Skip to content

Commit

Permalink
[PATCH] Char: mxser_new, do not null driver_data
Browse files Browse the repository at this point in the history
driver_data are initialzed to NULL from tty layer, no need to do it in the
driver.  In this case it cases oops, since driver_data may be NULL for a short
while for another closing process.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: <osv@javad.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Jiri Slaby authored and Linus Torvalds committed Feb 11, 2007
1 parent f64c84a commit 722d5e4
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions drivers/char/mxser_new.c
Original file line number Diff line number Diff line change
Expand Up @@ -927,9 +927,6 @@ static int mxser_open(struct tty_struct *tty, struct file *filp)
struct mxser_port *info;
int retval, line;

/* initialize driver_data in case something fails */
tty->driver_data = NULL;

line = tty->index;
if (line == MXSER_PORTS)
return 0;
Expand Down

0 comments on commit 722d5e4

Please sign in to comment.