From ece1d77ed73b335319725f1d5ffa72ca3fa9b05c Mon Sep 17 00:00:00 2001 From: Chen Gang Date: Wed, 19 Dec 2012 09:18:57 +0800 Subject: [PATCH] USB: ohci: set urb->hcpriv = NULL immediately, after free it although we can not say it is surely a bug. it is better to set urb->hcpriv = NULL, after finish calling urb_free_priv. Signed-off-by: Chen Gang Acked-by: Alan Stern Signed-off-by: Greg Kroah-Hartman --- drivers/usb/host/ohci-q.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/ohci-q.c b/drivers/usb/host/ohci-q.c index 7482cfbe8c5e..88731b7c5f42 100644 --- a/drivers/usb/host/ohci-q.c +++ b/drivers/usb/host/ohci-q.c @@ -44,6 +44,7 @@ __acquires(ohci->lock) // ASSERT (urb->hcpriv != 0); urb_free_priv (ohci, urb->hcpriv); + urb->hcpriv = NULL; if (likely(status == -EINPROGRESS)) status = 0; -- 2.20.1