usb: musb: omap2430: don't loop indefinitely in interrupt.
When called during resume_irqs, omap2430_musb_set_vbus() is run with interrupts disabled, In that case 'jiffies' never changes so the loop can loop forever. So impose a maximum loop count and add an 'mdelay' to ensure we wait a reasonable amount of time for bit to be cleared. This fixes a hang on resume. Signed-of-by: NNeilBrown <neilb@suse.de> Signed-off-by: NFelipe Balbi <balbi@ti.com>
Showing
想要评论请 注册 或 登录