aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorRoel Kluin <roel.kluin@gmail.com>2009-08-25 04:26:57 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-09-23 09:46:37 -0400
commit48d316770bd4dcf3d21b53cfa91e358280c31d69 (patch)
tree8a65b7cdfbdb23f6774e0a280f8a14e02d30cd39 /drivers
parent2912282c06f219cf1634a624653c445329b37acf (diff)
USB: double put_tty_driver(gs_tty_driver) in gserial_setup()
If the driver cannot be registered, put_tty_driver(gs_tty_driver) occurred here as well as at label fail. put_tty_driver() already occurs at label fail Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/gadget/u_serial.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/usb/gadget/u_serial.c b/drivers/usb/gadget/u_serial.c
index fc6e709f45b1..adf8260c3a6a 100644
--- a/drivers/usb/gadget/u_serial.c
+++ b/drivers/usb/gadget/u_serial.c
@@ -1114,7 +1114,6 @@ int __init gserial_setup(struct usb_gadget *g, unsigned count)
1114 /* export the driver ... */ 1114 /* export the driver ... */
1115 status = tty_register_driver(gs_tty_driver); 1115 status = tty_register_driver(gs_tty_driver);
1116 if (status) { 1116 if (status) {
1117 put_tty_driver(gs_tty_driver);
1118 pr_err("%s: cannot register, err %d\n", 1117 pr_err("%s: cannot register, err %d\n",
1119 __func__, status); 1118 __func__, status);
1120 goto fail; 1119 goto fail;