Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
4cf24b4c
Commit
4cf24b4c
authored
Aug 16, 2003
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
bk://bk.arm.linux.org.uk/linux-2.5-pcmcia
into home.osdl.org:/home/torvalds/v2.5/linux
parents
7412360e
f0146a91
Changes
11
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
58 additions
and
123 deletions
+58
-123
drivers/bluetooth/bluecard_cs.c
drivers/bluetooth/bluecard_cs.c
+5
-10
drivers/bluetooth/bt3c_cs.c
drivers/bluetooth/bt3c_cs.c
+5
-12
drivers/bluetooth/btuart_cs.c
drivers/bluetooth/btuart_cs.c
+5
-11
drivers/bluetooth/dtl1_cs.c
drivers/bluetooth/dtl1_cs.c
+5
-11
drivers/ide/legacy/ide-cs.c
drivers/ide/legacy/ide-cs.c
+5
-10
drivers/isdn/hardware/avm/avm_cs.c
drivers/isdn/hardware/avm/avm_cs.c
+7
-14
drivers/isdn/hisax/avma1_cs.c
drivers/isdn/hisax/avma1_cs.c
+6
-12
drivers/isdn/hisax/elsa_cs.c
drivers/isdn/hisax/elsa_cs.c
+5
-11
drivers/isdn/hisax/sedlbauer_cs.c
drivers/isdn/hisax/sedlbauer_cs.c
+5
-11
drivers/parport/parport_cs.c
drivers/parport/parport_cs.c
+5
-10
drivers/telephony/ixj_pcmcia.c
drivers/telephony/ixj_pcmcia.c
+5
-11
No files found.
drivers/bluetooth/bluecard_cs.c
View file @
4cf24b4c
...
@@ -90,7 +90,7 @@ typedef struct bluecard_info_t {
...
@@ -90,7 +90,7 @@ typedef struct bluecard_info_t {
void
bluecard_config
(
dev_link_t
*
link
);
void
bluecard_config
(
dev_link_t
*
link
);
void
bluecard_release
(
u_long
arg
);
void
bluecard_release
(
dev_link_t
*
link
);
int
bluecard_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
int
bluecard_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
static
dev_info_t
dev_info
=
"bluecard_cs"
;
static
dev_info_t
dev_info
=
"bluecard_cs"
;
...
@@ -838,9 +838,6 @@ dev_link_t *bluecard_attach(void)
...
@@ -838,9 +838,6 @@ dev_link_t *bluecard_attach(void)
link
=
&
info
->
link
;
link
=
&
info
->
link
;
link
->
priv
=
info
;
link
->
priv
=
info
;
init_timer
(
&
link
->
release
);
link
->
release
.
function
=
&
bluecard_release
;
link
->
release
.
data
=
(
u_long
)
link
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
NumPorts1
=
8
;
link
->
io
.
NumPorts1
=
8
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
|
IRQ_HANDLE_PRESENT
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
|
IRQ_HANDLE_PRESENT
;
...
@@ -897,9 +894,8 @@ void bluecard_detach(dev_link_t *link)
...
@@ -897,9 +894,8 @@ void bluecard_detach(dev_link_t *link)
if
(
*
linkp
==
NULL
)
if
(
*
linkp
==
NULL
)
return
;
return
;
del_timer
(
&
link
->
release
);
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
bluecard_release
(
(
u_long
)
link
);
bluecard_release
(
link
);
if
(
link
->
handle
)
{
if
(
link
->
handle
)
{
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
...
@@ -1004,13 +1000,12 @@ void bluecard_config(dev_link_t *link)
...
@@ -1004,13 +1000,12 @@ void bluecard_config(dev_link_t *link)
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
failed:
failed:
bluecard_release
(
(
u_long
)
link
);
bluecard_release
(
link
);
}
}
void
bluecard_release
(
u_long
arg
)
void
bluecard_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
bluecard_info_t
*
info
=
link
->
priv
;
bluecard_info_t
*
info
=
link
->
priv
;
if
(
link
->
state
&
DEV_PRESENT
)
if
(
link
->
state
&
DEV_PRESENT
)
...
@@ -1036,7 +1031,7 @@ int bluecard_event(event_t event, int priority, event_callback_args_t *args)
...
@@ -1036,7 +1031,7 @@ int bluecard_event(event_t event, int priority, event_callback_args_t *args)
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
{
bluecard_close
(
info
);
bluecard_close
(
info
);
mod_timer
(
&
link
->
release
,
jiffies
+
HZ
/
20
);
bluecard_release
(
link
);
}
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
...
...
drivers/bluetooth/bt3c_cs.c
View file @
4cf24b4c
...
@@ -30,7 +30,6 @@
...
@@ -30,7 +30,6 @@
#include <linux/slab.h>
#include <linux/slab.h>
#include <linux/types.h>
#include <linux/types.h>
#include <linux/sched.h>
#include <linux/sched.h>
#include <linux/timer.h>
#include <linux/errno.h>
#include <linux/errno.h>
#include <linux/ptrace.h>
#include <linux/ptrace.h>
#include <linux/ioport.h>
#include <linux/ioport.h>
...
@@ -94,7 +93,7 @@ typedef struct bt3c_info_t {
...
@@ -94,7 +93,7 @@ typedef struct bt3c_info_t {
void
bt3c_config
(
dev_link_t
*
link
);
void
bt3c_config
(
dev_link_t
*
link
);
void
bt3c_release
(
u_long
arg
);
void
bt3c_release
(
dev_link_t
*
link
);
int
bt3c_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
int
bt3c_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
static
dev_info_t
dev_info
=
"bt3c_cs"
;
static
dev_info_t
dev_info
=
"bt3c_cs"
;
...
@@ -585,9 +584,6 @@ dev_link_t *bt3c_attach(void)
...
@@ -585,9 +584,6 @@ dev_link_t *bt3c_attach(void)
link
=
&
info
->
link
;
link
=
&
info
->
link
;
link
->
priv
=
info
;
link
->
priv
=
info
;
init_timer
(
&
link
->
release
);
link
->
release
.
function
=
&
bt3c_release
;
link
->
release
.
data
=
(
u_long
)
link
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
NumPorts1
=
8
;
link
->
io
.
NumPorts1
=
8
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
|
IRQ_HANDLE_PRESENT
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
|
IRQ_HANDLE_PRESENT
;
...
@@ -644,10 +640,8 @@ void bt3c_detach(dev_link_t *link)
...
@@ -644,10 +640,8 @@ void bt3c_detach(dev_link_t *link)
if
(
*
linkp
==
NULL
)
if
(
*
linkp
==
NULL
)
return
;
return
;
del_timer
(
&
link
->
release
);
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
bt3c_release
(
(
u_long
)
link
);
bt3c_release
(
link
);
if
(
link
->
handle
)
{
if
(
link
->
handle
)
{
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
...
@@ -790,13 +784,12 @@ void bt3c_config(dev_link_t *link)
...
@@ -790,13 +784,12 @@ void bt3c_config(dev_link_t *link)
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
failed:
failed:
bt3c_release
(
(
u_long
)
link
);
bt3c_release
(
link
);
}
}
void
bt3c_release
(
u_long
arg
)
void
bt3c_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
bt3c_info_t
*
info
=
link
->
priv
;
bt3c_info_t
*
info
=
link
->
priv
;
if
(
link
->
state
&
DEV_PRESENT
)
if
(
link
->
state
&
DEV_PRESENT
)
...
@@ -822,7 +815,7 @@ int bt3c_event(event_t event, int priority, event_callback_args_t *args)
...
@@ -822,7 +815,7 @@ int bt3c_event(event_t event, int priority, event_callback_args_t *args)
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
{
bt3c_close
(
info
);
bt3c_close
(
info
);
mod_timer
(
&
link
->
release
,
jiffies
+
HZ
/
20
);
bt3c_release
(
link
);
}
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
...
...
drivers/bluetooth/btuart_cs.c
View file @
4cf24b4c
...
@@ -28,7 +28,6 @@
...
@@ -28,7 +28,6 @@
#include <linux/slab.h>
#include <linux/slab.h>
#include <linux/types.h>
#include <linux/types.h>
#include <linux/sched.h>
#include <linux/sched.h>
#include <linux/timer.h>
#include <linux/errno.h>
#include <linux/errno.h>
#include <linux/ptrace.h>
#include <linux/ptrace.h>
#include <linux/ioport.h>
#include <linux/ioport.h>
...
@@ -92,7 +91,7 @@ typedef struct btuart_info_t {
...
@@ -92,7 +91,7 @@ typedef struct btuart_info_t {
void
btuart_config
(
dev_link_t
*
link
);
void
btuart_config
(
dev_link_t
*
link
);
void
btuart_release
(
u_long
arg
);
void
btuart_release
(
dev_link_t
*
link
);
int
btuart_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
int
btuart_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
static
dev_info_t
dev_info
=
"btuart_cs"
;
static
dev_info_t
dev_info
=
"btuart_cs"
;
...
@@ -592,9 +591,6 @@ dev_link_t *btuart_attach(void)
...
@@ -592,9 +591,6 @@ dev_link_t *btuart_attach(void)
link
=
&
info
->
link
;
link
=
&
info
->
link
;
link
->
priv
=
info
;
link
->
priv
=
info
;
init_timer
(
&
link
->
release
);
link
->
release
.
function
=
&
btuart_release
;
link
->
release
.
data
=
(
u_long
)
link
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
NumPorts1
=
8
;
link
->
io
.
NumPorts1
=
8
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
|
IRQ_HANDLE_PRESENT
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
|
IRQ_HANDLE_PRESENT
;
...
@@ -651,9 +647,8 @@ void btuart_detach(dev_link_t *link)
...
@@ -651,9 +647,8 @@ void btuart_detach(dev_link_t *link)
if
(
*
linkp
==
NULL
)
if
(
*
linkp
==
NULL
)
return
;
return
;
del_timer
(
&
link
->
release
);
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
btuart_release
(
(
u_long
)
link
);
btuart_release
(
link
);
if
(
link
->
handle
)
{
if
(
link
->
handle
)
{
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
...
@@ -797,13 +792,12 @@ void btuart_config(dev_link_t *link)
...
@@ -797,13 +792,12 @@ void btuart_config(dev_link_t *link)
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
failed:
failed:
btuart_release
(
(
u_long
)
link
);
btuart_release
(
link
);
}
}
void
btuart_release
(
u_long
arg
)
void
btuart_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
btuart_info_t
*
info
=
link
->
priv
;
btuart_info_t
*
info
=
link
->
priv
;
if
(
link
->
state
&
DEV_PRESENT
)
if
(
link
->
state
&
DEV_PRESENT
)
...
@@ -829,7 +823,7 @@ int btuart_event(event_t event, int priority, event_callback_args_t *args)
...
@@ -829,7 +823,7 @@ int btuart_event(event_t event, int priority, event_callback_args_t *args)
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
{
btuart_close
(
info
);
btuart_close
(
info
);
mod_timer
(
&
link
->
release
,
jiffies
+
HZ
/
20
);
btuart_release
(
link
);
}
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
...
...
drivers/bluetooth/dtl1_cs.c
View file @
4cf24b4c
...
@@ -28,7 +28,6 @@
...
@@ -28,7 +28,6 @@
#include <linux/slab.h>
#include <linux/slab.h>
#include <linux/types.h>
#include <linux/types.h>
#include <linux/sched.h>
#include <linux/sched.h>
#include <linux/timer.h>
#include <linux/errno.h>
#include <linux/errno.h>
#include <linux/ptrace.h>
#include <linux/ptrace.h>
#include <linux/ioport.h>
#include <linux/ioport.h>
...
@@ -95,7 +94,7 @@ typedef struct dtl1_info_t {
...
@@ -95,7 +94,7 @@ typedef struct dtl1_info_t {
void
dtl1_config
(
dev_link_t
*
link
);
void
dtl1_config
(
dev_link_t
*
link
);
void
dtl1_release
(
u_long
arg
);
void
dtl1_release
(
dev_link_t
*
link
);
int
dtl1_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
int
dtl1_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
static
dev_info_t
dev_info
=
"dtl1_cs"
;
static
dev_info_t
dev_info
=
"dtl1_cs"
;
...
@@ -571,9 +570,6 @@ dev_link_t *dtl1_attach(void)
...
@@ -571,9 +570,6 @@ dev_link_t *dtl1_attach(void)
link
=
&
info
->
link
;
link
=
&
info
->
link
;
link
->
priv
=
info
;
link
->
priv
=
info
;
init_timer
(
&
link
->
release
);
link
->
release
.
function
=
&
dtl1_release
;
link
->
release
.
data
=
(
u_long
)
link
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
NumPorts1
=
8
;
link
->
io
.
NumPorts1
=
8
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
|
IRQ_HANDLE_PRESENT
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
|
IRQ_HANDLE_PRESENT
;
...
@@ -630,9 +626,8 @@ void dtl1_detach(dev_link_t *link)
...
@@ -630,9 +626,8 @@ void dtl1_detach(dev_link_t *link)
if
(
*
linkp
==
NULL
)
if
(
*
linkp
==
NULL
)
return
;
return
;
del_timer
(
&
link
->
release
);
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
dtl1_release
(
(
u_long
)
link
);
dtl1_release
(
link
);
if
(
link
->
handle
)
{
if
(
link
->
handle
)
{
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
...
@@ -749,13 +744,12 @@ void dtl1_config(dev_link_t *link)
...
@@ -749,13 +744,12 @@ void dtl1_config(dev_link_t *link)
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
failed:
failed:
dtl1_release
(
(
u_long
)
link
);
dtl1_release
(
link
);
}
}
void
dtl1_release
(
u_long
arg
)
void
dtl1_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
dtl1_info_t
*
info
=
link
->
priv
;
dtl1_info_t
*
info
=
link
->
priv
;
if
(
link
->
state
&
DEV_PRESENT
)
if
(
link
->
state
&
DEV_PRESENT
)
...
@@ -781,7 +775,7 @@ int dtl1_event(event_t event, int priority, event_callback_args_t *args)
...
@@ -781,7 +775,7 @@ int dtl1_event(event_t event, int priority, event_callback_args_t *args)
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
{
dtl1_close
(
info
);
dtl1_close
(
info
);
mod_timer
(
&
link
->
release
,
jiffies
+
HZ
/
20
);
dtl1_release
(
link
);
}
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
...
...
drivers/ide/legacy/ide-cs.c
View file @
4cf24b4c
...
@@ -92,7 +92,7 @@ typedef struct ide_info_t {
...
@@ -92,7 +92,7 @@ typedef struct ide_info_t {
int
hd
;
int
hd
;
}
ide_info_t
;
}
ide_info_t
;
static
void
ide_release
(
u_long
arg
);
static
void
ide_release
(
dev_link_t
*
);
static
int
ide_event
(
event_t
event
,
int
priority
,
static
int
ide_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
event_callback_args_t
*
args
);
...
@@ -126,9 +126,6 @@ static dev_link_t *ide_attach(void)
...
@@ -126,9 +126,6 @@ static dev_link_t *ide_attach(void)
memset
(
info
,
0
,
sizeof
(
*
info
));
memset
(
info
,
0
,
sizeof
(
*
info
));
link
=
&
info
->
link
;
link
->
priv
=
info
;
link
=
&
info
->
link
;
link
->
priv
=
info
;
init_timer
(
&
link
->
release
);
link
->
release
.
function
=
&
ide_release
;
link
->
release
.
data
=
(
u_long
)
link
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_AUTO
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_AUTO
;
link
->
io
.
Attributes2
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes2
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
IOAddrLines
=
3
;
link
->
io
.
IOAddrLines
=
3
;
...
@@ -187,9 +184,8 @@ static void ide_detach(dev_link_t *link)
...
@@ -187,9 +184,8 @@ static void ide_detach(dev_link_t *link)
if
(
*
linkp
==
NULL
)
if
(
*
linkp
==
NULL
)
return
;
return
;
del_timer
(
&
link
->
release
);
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
ide_release
(
(
u_long
)
link
);
ide_release
(
link
);
if
(
link
->
handle
)
{
if
(
link
->
handle
)
{
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
...
@@ -383,7 +379,7 @@ void ide_config(dev_link_t *link)
...
@@ -383,7 +379,7 @@ void ide_config(dev_link_t *link)
cs_failed:
cs_failed:
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
failed:
failed:
ide_release
(
(
u_long
)
link
);
ide_release
(
link
);
link
->
state
&=
~
DEV_CONFIG_PENDING
;
link
->
state
&=
~
DEV_CONFIG_PENDING
;
}
/* ide_config */
}
/* ide_config */
...
@@ -396,9 +392,8 @@ void ide_config(dev_link_t *link)
...
@@ -396,9 +392,8 @@ void ide_config(dev_link_t *link)
======================================================================*/
======================================================================*/
void
ide_release
(
u_long
arg
)
void
ide_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
ide_info_t
*
info
=
link
->
priv
;
ide_info_t
*
info
=
link
->
priv
;
DEBUG
(
0
,
"ide_release(0x%p)
\n
"
,
link
);
DEBUG
(
0
,
"ide_release(0x%p)
\n
"
,
link
);
...
@@ -446,7 +441,7 @@ int ide_event(event_t event, int priority,
...
@@ -446,7 +441,7 @@ int ide_event(event_t event, int priority,
case
CS_EVENT_CARD_REMOVAL
:
case
CS_EVENT_CARD_REMOVAL
:
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
mod_timer
(
&
link
->
release
,
jiffies
+
HZ
/
20
);
ide_release
(
link
);
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
link
->
state
|=
DEV_PRESENT
|
DEV_CONFIG_PENDING
;
link
->
state
|=
DEV_PRESENT
|
DEV_CONFIG_PENDING
;
...
...
drivers/isdn/hardware/avm/avm_cs.c
View file @
4cf24b4c
...
@@ -16,7 +16,6 @@
...
@@ -16,7 +16,6 @@
#include <linux/ptrace.h>
#include <linux/ptrace.h>
#include <linux/slab.h>
#include <linux/slab.h>
#include <linux/string.h>
#include <linux/string.h>
#include <linux/timer.h>
#include <linux/tty.h>
#include <linux/tty.h>
#include <linux/serial.h>
#include <linux/serial.h>
#include <linux/major.h>
#include <linux/major.h>
...
@@ -64,7 +63,7 @@ MODULE_PARM(irq_list, "1-10i");
...
@@ -64,7 +63,7 @@ MODULE_PARM(irq_list, "1-10i");
*/
*/
static
void
avmcs_config
(
dev_link_t
*
link
);
static
void
avmcs_config
(
dev_link_t
*
link
);
static
void
avmcs_release
(
u_long
arg
);
static
void
avmcs_release
(
dev_link_t
*
link
);
static
int
avmcs_event
(
event_t
event
,
int
priority
,
static
int
avmcs_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
event_callback_args_t
*
args
);
...
@@ -142,8 +141,6 @@ static dev_link_t *avmcs_attach(void)
...
@@ -142,8 +141,6 @@ static dev_link_t *avmcs_attach(void)
if
(
!
link
)
if
(
!
link
)
goto
err
;
goto
err
;
memset
(
link
,
0
,
sizeof
(
struct
dev_link_t
));
memset
(
link
,
0
,
sizeof
(
struct
dev_link_t
));
link
->
release
.
function
=
&
avmcs_release
;
link
->
release
.
data
=
(
u_long
)
link
;
/* The io structure describes IO port mapping */
/* The io structure describes IO port mapping */
link
->
io
.
NumPorts1
=
16
;
link
->
io
.
NumPorts1
=
16
;
...
@@ -403,7 +400,7 @@ static void avmcs_config(dev_link_t *link)
...
@@ -403,7 +400,7 @@ static void avmcs_config(dev_link_t *link)
link
->
state
&=
~
DEV_CONFIG_PENDING
;
link
->
state
&=
~
DEV_CONFIG_PENDING
;
/* If any step failed, release any partially configured state */
/* If any step failed, release any partially configured state */
if
(
i
!=
0
)
{
if
(
i
!=
0
)
{
avmcs_release
(
(
u_long
)
link
);
avmcs_release
(
link
);
return
;
return
;
}
}
...
@@ -417,7 +414,7 @@ static void avmcs_config(dev_link_t *link)
...
@@ -417,7 +414,7 @@ static void avmcs_config(dev_link_t *link)
if
((
i
=
(
*
addcard
)(
link
->
io
.
BasePort1
,
link
->
irq
.
AssignedIRQ
))
<
0
)
{
if
((
i
=
(
*
addcard
)(
link
->
io
.
BasePort1
,
link
->
irq
.
AssignedIRQ
))
<
0
)
{
printk
(
KERN_ERR
"avm_cs: failed to add AVM-%s-Controller at i/o %#x, irq %d
\n
"
,
printk
(
KERN_ERR
"avm_cs: failed to add AVM-%s-Controller at i/o %#x, irq %d
\n
"
,
dev
->
node
.
dev_name
,
link
->
io
.
BasePort1
,
link
->
irq
.
AssignedIRQ
);
dev
->
node
.
dev_name
,
link
->
io
.
BasePort1
,
link
->
irq
.
AssignedIRQ
);
avmcs_release
(
(
u_long
)
link
);
avmcs_release
(
link
);
return
;
return
;
}
}
dev
->
node
.
minor
=
i
;
dev
->
node
.
minor
=
i
;
...
@@ -432,10 +429,8 @@ static void avmcs_config(dev_link_t *link)
...
@@ -432,10 +429,8 @@ static void avmcs_config(dev_link_t *link)
======================================================================*/
======================================================================*/
static
void
avmcs_release
(
u_long
arg
)
static
void
avmcs_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
/*
/*
If the device is currently in use, we won't release until it
If the device is currently in use, we won't release until it
is actually closed.
is actually closed.
...
@@ -483,10 +478,8 @@ static int avmcs_event(event_t event, int priority,
...
@@ -483,10 +478,8 @@ static int avmcs_event(event_t event, int priority,
switch
(
event
)
{
switch
(
event
)
{
case
CS_EVENT_CARD_REMOVAL
:
case
CS_EVENT_CARD_REMOVAL
:
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
link
->
release
.
expires
=
jiffies
+
(
HZ
/
20
);
avmcs_release
(
link
);
add_timer
(
&
link
->
release
);
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
link
->
state
|=
DEV_PRESENT
|
DEV_CONFIG_PENDING
;
link
->
state
|=
DEV_PRESENT
|
DEV_CONFIG_PENDING
;
...
@@ -531,7 +524,7 @@ static void __exit avmcs_exit(void)
...
@@ -531,7 +524,7 @@ static void __exit avmcs_exit(void)
/* XXX: this really needs to move into generic code.. */
/* XXX: this really needs to move into generic code.. */
while
(
dev_list
!=
NULL
)
{
while
(
dev_list
!=
NULL
)
{
if
(
dev_list
->
state
&
DEV_CONFIG
)
if
(
dev_list
->
state
&
DEV_CONFIG
)
avmcs_release
(
(
u_long
)
dev_list
);
avmcs_release
(
dev_list
);
avmcs_detach
(
dev_list
);
avmcs_detach
(
dev_list
);
}
}
}
}
...
...
drivers/isdn/hisax/avma1_cs.c
View file @
4cf24b4c
...
@@ -18,7 +18,6 @@
...
@@ -18,7 +18,6 @@
#include <linux/ptrace.h>
#include <linux/ptrace.h>
#include <linux/slab.h>
#include <linux/slab.h>
#include <linux/string.h>
#include <linux/string.h>
#include <linux/timer.h>
#include <asm/io.h>
#include <asm/io.h>
#include <asm/system.h>
#include <asm/system.h>
...
@@ -76,7 +75,7 @@ MODULE_PARM(isdnprot, "1-4i");
...
@@ -76,7 +75,7 @@ MODULE_PARM(isdnprot, "1-4i");
*/
*/
static
void
avma1cs_config
(
dev_link_t
*
link
);
static
void
avma1cs_config
(
dev_link_t
*
link
);
static
void
avma1cs_release
(
u_long
arg
);
static
void
avma1cs_release
(
dev_link_t
*
link
);
static
int
avma1cs_event
(
event_t
event
,
int
priority
,
static
int
avma1cs_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
event_callback_args_t
*
args
);
...
@@ -156,8 +155,6 @@ static dev_link_t *avma1cs_attach(void)
...
@@ -156,8 +155,6 @@ static dev_link_t *avma1cs_attach(void)
if
(
!
link
)
if
(
!
link
)
return
NULL
;
return
NULL
;
memset
(
link
,
0
,
sizeof
(
struct
dev_link_t
));
memset
(
link
,
0
,
sizeof
(
struct
dev_link_t
));
link
->
release
.
function
=
&
avma1cs_release
;
link
->
release
.
data
=
(
u_long
)
link
;
/* The io structure describes IO port mapping */
/* The io structure describes IO port mapping */
link
->
io
.
NumPorts1
=
16
;
link
->
io
.
NumPorts1
=
16
;
...
@@ -407,7 +404,7 @@ static void avma1cs_config(dev_link_t *link)
...
@@ -407,7 +404,7 @@ static void avma1cs_config(dev_link_t *link)
link
->
state
&=
~
DEV_CONFIG_PENDING
;
link
->
state
&=
~
DEV_CONFIG_PENDING
;
/* If any step failed, release any partially configured state */
/* If any step failed, release any partially configured state */
if
(
i
!=
0
)
{
if
(
i
!=
0
)
{
avma1cs_release
(
(
u_long
)
link
);
avma1cs_release
(
link
);
return
;
return
;
}
}
...
@@ -435,9 +432,8 @@ static void avma1cs_config(dev_link_t *link)
...
@@ -435,9 +432,8 @@ static void avma1cs_config(dev_link_t *link)
======================================================================*/
======================================================================*/
static
void
avma1cs_release
(
u_long
arg
)
static
void
avma1cs_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
local_info_t
*
local
=
link
->
priv
;
local_info_t
*
local
=
link
->
priv
;
DEBUG
(
0
,
"avma1cs_release(0x%p)
\n
"
,
link
);
DEBUG
(
0
,
"avma1cs_release(0x%p)
\n
"
,
link
);
...
@@ -494,10 +490,8 @@ static int avma1cs_event(event_t event, int priority,
...
@@ -494,10 +490,8 @@ static int avma1cs_event(event_t event, int priority,
switch
(
event
)
{
switch
(
event
)
{
case
CS_EVENT_CARD_REMOVAL
:
case
CS_EVENT_CARD_REMOVAL
:
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
link
->
release
.
expires
=
jiffies
+
HZ
/
20
;
avma1cs_release
(
link
);
add_timer
(
&
link
->
release
);
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
link
->
state
|=
DEV_PRESENT
|
DEV_CONFIG_PENDING
;
link
->
state
|=
DEV_PRESENT
|
DEV_CONFIG_PENDING
;
...
@@ -542,7 +536,7 @@ static void __exit exit_avma1_cs(void)
...
@@ -542,7 +536,7 @@ static void __exit exit_avma1_cs(void)
/* XXX: this really needs to move into generic code.. */
/* XXX: this really needs to move into generic code.. */
while
(
dev_list
!=
NULL
)
{
while
(
dev_list
!=
NULL
)
{
if
(
dev_list
->
state
&
DEV_CONFIG
)
if
(
dev_list
->
state
&
DEV_CONFIG
)
avma1cs_release
(
(
u_long
)
dev_list
);
avma1cs_release
(
dev_list
);
avma1cs_detach
(
dev_list
);
avma1cs_detach
(
dev_list
);
}
}
}
}
...
...
drivers/isdn/hisax/elsa_cs.c
View file @
4cf24b4c
...
@@ -107,7 +107,7 @@ extern int elsa_init_pcmcia(int, int, int*, int);
...
@@ -107,7 +107,7 @@ extern int elsa_init_pcmcia(int, int, int*, int);
*/
*/
static
void
elsa_cs_config
(
dev_link_t
*
link
);
static
void
elsa_cs_config
(
dev_link_t
*
link
);
static
void
elsa_cs_release
(
u_long
arg
);
static
void
elsa_cs_release
(
dev_link_t
*
link
);
static
int
elsa_cs_event
(
event_t
event
,
int
priority
,
static
int
elsa_cs_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
event_callback_args_t
*
args
);
...
@@ -198,10 +198,6 @@ static dev_link_t *elsa_cs_attach(void)
...
@@ -198,10 +198,6 @@ static dev_link_t *elsa_cs_attach(void)
memset
(
local
,
0
,
sizeof
(
local_info_t
));
memset
(
local
,
0
,
sizeof
(
local_info_t
));
link
=
&
local
->
link
;
link
->
priv
=
local
;
link
=
&
local
->
link
;
link
->
priv
=
local
;
/* Initialize the dev_link_t structure */
link
->
release
.
function
=
&
elsa_cs_release
;
link
->
release
.
data
=
(
u_long
)
link
;
/* Interrupt setup */
/* Interrupt setup */
link
->
irq
.
Attributes
=
IRQ_TYPE_DYNAMIC_SHARING
|
IRQ_FIRST_SHARED
;
link
->
irq
.
Attributes
=
IRQ_TYPE_DYNAMIC_SHARING
|
IRQ_FIRST_SHARED
;
link
->
irq
.
IRQInfo1
=
IRQ_INFO2_VALID
|
IRQ_LEVEL_ID
|
IRQ_SHARE_ID
;
link
->
irq
.
IRQInfo1
=
IRQ_INFO2_VALID
|
IRQ_LEVEL_ID
|
IRQ_SHARE_ID
;
...
@@ -272,9 +268,8 @@ static void elsa_cs_detach(dev_link_t *link)
...
@@ -272,9 +268,8 @@ static void elsa_cs_detach(dev_link_t *link)
if
(
*
linkp
==
NULL
)
if
(
*
linkp
==
NULL
)
return
;
return
;
del_timer
(
&
link
->
release
);
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
elsa_cs_release
(
(
u_long
)
link
);
elsa_cs_release
(
link
);
/*
/*
If the device is currently configured and active, we won't
If the device is currently configured and active, we won't
...
@@ -431,7 +426,7 @@ static void elsa_cs_config(dev_link_t *link)
...
@@ -431,7 +426,7 @@ static void elsa_cs_config(dev_link_t *link)
return
;
return
;
cs_failed:
cs_failed:
cs_error
(
link
->
handle
,
last_fn
,
i
);
cs_error
(
link
->
handle
,
last_fn
,
i
);
elsa_cs_release
(
(
u_long
)
link
);
elsa_cs_release
(
link
);
}
/* elsa_cs_config */
}
/* elsa_cs_config */
/*======================================================================
/*======================================================================
...
@@ -442,9 +437,8 @@ static void elsa_cs_config(dev_link_t *link)
...
@@ -442,9 +437,8 @@ static void elsa_cs_config(dev_link_t *link)
======================================================================*/
======================================================================*/
static
void
elsa_cs_release
(
u_long
arg
)
static
void
elsa_cs_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
DEBUG
(
0
,
"elsa_cs_release(0x%p)
\n
"
,
link
);
DEBUG
(
0
,
"elsa_cs_release(0x%p)
\n
"
,
link
);
...
@@ -503,7 +497,7 @@ static int elsa_cs_event(event_t event, int priority,
...
@@ -503,7 +497,7 @@ static int elsa_cs_event(event_t event, int priority,
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
{
((
local_info_t
*
)
link
->
priv
)
->
busy
=
1
;
((
local_info_t
*
)
link
->
priv
)
->
busy
=
1
;
mod_timer
(
&
link
->
release
,
jiffies
+
HZ
/
20
);
elsa_cs_release
(
link
);
}
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
...
...
drivers/isdn/hisax/sedlbauer_cs.c
View file @
4cf24b4c
...
@@ -107,7 +107,7 @@ extern int sedl_init_pcmcia(int, int, int*, int);
...
@@ -107,7 +107,7 @@ extern int sedl_init_pcmcia(int, int, int*, int);
*/
*/
static
void
sedlbauer_config
(
dev_link_t
*
link
);
static
void
sedlbauer_config
(
dev_link_t
*
link
);
static
void
sedlbauer_release
(
u_long
arg
);
static
void
sedlbauer_release
(
dev_link_t
*
link
);
static
int
sedlbauer_event
(
event_t
event
,
int
priority
,
static
int
sedlbauer_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
event_callback_args_t
*
args
);
...
@@ -205,10 +205,6 @@ static dev_link_t *sedlbauer_attach(void)
...
@@ -205,10 +205,6 @@ static dev_link_t *sedlbauer_attach(void)
memset
(
local
,
0
,
sizeof
(
local_info_t
));
memset
(
local
,
0
,
sizeof
(
local_info_t
));
link
=
&
local
->
link
;
link
->
priv
=
local
;
link
=
&
local
->
link
;
link
->
priv
=
local
;
/* Initialize the dev_link_t structure */
link
->
release
.
function
=
&
sedlbauer_release
;
link
->
release
.
data
=
(
u_long
)
link
;
/* Interrupt setup */
/* Interrupt setup */
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
;
link
->
irq
.
IRQInfo1
=
IRQ_INFO2_VALID
|
IRQ_LEVEL_ID
;
link
->
irq
.
IRQInfo1
=
IRQ_INFO2_VALID
|
IRQ_LEVEL_ID
;
...
@@ -523,7 +519,7 @@ static void sedlbauer_config(dev_link_t *link)
...
@@ -523,7 +519,7 @@ static void sedlbauer_config(dev_link_t *link)
cs_failed:
cs_failed:
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
sedlbauer_release
(
(
u_long
)
link
);
sedlbauer_release
(
link
);
}
/* sedlbauer_config */
}
/* sedlbauer_config */
...
@@ -535,10 +531,8 @@ static void sedlbauer_config(dev_link_t *link)
...
@@ -535,10 +531,8 @@ static void sedlbauer_config(dev_link_t *link)
======================================================================*/
======================================================================*/
static
void
sedlbauer_release
(
u_long
arg
)
static
void
sedlbauer_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
DEBUG
(
0
,
"sedlbauer_release(0x%p)
\n
"
,
link
);
DEBUG
(
0
,
"sedlbauer_release(0x%p)
\n
"
,
link
);
/*
/*
...
@@ -601,7 +595,7 @@ static int sedlbauer_event(event_t event, int priority,
...
@@ -601,7 +595,7 @@ static int sedlbauer_event(event_t event, int priority,
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
{
((
local_info_t
*
)
link
->
priv
)
->
stop
=
1
;
((
local_info_t
*
)
link
->
priv
)
->
stop
=
1
;
mod_timer
(
&
link
->
release
,
jiffies
+
HZ
/
20
);
sedlbauer_release
(
link
);
}
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
...
@@ -655,7 +649,7 @@ static void __exit exit_sedlbauer_cs(void)
...
@@ -655,7 +649,7 @@ static void __exit exit_sedlbauer_cs(void)
while
(
dev_list
!=
NULL
)
{
while
(
dev_list
!=
NULL
)
{
del_timer
(
&
dev_list
->
release
);
del_timer
(
&
dev_list
->
release
);
if
(
dev_list
->
state
&
DEV_CONFIG
)
if
(
dev_list
->
state
&
DEV_CONFIG
)
sedlbauer_release
(
(
u_long
)
dev_list
);
sedlbauer_release
(
dev_list
);
sedlbauer_detach
(
dev_list
);
sedlbauer_detach
(
dev_list
);
}
}
}
}
...
...
drivers/parport/parport_cs.c
View file @
4cf24b4c
...
@@ -96,7 +96,7 @@ typedef struct parport_info_t {
...
@@ -96,7 +96,7 @@ typedef struct parport_info_t {
static
dev_link_t
*
parport_attach
(
void
);
static
dev_link_t
*
parport_attach
(
void
);
static
void
parport_detach
(
dev_link_t
*
);
static
void
parport_detach
(
dev_link_t
*
);
static
void
parport_config
(
dev_link_t
*
link
);
static
void
parport_config
(
dev_link_t
*
link
);
static
void
parport_cs_release
(
u_long
arg
);
static
void
parport_cs_release
(
dev_link_t
*
);
static
int
parport_event
(
event_t
event
,
int
priority
,
static
int
parport_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
event_callback_args_t
*
args
);
...
@@ -126,9 +126,6 @@ static dev_link_t *parport_attach(void)
...
@@ -126,9 +126,6 @@ static dev_link_t *parport_attach(void)
memset
(
info
,
0
,
sizeof
(
*
info
));
memset
(
info
,
0
,
sizeof
(
*
info
));
link
=
&
info
->
link
;
link
->
priv
=
info
;
link
=
&
info
->
link
;
link
->
priv
=
info
;
init_timer
(
&
link
->
release
);
link
->
release
.
function
=
&
parport_cs_release
;
link
->
release
.
data
=
(
u_long
)
link
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes2
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes2
=
IO_DATA_PATH_WIDTH_8
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
;
link
->
irq
.
Attributes
=
IRQ_TYPE_EXCLUSIVE
;
...
@@ -186,9 +183,8 @@ static void parport_detach(dev_link_t *link)
...
@@ -186,9 +183,8 @@ static void parport_detach(dev_link_t *link)
if
(
*
linkp
==
NULL
)
if
(
*
linkp
==
NULL
)
return
;
return
;
del_timer
(
&
link
->
release
);
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
parport_cs_release
(
(
u_long
)
link
);
parport_cs_release
(
link
);
if
(
link
->
handle
)
{
if
(
link
->
handle
)
{
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
...
@@ -308,7 +304,7 @@ void parport_config(dev_link_t *link)
...
@@ -308,7 +304,7 @@ void parport_config(dev_link_t *link)
cs_failed:
cs_failed:
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
failed:
failed:
parport_cs_release
(
(
u_long
)
link
);
parport_cs_release
(
link
);
link
->
state
&=
~
DEV_CONFIG_PENDING
;
link
->
state
&=
~
DEV_CONFIG_PENDING
;
}
/* parport_config */
}
/* parport_config */
...
@@ -321,9 +317,8 @@ void parport_config(dev_link_t *link)
...
@@ -321,9 +317,8 @@ void parport_config(dev_link_t *link)
======================================================================*/
======================================================================*/
void
parport_cs_release
(
u_long
arg
)
void
parport_cs_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
parport_info_t
*
info
=
link
->
priv
;
parport_info_t
*
info
=
link
->
priv
;
DEBUG
(
0
,
"parport_release(0x%p)
\n
"
,
link
);
DEBUG
(
0
,
"parport_release(0x%p)
\n
"
,
link
);
...
@@ -366,7 +361,7 @@ int parport_event(event_t event, int priority,
...
@@ -366,7 +361,7 @@ int parport_event(event_t event, int priority,
case
CS_EVENT_CARD_REMOVAL
:
case
CS_EVENT_CARD_REMOVAL
:
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
mod_timer
(
&
link
->
release
,
jiffies
+
HZ
/
20
);
parport_cs_release
(
link
);
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
link
->
state
|=
DEV_PRESENT
|
DEV_CONFIG_PENDING
;
link
->
state
|=
DEV_PRESENT
|
DEV_CONFIG_PENDING
;
...
...
drivers/telephony/ixj_pcmcia.c
View file @
4cf24b4c
...
@@ -38,7 +38,7 @@ typedef struct ixj_info_t {
...
@@ -38,7 +38,7 @@ typedef struct ixj_info_t {
static
dev_link_t
*
ixj_attach
(
void
);
static
dev_link_t
*
ixj_attach
(
void
);
static
void
ixj_detach
(
dev_link_t
*
);
static
void
ixj_detach
(
dev_link_t
*
);
static
void
ixj_config
(
dev_link_t
*
link
);
static
void
ixj_config
(
dev_link_t
*
link
);
static
void
ixj_cs_release
(
u_long
arg
);
static
void
ixj_cs_release
(
dev_link_t
*
link
);
static
int
ixj_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
static
int
ixj_event
(
event_t
event
,
int
priority
,
event_callback_args_t
*
args
);
static
dev_info_t
dev_info
=
"ixj_cs"
;
static
dev_info_t
dev_info
=
"ixj_cs"
;
static
dev_link_t
*
dev_list
=
NULL
;
static
dev_link_t
*
dev_list
=
NULL
;
...
@@ -54,9 +54,6 @@ static dev_link_t *ixj_attach(void)
...
@@ -54,9 +54,6 @@ static dev_link_t *ixj_attach(void)
if
(
!
link
)
if
(
!
link
)
return
NULL
;
return
NULL
;
memset
(
link
,
0
,
sizeof
(
struct
dev_link_t
));
memset
(
link
,
0
,
sizeof
(
struct
dev_link_t
));
init_timer
(
&
link
->
release
);
link
->
release
.
function
=
&
ixj_cs_release
;
link
->
release
.
data
=
(
u_long
)
link
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes1
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes2
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
Attributes2
=
IO_DATA_PATH_WIDTH_8
;
link
->
io
.
IOAddrLines
=
3
;
link
->
io
.
IOAddrLines
=
3
;
...
@@ -97,10 +94,9 @@ static void ixj_detach(dev_link_t * link)
...
@@ -97,10 +94,9 @@ static void ixj_detach(dev_link_t * link)
break
;
break
;
if
(
*
linkp
==
NULL
)
if
(
*
linkp
==
NULL
)
return
;
return
;
del_timer_sync
(
&
link
->
release
);
link
->
state
&=
~
DEV_RELEASE_PENDING
;
link
->
state
&=
~
DEV_RELEASE_PENDING
;
if
(
link
->
state
&
DEV_CONFIG
)
if
(
link
->
state
&
DEV_CONFIG
)
ixj_cs_release
(
(
u_long
)
link
);
ixj_cs_release
(
link
);
if
(
link
->
handle
)
{
if
(
link
->
handle
)
{
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
ret
=
CardServices
(
DeregisterClient
,
link
->
handle
);
if
(
ret
!=
CS_SUCCESS
)
if
(
ret
!=
CS_SUCCESS
)
...
@@ -251,12 +247,11 @@ static void ixj_config(dev_link_t * link)
...
@@ -251,12 +247,11 @@ static void ixj_config(dev_link_t * link)
return
;
return
;
cs_failed:
cs_failed:
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
cs_error
(
link
->
handle
,
last_fn
,
last_ret
);
ixj_cs_release
(
(
u_long
)
link
);
ixj_cs_release
(
link
);
}
}
static
void
ixj_cs_release
(
u_long
arg
)
static
void
ixj_cs_release
(
dev_link_t
*
link
)
{
{
dev_link_t
*
link
=
(
dev_link_t
*
)
arg
;
ixj_info_t
*
info
=
link
->
priv
;
ixj_info_t
*
info
=
link
->
priv
;
DEBUG
(
0
,
"ixj_cs_release(0x%p)
\n
"
,
link
);
DEBUG
(
0
,
"ixj_cs_release(0x%p)
\n
"
,
link
);
info
->
ndev
=
0
;
info
->
ndev
=
0
;
...
@@ -274,9 +269,8 @@ static int ixj_event(event_t event, int priority, event_callback_args_t * args)
...
@@ -274,9 +269,8 @@ static int ixj_event(event_t event, int priority, event_callback_args_t * args)
case
CS_EVENT_CARD_REMOVAL
:
case
CS_EVENT_CARD_REMOVAL
:
link
->
state
&=
~
DEV_PRESENT
;
link
->
state
&=
~
DEV_PRESENT
;
if
(
link
->
state
&
DEV_CONFIG
)
{
if
(
link
->
state
&
DEV_CONFIG
)
{
link
->
release
.
expires
=
jiffies
+
(
HZ
/
20
);
link
->
state
|=
DEV_RELEASE_PENDING
;
link
->
state
|=
DEV_RELEASE_PENDING
;
add_timer
(
&
link
->
release
);
ixj_cs_release
(
link
);
}
}
break
;
break
;
case
CS_EVENT_CARD_INSERTION
:
case
CS_EVENT_CARD_INSERTION
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment