linux-uconsole/drivers/usb/class
Thilo-Alexander Ginkel 68f760945c usb: cdc-acm: Fix acm_tty_hangup() vs. acm_tty_close() race
[Not upstream as it was fixed differently for 3.3 with a much more
"intrusive" rework of the driver - gregkh]

There is a race condition involving acm_tty_hangup() and acm_tty_close()
where hangup() would attempt to access tty->driver_data without proper
locking and NULL checking after close() has potentially already set it
to NULL.  One possibility to (sporadically) trigger this behavior is to
perform a suspend/resume cycle with a running WWAN data connection.

This patch addresses the issue by introducing a NULL check for
tty->driver_data in acm_tty_hangup() protected by open_mutex and exiting
gracefully when hangup() is invoked on a device that has already been
closed.

Signed-off-by: Thilo-Alexander Ginkel <thilo@ginkel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-01-12 11:35:53 -08:00
..
cdc-acm.c usb: cdc-acm: Fix acm_tty_hangup() vs. acm_tty_close() race 2012-01-12 11:35:53 -08:00
cdc-acm.h USB: cdc_acm: Fix oops when Droids MuIn LCD is connected 2011-05-11 15:14:28 -07:00
cdc-wdm.c USB: cdc-wdm: reset handling according to new requirements 2011-04-29 17:04:40 -07:00
Kconfig USB: add USB test and measurement class driver 2008-10-17 14:40:51 -07:00
Makefile USB: add USB test and measurement class driver 2008-10-17 14:40:51 -07:00
usblp.c llseek: automatically add .llseek fop 2010-10-15 15:53:27 +02:00
usbtmc.c USB: assign instead of equal in usbtmc.c 2011-08-17 10:55:51 -07:00