Char: tty, fix tty_port_block_til_ready waiting
PATCH 1/1 Char: tty, fix tty_port_block_til_ready waiting
Use DEFINE_WAIT instead of DECLARE_WAITQUEUE, because we use prepare/finish_wait since commit 3e3b5c087799e536871c8261b05bc28e4783c8da
(tty: use prepare/finish_wait)
Otherwise we would oops in finish_wait.
--- drivers/char/tty_port.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/char/tty_port.c +1 -1
@@ -193,7 +193,7 @@ int tty_port_block_til_ready(struct tty_port *port, {int do_clocal =0 , retval;unsigned long flags; -DECLARE_WAITQUEUE (wait, current); +DEFINE_WAIT (wait, current);int cd;/* block if port is in the process of being closed */
Signature · 1 line
1.6.3.2
Quoted 17 lines · On Tue, 16 Jun 2009 21:13:00 +0200 Jiri Slaby <[email protected]> wrote:
Use
DEFINE_WAITinstead ofDECLARE_WAITQUEUE, because we use prepare/finish_wait since commit3e3b5c087799e536871c8261b05bc28e4783c8da
(tty: use prepare/finish_wait)Otherwise we would oops in
finish_wait.Signed-off-by Jiri Slaby <[email protected]>--- drivers/char/tty_port.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)drivers/char/tty_port.c +0
-0
drivers/char/tty_port.c int tty_port_block_til_ready(struct tty_port *port, · line 196
Quoted 5 lines
drivers/char/tty_port.c +1
-1@@ -193,7 +193,7 @@ int tty_port_block_til_ready(struct tty_port *port, {int do_clocal =0 , retval;unsigned long flags; -DECLARE_WAITQUEUE (wait, current); +DEFINE_WAIT (wait, current);
That won't compile. DEFINE_WAIT(wait) will though.
Quoted 10 lines · Andrew Morton
drivers/char/tty_port.c int tty_port_block_til_ready(struct tty_port *port, · line 196
Quoted 8 lines
drivers/char/tty_port.c +1
-1@@ -193,7 +193,7 @@ int tty_port_block_til_ready(struct tty_port *port, {int do_clocal =0 , retval;unsigned long flags; -DECLARE_WAITQUEUE (wait, current); +DEFINE_WAIT (wait, current);That won't compile.
DEFINE_WAIT(wait)will though.
Ah, crap. One should teach himself using commit --amend.
Sorry.