[bug report] usb: isp1760: add support for isp1763

From: Dan Carpenter <hidden>
Date: 2021-07-26 07:28:42

Hello Rui Miguel Silva,

The patch 60d789f3bfbb: "usb: isp1760: add support for isp1763" from
May 13, 2021, leads to the following static checker warning:

	drivers/usb/isp1760/isp1760-hcd.c:276 isp1760_hcd_clear_and_wait()
	warn: sleeping in atomic context

drivers/usb/isp1760/isp1760-hcd.c
    268 static int isp1760_hcd_clear_and_wait(struct usb_hcd *hcd, u32 field,
    269 				      u32 timeout_us)
    270 {
    271 	struct isp1760_hcd *priv = hcd_to_priv(hcd);
    272 	u32 val;
    273 
    274 	isp1760_hcd_clear(hcd, field);
    275 
--> 276 	return regmap_field_read_poll_timeout(priv->fields[field], val,
    277 					      !val, 10, timeout_us);
                                                            ^^
Originally this used to call read_poll_timeout() with 0 us_timeout (no
sleeping).  The caller always holds a spin_lock.

    278 }

regards,
dan carpenter
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help