diff options
author | Devendra Naga <develkernel412222@gmail.com> | 2012-08-15 14:56:03 +0545 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-08-15 15:32:13 -0700 |
commit | 7b11eb3eaaf049586bc44e2512c5d0cd64eb79df (patch) | |
tree | 62ced3e4581379fa9446ff21aca55521bff2edf6 /drivers/staging/serqt_usb2 | |
parent | 68e071d890a5551cf08521c7d75e07b9bef00a8a (diff) |
staging: serqt_usb2: remove retval initialisation in qt_tiocmget and qt_tiocmset
in qt_tiocmset,
the retval gets assigned if we have a valid serial pointer in the critical section
(between mutex_lock and _unlock) of the code, no need to initialise this variable.
the same retval assignment follows in the qt_tiocmget function also, so remove the
initialisation here too.
Signed-off-by: Devendra Naga <develkernel412222@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/serqt_usb2')
-rw-r--r-- | drivers/staging/serqt_usb2/serqt_usb2.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/serqt_usb2/serqt_usb2.c b/drivers/staging/serqt_usb2/serqt_usb2.c index 135eb3896b39..5a5ea482a216 100644 --- a/drivers/staging/serqt_usb2/serqt_usb2.c +++ b/drivers/staging/serqt_usb2/serqt_usb2.c @@ -1412,7 +1412,7 @@ static int qt_tiocmget(struct tty_struct *tty) struct usb_serial_port *port = tty->driver_data; struct usb_serial *serial = get_usb_serial(port, __func__); struct quatech_port *qt_port = qt_get_port_private(port); - int retval = -ENODEV; + int retval; if (!serial) return -ENODEV; @@ -1430,7 +1430,7 @@ static int qt_tiocmset(struct tty_struct *tty, struct usb_serial_port *port = tty->driver_data; struct usb_serial *serial = get_usb_serial(port, __func__); struct quatech_port *qt_port = qt_get_port_private(port); - int retval = -ENODEV; + int retval; if (!serial) return -ENODEV; |