提交 b3314d9a 编写于 作者: F Felipe Contreras 提交者: Felipe Balbi

usb: musb: trivial cleanup

enabled && driver || !enabled can be simplified to !enabled || driver.
Signed-off-by: NFelipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: NFelipe Balbi <balbi@ti.com>
上级 772aed45
......@@ -245,13 +245,7 @@ static void musb_otg_notifier_work(struct work_struct *data_notifier_work)
case USB_EVENT_ID:
dev_dbg(musb->controller, "ID GND\n");
if (is_otg_enabled(musb)) {
if (musb->gadget_driver) {
pm_runtime_get_sync(musb->controller);
otg_init(musb->xceiv);
omap2430_musb_set_vbus(musb, 1);
}
} else {
if (!is_otg_enabled(musb) || musb->gadget_driver) {
pm_runtime_get_sync(musb->controller);
otg_init(musb->xceiv);
omap2430_musb_set_vbus(musb, 1);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册