kernel-janitors.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [Patch 5/5] Staging: winbond: usb_free_urb(NULL) is safe
@ 2012-09-26 18:18 Harsh Kumar
  2012-09-28 21:14 ` Pavel Machek
  0 siblings, 1 reply; 2+ messages in thread
From: Harsh Kumar @ 2012-09-26 18:18 UTC (permalink / raw)
  To: kernel-janitors

usb_free_urb(NULL) is safe. So, the check was removed.

Signed-off-by: Harsh Kumar <harsh1kumar@gmail.com>

---
 drivers/staging/winbond/wb35tx.c |    7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff -uprN a/drivers/staging/winbond/wb35tx.c b/drivers/staging/winbond/wb35tx.c
--- a/drivers/staging/winbond/wb35tx.c
+++ b/drivers/staging/winbond/wb35tx.c
@@ -170,11 +170,8 @@ void Wb35Tx_destroy(struct hw_data *pHwD
 	} while ((pWb35Tx->EP2vm_state != VM_STOP) && (pWb35Tx->EP4vm_state != VM_STOP));
 	msleep(10); /* Delay for waiting function enter 940623.1.b */
 
-	if (pWb35Tx->Tx4Urb)
-		usb_free_urb(pWb35Tx->Tx4Urb);
-
-	if (pWb35Tx->Tx2Urb)
-		usb_free_urb(pWb35Tx->Tx2Urb);
+	usb_free_urb(pWb35Tx->Tx4Urb);
+	usb_free_urb(pWb35Tx->Tx2Urb);
 
 	pr_debug("Wb35Tx_destroy OK\n");
 }

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Patch 5/5] Staging: winbond: usb_free_urb(NULL) is safe
  2012-09-26 18:18 [Patch 5/5] Staging: winbond: usb_free_urb(NULL) is safe Harsh Kumar
@ 2012-09-28 21:14 ` Pavel Machek
  0 siblings, 0 replies; 2+ messages in thread
From: Pavel Machek @ 2012-09-28 21:14 UTC (permalink / raw)
  To: kernel-janitors

On Wed 2012-09-26 23:36:15, Harsh Kumar wrote:
> usb_free_urb(NULL) is safe. So, the check was removed.
> 
> Signed-off-by: Harsh Kumar <harsh1kumar@gmail.com>

ACK.

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-09-28 21:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-26 18:18 [Patch 5/5] Staging: winbond: usb_free_urb(NULL) is safe Harsh Kumar
2012-09-28 21:14 ` Pavel Machek

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).