We need to use a dedicated function because we can't get charger status from an irq context and that is required by usb gadgets.
Signed-off-by: Paul Fertser <[email protected]> --- arch/arm/mach-s3c2442/mach-gta02.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-s3c2442/mach-gta02.c b/arch/arm/mach-s3c2442/mach-gta02.c index 45d209f..e0b954a 100644 --- a/arch/arm/mach-s3c2442/mach-gta02.c +++ b/arch/arm/mach-s3c2442/mach-gta02.c @@ -392,7 +392,7 @@ static int gta02_get_charger_online_status(void) { struct pcf50633 *pcf = gta02_pcf; - return pcf50633_mbc_get_status(pcf) & PCF50633_MBC_USB_ONLINE; + return pcf50633_mbc_get_usb_online_status(pcf); } static int gta02_get_charger_active_status(void) @@ -485,7 +485,7 @@ static int gta02_udc_vbus_status(void) if (!gta02_pcf) return -ENODEV; - return !!(pcf50633_mbc_get_status(pcf) & PCF50633_MBC_USB_ONLINE); + return pcf50633_mbc_get_usb_online_status(pcf); } #else /* !CONFIG_CHARGER_PCF50633 */ #define gta02_get_charger_online_status NULL -- 1.6.0.6
