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
nexedi
linux
Commits
dd99888a
Commit
dd99888a
authored
Aug 20, 2003
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix up DIGI driver for work-queue abstraction
parent
0b401e25
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
17 deletions
+4
-17
drivers/char/pcxx.c
drivers/char/pcxx.c
+2
-15
drivers/char/pcxx.h
drivers/char/pcxx.h
+2
-2
No files found.
drivers/char/pcxx.c
View file @
dd99888a
...
@@ -142,8 +142,6 @@ static struct tty_driver *pcxe_driver;
...
@@ -142,8 +142,6 @@ static struct tty_driver *pcxe_driver;
static
struct
timer_list
pcxx_timer
;
static
struct
timer_list
pcxx_timer
;
DECLARE_TASK_QUEUE
(
tq_pcxx
);
static
void
pcxxpoll
(
unsigned
long
dummy
);
static
void
pcxxpoll
(
unsigned
long
dummy
);
static
void
fepcmd
(
struct
channel
*
,
int
,
int
,
int
,
int
,
int
);
static
void
fepcmd
(
struct
channel
*
,
int
,
int
,
int
,
int
,
int
);
static
void
pcxe_put_char
(
struct
tty_struct
*
,
unsigned
char
);
static
void
pcxe_put_char
(
struct
tty_struct
*
,
unsigned
char
);
...
@@ -161,7 +159,6 @@ static void receive_data(struct channel *);
...
@@ -161,7 +159,6 @@ static void receive_data(struct channel *);
static
void
pcxxparam
(
struct
tty_struct
*
,
struct
channel
*
ch
);
static
void
pcxxparam
(
struct
tty_struct
*
,
struct
channel
*
ch
);
static
void
do_softint
(
void
*
);
static
void
do_softint
(
void
*
);
static
inline
void
pcxe_sched_event
(
struct
channel
*
,
int
);
static
inline
void
pcxe_sched_event
(
struct
channel
*
,
int
);
static
void
do_pcxe_bh
(
void
);
static
void
pcxe_start
(
struct
tty_struct
*
);
static
void
pcxe_start
(
struct
tty_struct
*
);
static
void
pcxe_stop
(
struct
tty_struct
*
);
static
void
pcxe_stop
(
struct
tty_struct
*
);
static
void
pcxe_throttle
(
struct
tty_struct
*
);
static
void
pcxe_throttle
(
struct
tty_struct
*
);
...
@@ -220,7 +217,6 @@ static void pcxe_cleanup()
...
@@ -220,7 +217,6 @@ static void pcxe_cleanup()
save_flags
(
flags
);
save_flags
(
flags
);
cli
();
cli
();
del_timer_sync
(
&
pcxx_timer
);
del_timer_sync
(
&
pcxx_timer
);
remove_bh
(
DIGI_BH
);
if
((
e1
=
tty_unregister_driver
(
pcxe_driver
)))
if
((
e1
=
tty_unregister_driver
(
pcxe_driver
)))
printk
(
"SERIAL: failed to unregister serial driver (%d)
\n
"
,
e1
);
printk
(
"SERIAL: failed to unregister serial driver (%d)
\n
"
,
e1
);
...
@@ -312,8 +308,7 @@ static inline void assertmemoff(struct channel *ch)
...
@@ -312,8 +308,7 @@ static inline void assertmemoff(struct channel *ch)
static
inline
void
pcxe_sched_event
(
struct
channel
*
info
,
int
event
)
static
inline
void
pcxe_sched_event
(
struct
channel
*
info
,
int
event
)
{
{
info
->
event
|=
1
<<
event
;
info
->
event
|=
1
<<
event
;
queue_task
(
&
info
->
tqueue
,
&
tq_pcxx
);
schedule_work
(
&
info
->
tqueue
);
mark_bh
(
DIGI_BH
);
}
}
static
void
pcxx_error
(
int
line
,
char
*
msg
)
static
void
pcxx_error
(
int
line
,
char
*
msg
)
...
@@ -1150,8 +1145,6 @@ int __init pcxe_init(void)
...
@@ -1150,8 +1145,6 @@ int __init pcxe_init(void)
}
}
memset
(
digi_channels
,
0
,
sizeof
(
struct
channel
)
*
nbdevs
);
memset
(
digi_channels
,
0
,
sizeof
(
struct
channel
)
*
nbdevs
);
init_bh
(
DIGI_BH
,
do_pcxe_bh
);
init_timer
(
&
pcxx_timer
);
init_timer
(
&
pcxx_timer
);
pcxx_timer
.
function
=
pcxxpoll
;
pcxx_timer
.
function
=
pcxxpoll
;
...
@@ -1450,8 +1443,7 @@ int __init pcxe_init(void)
...
@@ -1450,8 +1443,7 @@ int __init pcxe_init(void)
}
}
ch
->
brdchan
=
bc
;
ch
->
brdchan
=
bc
;
ch
->
mailbox
=
gd
;
ch
->
mailbox
=
gd
;
ch
->
tqueue
.
routine
=
do_softint
;
INIT_WORK
(
&
ch
->
tqueue
,
do_softint
,
ch
);
ch
->
tqueue
.
data
=
ch
;
ch
->
board
=
&
boards
[
crd
];
ch
->
board
=
&
boards
[
crd
];
#ifdef DEFAULT_HW_FLOW
#ifdef DEFAULT_HW_FLOW
ch
->
digiext
.
digi_flags
=
RTSPACE
|
CTSPACE
;
ch
->
digiext
.
digi_flags
=
RTSPACE
|
CTSPACE
;
...
@@ -2254,11 +2246,6 @@ static void pcxe_set_termios(struct tty_struct *tty, struct termios *old_termios
...
@@ -2254,11 +2246,6 @@ static void pcxe_set_termios(struct tty_struct *tty, struct termios *old_termios
}
}
static
void
do_pcxe_bh
(
void
)
{
run_task_queue
(
&
tq_pcxx
);
}
static
void
do_softint
(
void
*
private_
)
static
void
do_softint
(
void
*
private_
)
{
{
...
...
drivers/char/pcxx.h
View file @
dd99888a
...
@@ -85,10 +85,10 @@ struct channel {
...
@@ -85,10 +85,10 @@ struct channel {
int
count
;
int
count
;
int
blocked_open
;
int
blocked_open
;
int
close_delay
;
int
close_delay
;
int
event
;
unsigned
long
event
;
wait_queue_head_t
open_wait
;
wait_queue_head_t
open_wait
;
wait_queue_head_t
close_wait
;
wait_queue_head_t
close_wait
;
struct
tq
_struct
tqueue
;
struct
work
_struct
tqueue
;
/* ------------ Async control data ------------- */
/* ------------ Async control data ------------- */
unchar
modemfake
;
/* Modem values to be forced */
unchar
modemfake
;
/* Modem values to be forced */
unchar
modem
;
/* Force values */
unchar
modem
;
/* Force values */
...
...
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