TTY fixes for 2.6.34-git
Subsystems (3)
PATCH 1/1 TTY fixes for 2.6.34-git
Here are 2 bugfixes and one new device id for your 2.6.34-git tree.
Please pull from:
master.kernel.org:/pub/scm/linux/kernel/git/gregkh/tty-2.6.git/
These patches have been in the linux-next tree for a while now.
Patches will be sent to the linux-kernel mailing list, if anyone wants to see them.
thanks,
greg k-h
------------
drivers/char/isicom.c | 9 +++++++-- drivers/char/istallion.c | 2 ++ drivers/char/mxser.c | 3 ++- drivers/char/riscom8.c | 1 + drivers/char/stallion.c | 7 ++++--- drivers/serial/8250_pnp.c | 2 ++ drivers/serial/pmac_zilog.c | 4 +++- 7 files changed, 21 insertions(+), 7 deletions(-)
---------------
Alan Cox (1):
tty: Fix regressions in the char driver conversion
Julia Lawall (1):
serial: drivers/serial/pmac_zilog.c: add missing unlock
Ping Cheng (1):
serial: 8250_pnp - add Fujitsu Wacom device
PATCH 1/3 tty: Fix regressions in the char driver conversion
From: Alan Cox <[email protected]>
This forgot to update a field in the old char drivers. The fact nobody has basically noticed (except one mxser user) rather suggests most of these drivers could go into the bitbucket.
--- drivers/char/isicom.c | 9 +++++++-- drivers/char/istallion.c | 2 ++ drivers/char/mxser.c | 3 ++- drivers/char/riscom8.c | 1 + drivers/char/stallion.c | 7 ++++--- 5 files changed, 16 insertions(+), 6 deletions(-)
drivers/char/isicom.c +7 -2
@@ -879,8 +879,8 @@ static int isicom_open(struct tty_struct *tty, struct file *filp)if (tport ==NULL )return -ENODEV ; port = container_of(tport, struct isi_port, port); - card = &isi_card[BOARD (tty->index)]; + tty->driver_data = port;return tty_port_open (tport, tty, filp); }
@@ -936,7 +936,12 @@ static void isicom_shutdown(struct tty_port *port)static void isicom_close (struct tty_struct *tty,struct file *filp) {struct isi_port *ip = tty->driver_data; -struct tty_port *port = &ip->port; +struct tty_port *port; + +if (ip ==NULL ) +return ; + + port = &ip->port;if (isicom_paranoia_check (ip, tty->name,"isicom_close" ))return ;tty_port_close (port, tty, filp);
drivers/char/istallion.c +2 -0
@@ -827,6 +827,8 @@ static int stli_open(struct tty_struct *tty, struct file *filp)return -ENODEV ;if (portp->devnr <1 )return -ENODEV ; + + tty->driver_data = portp;return tty_port_open (&portp->port, tty, filp); }
drivers/char/mxser.c +2 -1
@@ -1011,6 +1011,7 @@ static int mxser_open(struct tty_struct *tty, struct file *filp)if (!info->ioaddr)return -ENODEV ; + tty->driver_data = info;return tty_port_open (&info->port, tty, filp); }
@@ -1074,7 +1075,7 @@ static void mxser_close(struct tty_struct *tty, struct file *filp)struct mxser_port *info = tty->driver_data;struct tty_port *port = &info->port; -if (tty->index ==MXSER_PORTS ) +if (tty->index ==MXSER_PORTS || info ==NULL )return ;if (tty_port_close_start (port, tty, filp) ==0 )return ;
drivers/char/riscom8.c +1 -0
@@ -909,6 +909,7 @@ static int rc_open(struct tty_struct *tty, struct file *filp)if (error)return error; + tty->driver_data = port;return tty_port_open (&port->port, tty, filp); }
drivers/char/stallion.c +4 -3
@@ -724,7 +724,6 @@ static int stl_open(struct tty_struct *tty, struct file *filp) {struct stlport *portp;struct stlbrd *brdp; -struct tty_port *port;unsigned int minordev, brdnr, panelnr;int portnr;
@@ -754,7 +753,8 @@ static int stl_open(struct tty_struct *tty, struct file *filp) portp = brdp->panels[panelnr]->ports[portnr];if (portp ==NULL )return -ENODEV ; - port = &portp->port; + + tty->driver_data = portp;return tty_port_open (&portp->port, tty, filp); }
@@ -841,7 +841,8 @@ static void stl_close(struct tty_struct *tty, struct file *filp)pr_debug ("stl_close(tty=%p,filp=%p)\n" , tty, filp); portp = tty->driver_data; -BUG_ON (portp ==NULL ); +if (portp ==NULL ) +return ;tty_port_close (&portp->port, tty, filp); }
Signature · 1 line
1.7.0.4
PATCH 2/3 serial: 8250_pnp - add Fujitsu Wacom device
In reply to Greg KHFrom: Ping Cheng <[email protected]>
Add Fujitsu Wacom 1FGT Tablet PC device
--- drivers/serial/8250_pnp.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
drivers/serial/8250_pnp.c +2 -0
@@ -348,6 +348,8 @@ static const struct pnp_device_id pnp_dev_table[] = { { "FUJ02E6", 0 },/* Fujitsu Wacom 2FGT Tablet PC device */ { "FUJ02E7", 0 }, +/* Fujitsu Wacom 1FGT Tablet PC device */ + { "FUJ02E9", 0 },/* * LG C1 EXPRESS DUAL (C1-PB11A3) touch screen (actually a FUJ02E6 in * disguise)
Signature · 1 line
1.7.0.4
PATCH 3/3 serial: drivers/serial/pmac_zilog.c: add missing unlock
In reply to Greg KHFrom: Julia Lawall <[email protected]>
In an error handling case the lock is not unlocked.
A simplified version of the semantic patch that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@r exists@
expression E1;
identifier f;
@@
f (...) { <+...
* spin_lock_irqsave (E1,...);
... when != E1
* return ...;
...+> }
// </smpl>
--- drivers/serial/pmac_zilog.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
drivers/serial/pmac_zilog.c +3 -1
@@ -752,8 +752,10 @@ static void pmz_break_ctl(struct uart_port *port, int break_state) uap->curregs[R5 ] = new_reg;/* NOTE: Not subject to 'transmitter active' rule. */ -if (ZS_IS_ASLEEP (uap)) +if (ZS_IS_ASLEEP (uap)) { +spin_unlock_irqrestore (&port->lock, flags);return ; + }write_zsreg (uap,R5 , uap->curregs[R5 ]); }
Signature · 1 line
1.7.0.4