diff mbox series

[3/3] usb: cdns3: gadget: use unsigned int for 32-bit number

Message ID 20200623031001.8469-4-peter.chen@nxp.com (mailing list archive)
State Mainlined
Commit 06825ca0182cec9444fb2fd05e759757f30f4b37
Headers show
Series usb: cdns3: improvement for usb-next | expand

Commit Message

Peter Chen June 23, 2020, 3:10 a.m. UTC
If it is 'int', it can't stands for the highest bit for 32-bit
number, since the largest 'int' is 0x7fffffff.

Reviewed-by: Jun Li <jun.li@nxp.com>
Signed-off-by: Peter Chen <peter.chen@nxp.com>
---
 drivers/usb/cdns3/gadget.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/drivers/usb/cdns3/gadget.c b/drivers/usb/cdns3/gadget.c
index 2362faf7efeb..ecd395397e2c 100644
--- a/drivers/usb/cdns3/gadget.c
+++ b/drivers/usb/cdns3/gadget.c
@@ -1812,7 +1812,7 @@  static irqreturn_t cdns3_device_thread_irq_handler(int irq, void *data)
 	struct cdns3_device *priv_dev = data;
 	irqreturn_t ret = IRQ_NONE;
 	unsigned long flags;
-	int bit;
+	unsigned int bit;
 	unsigned long reg;
 
 	spin_lock_irqsave(&priv_dev->lock, flags);