diff options
author | Pantelis Antoniou <panto@antoniou-consulting.com> | 2012-11-30 08:01:05 +0000 |
---|---|---|
committer | Marek Vasut <marex@denx.de> | 2012-12-17 15:38:15 +0100 |
commit | 5a413cae6a2201e0aee4741ab9e793317084707e (patch) | |
tree | 80611f1738d5cb2ed3f8951ef9b7b4617ec6dd29 /drivers | |
parent | 8b57e2f0814a2fd9aed1fa09d8279eaf90764560 (diff) |
g_dnl: Issue connect/disconnect as appropriate
Call usb_gadget_connect/usb_gadget_disconnect in g_dnl_bind/g_dnl_unbind.
Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/usb/gadget/g_dnl.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/drivers/usb/gadget/g_dnl.c b/drivers/usb/gadget/g_dnl.c index 7d87050df3d..25da73363ad 100644 --- a/drivers/usb/gadget/g_dnl.c +++ b/drivers/usb/gadget/g_dnl.c @@ -83,7 +83,12 @@ static struct usb_gadget_strings *g_dnl_composite_strings[] = { static int g_dnl_unbind(struct usb_composite_dev *cdev) { - debug("%s\n", __func__); + struct usb_gadget *gadget = cdev->gadget; + + debug("%s: calling usb_gadget_disconnect for " + "controller '%s'\n", shortname, gadget->name); + usb_gadget_disconnect(gadget); + return 0; } @@ -153,6 +158,10 @@ static int g_dnl_bind(struct usb_composite_dev *cdev) device_desc.bcdDevice = __constant_cpu_to_le16(0x9999); } + debug("%s: calling usb_gadget_connect for " + "controller '%s'\n", shortname, gadget->name); + usb_gadget_connect(gadget); + return 0; error: |