usb: gadget: s3c2410_udc: set value for common is_selfpowered
authorPeter Chen <peter.chen@freescale.com>
Wed, 28 Jan 2015 08:32:36 +0000 (16:32 +0800)
committerFelipe Balbi <balbi@ti.com>
Thu, 29 Jan 2015 16:35:23 +0000 (10:35 -0600)
Set value for common is_selfpowered.

Signed-off-by: Peter Chen <peter.chen@freescale.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/gadget/udc/s3c2410_udc.c

index 256a67ba2158d3ac0687719fb297ee9dc410f203..b808951491ccbfcdd949d8e78f7c1cc2b4c55f47 100644 (file)
@@ -1434,6 +1434,7 @@ static int s3c2410_udc_set_selfpowered(struct usb_gadget *gadget, int value)
 
        dprintk(DEBUG_NORMAL, "%s()\n", __func__);
 
+       gadget->is_selfpowered = (value != 0);
        if (value)
                udc->devstatus |= (1 << USB_DEVICE_SELF_POWERED);
        else