Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

USB: serial: navman: clean up urb->status usage

This done in anticipation of removal of urb->status, which will make
that patch easier to review and apply in the future.


Cc: <linux-usb-devel@lists.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

+4 -3
+4 -3
drivers/usb/serial/navman.c
··· 37 37 struct usb_serial_port *port = urb->context; 38 38 unsigned char *data = urb->transfer_buffer; 39 39 struct tty_struct *tty; 40 + int status = urb->status; 40 41 int result; 41 42 42 - switch (urb->status) { 43 + switch (status) { 43 44 case 0: 44 45 /* success */ 45 46 break; ··· 49 48 case -ESHUTDOWN: 50 49 /* this urb is terminated, clean up */ 51 50 dbg("%s - urb shutting down with status: %d", 52 - __FUNCTION__, urb->status); 51 + __FUNCTION__, status); 53 52 return; 54 53 default: 55 54 dbg("%s - nonzero urb status received: %d", 56 - __FUNCTION__, urb->status); 55 + __FUNCTION__, status); 57 56 goto exit; 58 57 } 59 58