* [PATCH 1/1] drivers/usb/serial/mos7840.c: remove unnecessary null test before kfree
@ 2014-06-28 12:44 Fabian Frederick
2014-07-07 8:23 ` Johan Hovold
0 siblings, 1 reply; 2+ messages in thread
From: Fabian Frederick @ 2014-06-28 12:44 UTC (permalink / raw)
To: linux-kernel
Cc: Fabian Frederick, Johan Hovold, Greg Kroah-Hartman, linux-usb
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>
---
drivers/usb/serial/mos7840.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c
index 393be56..3d88eef 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]);
}
}
--
1.8.4.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] drivers/usb/serial/mos7840.c: remove unnecessary null test before kfree
2014-06-28 12:44 [PATCH 1/1] drivers/usb/serial/mos7840.c: remove unnecessary null test before kfree Fabian Frederick
@ 2014-07-07 8:23 ` Johan Hovold
0 siblings, 0 replies; 2+ messages in thread
From: Johan Hovold @ 2014-07-07 8:23 UTC (permalink / raw)
To: Fabian Frederick
Cc: linux-kernel, Johan Hovold, Greg Kroah-Hartman, linux-usb
On Sat, Jun 28, 2014 at 02:44:09PM +0200, Fabian Frederick wrote:
> 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>
Applied, thanks.
Johan
> ---
> drivers/usb/serial/mos7840.c | 5 +----
> 1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c
> index 393be56..3d88eef 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]);
> }
> }
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-07-07 8:24 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-28 12:44 [PATCH 1/1] drivers/usb/serial/mos7840.c: remove unnecessary null test before kfree Fabian Frederick
2014-07-07 8:23 ` Johan Hovold
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).