Fixes gcc '-Wunused-but-set-variable' warning:
drivers/usb/serial/mos7840.c: In function 'mos7840_send_cmd_write_baud_rate':
drivers/usb/serial/mos7840.c:1584:16: warning:
variable 'number' set but not used [-Wunused-but-set-variable]
drivers/usb/serial/mos7840.c: In function 'mos7840_change_port_settings':
drivers/usb/serial/mos7840.c:1695:21: warning:
variable 'serial' set but not used [-Wunused-but-set-variable]
'number' never used since introduction in commit
3f5429746d91 ("USB: Moschip
7840 USB-Serial Driver")
'serial' not used since commit
5833041f1b13 ("USB: serial: remove unnecessary
reinitialisations of urb->dev")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
int divisor = 0;
int status;
__u16 Data;
- unsigned char number;
__u16 clk_sel_val;
struct usb_serial_port *port;
if (mos7840_serial_paranoia_check(port->serial, __func__))
return -1;
- number = mos7840_port->port->port_number;
-
dev_dbg(&port->dev, "%s - baud = %d\n", __func__, baudRate);
/* reset clk_uart_sel in spregOffset */
if (baudRate > 115200) {
int status;
__u16 Data;
struct usb_serial_port *port;
- struct usb_serial *serial;
if (mos7840_port == NULL)
return;
if (mos7840_serial_paranoia_check(port->serial, __func__))
return;
- serial = port->serial;
-
if (!mos7840_port->open) {
dev_dbg(&port->dev, "%s - port not opened\n", __func__);
return;