mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-08 03:40:35 +09:00
USB: Fix compile err if not set CONFIG_USB20_OTG.
This commit is contained in:
@@ -1614,6 +1614,7 @@ void dwc_otg_pcd_start_check_vbus_work(dwc_otg_pcd_t * pcd)
|
||||
*/
|
||||
int dwc_vbus_status( void )
|
||||
{
|
||||
#ifdef CONFIG_USB20_OTG
|
||||
dwc_otg_pcd_t *pcd = 0;
|
||||
pcd = gadget_wrapper->pcd;
|
||||
|
||||
@@ -1621,7 +1622,9 @@ int dwc_vbus_status( void )
|
||||
return 0;
|
||||
else
|
||||
return pcd->vbus_status ;
|
||||
|
||||
#else
|
||||
return 0;
|
||||
#endif
|
||||
}
|
||||
EXPORT_SYMBOL(dwc_vbus_status);
|
||||
|
||||
|
||||
@@ -889,10 +889,12 @@ static int dwc_otg_control_usb_probe(struct platform_device *pdev)
|
||||
}
|
||||
gpio_direction_output(control_usb->otg_gpios->gpio, 0);
|
||||
|
||||
#ifdef CONFIG_USB20_OTG
|
||||
if(usb20otg_get_status(USB_STATUS_BVABLID)){
|
||||
rk_usb_charger_status = USB_BC_TYPE_SDP;
|
||||
schedule_delayed_work(&control_usb->usb_charger_det_work, HZ/10);
|
||||
}
|
||||
#endif
|
||||
|
||||
ret = otg_irq_detect_init(pdev);
|
||||
if (ret < 0)
|
||||
|
||||
Reference in New Issue
Block a user