summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-05-10 18:37:18 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-05-10 18:37:18 (GMT)
commitf639554b8a3a4aac18193a0c98a4639d432c48f0 (patch)
tree5a6aba2d397baab36eac55e2b4f58faa710a6836 /drivers
parent126625e1bf3228a3db7359310344617bee878517 (diff)
downloadlinux-f639554b8a3a4aac18193a0c98a4639d432c48f0.tar.xz
USB: gadget: ci13xx_udc: fix potential crash in irq handler
As pointed out by Dan Carpenter, we should not be trying to call dev_err() on a structure that was previously determined to be NULL, that's just foolish and asking for trouble. So just delete the message, it's not going to do anyone any good to have it anyway. This problem was caused by 0f089094cde5: "usb: gadget: ci13xxx: replace home-brewed logging with dev_{err,warn,info}" Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/gadget/ci13xxx_udc.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/usb/gadget/ci13xxx_udc.c b/drivers/usb/gadget/ci13xxx_udc.c
index 560b539..5bd95b0 100644
--- a/drivers/usb/gadget/ci13xxx_udc.c
+++ b/drivers/usb/gadget/ci13xxx_udc.c
@@ -2719,10 +2719,8 @@ static irqreturn_t udc_irq(int irq, void *data)
trace(udc ? udc->dev : NULL, "");
- if (udc == NULL) {
- dev_err(udc->dev, "ENODEV");
+ if (udc == NULL)
return IRQ_HANDLED;
- }
spin_lock(&udc->lock);