summaryrefslogtreecommitdiff
path: root/drivers/usb/serial/ftdi_sio.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/serial/ftdi_sio.c')
-rw-r--r--drivers/usb/serial/ftdi_sio.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c
index 4afd905fe2fe..4c788c767a97 100644
--- a/drivers/usb/serial/ftdi_sio.c
+++ b/drivers/usb/serial/ftdi_sio.c
@@ -1347,9 +1347,7 @@ static int ftdi_common_startup (struct usb_serial *serial)
priv->flags = ASYNC_LOW_LATENCY;
/* Increase the size of read buffers */
- if (port->bulk_in_buffer) {
- kfree (port->bulk_in_buffer);
- }
+ kfree(port->bulk_in_buffer);
port->bulk_in_buffer = kmalloc (BUFSZ, GFP_KERNEL);
if (!port->bulk_in_buffer) {
kfree (priv);
@@ -1365,10 +1363,8 @@ static int ftdi_common_startup (struct usb_serial *serial)
usb_free_urb (port->write_urb);
port->write_urb = NULL;
}
- if (port->bulk_out_buffer) {
- kfree (port->bulk_out_buffer);
- port->bulk_out_buffer = NULL;
- }
+ kfree(port->bulk_out_buffer);
+ port->bulk_out_buffer = NULL;
usb_set_serial_port_data(serial->port[0], priv);