summaryrefslogtreecommitdiff
path: root/drivers/usb
diff options
context:
space:
mode:
authorFabian Frederick <fabf@skynet.be>2014-06-28 14:44:09 +0200
committerJohan Hovold <johan@kernel.org>2014-07-07 10:19:29 +0200
commitcca16d62426680b49dd3b6008d10f50156874080 (patch)
tree8a676e94ebc232b1847b61c4692ed2b38ae71b10 /drivers/usb
parent19de4278121f59aaca68492ed1a66adda0e06294 (diff)
USB: mos7840: remove unnecessary null test before kfree
Cc: Johan Hovold <jhovold@gmail.com> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: linux-usb@vger.kernel.org Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: Johan Hovold <johan@kernel.org>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/serial/mos7840.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c
index 393be562d875..3d88eefdf1d1 100644
--- a/drivers/usb/serial/mos7840.c
+++ b/drivers/usb/serial/mos7840.c
@@ -1181,10 +1181,7 @@ static void mos7840_close(struct usb_serial_port *port)
/* Freeing Write URBs */
for (j = 0; j < NUM_URBS; ++j) {
if (mos7840_port->write_urb_pool[j]) {
- if (mos7840_port->write_urb_pool[j]->transfer_buffer)
- kfree(mos7840_port->write_urb_pool[j]->
- transfer_buffer);
-
+ kfree(mos7840_port->write_urb_pool[j]->transfer_buffer);
usb_free_urb(mos7840_port->write_urb_pool[j]);
}
}