Skip to content

Commit

Permalink
usb: gadget: printer: using gadget_is_otg to check otg support at run…
Browse files Browse the repository at this point in the history
…time

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>
  • Loading branch information
Peter Chen authored and Felipe Balbi committed Feb 20, 2014
1 parent 2d1f7af commit 8679059
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/usb/gadget/printer.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 8679059

Please sign in to comment.