diff options
author | Peter Chen <peter.chen@freescale.com> | 2014-01-03 16:45:13 +0800 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2014-02-20 09:17:22 -0600 |
commit | 8679059e360543b7afecd228ada6566da9f304a4 (patch) | |
tree | 43051f673bd631298cdd5512beb029c792fc9533 /drivers/usb/gadget/printer.c | |
parent | 2d1f7af3d60dd09794e0738a915d272c6c27abc5 (diff) | |
download | op-kernel-dev-8679059e360543b7afecd228ada6566da9f304a4.zip op-kernel-dev-8679059e360543b7afecd228ada6566da9f304a4.tar.gz |
usb: gadget: printer: using gadget_is_otg to check otg support at runtime
We need to use gadget_is_otg to check if the gadget is really
otg support at runtime, other composite gadget drivers have already
followed this method.
Signed-off-by: Peter Chen <peter.chen@freescale.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/gadget/printer.c')
-rw-r--r-- | drivers/usb/gadget/printer.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/gadget/printer.c b/drivers/usb/gadget/printer.c index bf7a56b..69b76ef 100644 --- a/drivers/usb/gadget/printer.c +++ b/drivers/usb/gadget/printer.c @@ -1157,7 +1157,7 @@ static int __init printer_bind_config(struct usb_configuration *c) usb_gadget_set_selfpowered(gadget); - if (gadget->is_otg) { + if (gadget_is_otg(gadget)) { otg_descriptor.bmAttributes |= USB_OTG_HNP; printer_cfg_driver.descriptors = otg_desc; printer_cfg_driver.bmAttributes |= USB_CONFIG_ATT_WAKEUP; |