aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget/dbgp.c
Commit message (Collapse)AuthorAgeFilesLines
* USB: dbpg gadget: dont mask out direction bitSven Schnelle2011-04-291-2/+2
| | | | | | | | Stripping the direction bit off will produce an invalid descriptor. Signed-off-by: Sven Schnelle <svens@stackframe.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: dbgp gadget: set MaxpacketSize0Sven Schnelle2011-04-291-0/+1
| | | | | | | | | | | The current code doesn't set it, so linux complains about it when connected, and ignores the device: [104611.068082] usb 1-5: new high speed USB device using ehci_hcd and address 127 [104611.088368] usb 1-5: Invalid ep0 maxpacket: 0 Signed-off-by: Sven Schnelle <svens@stackframe.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: dbgp gadget: fix return value of dbgp_setupSven Schnelle2011-04-291-5/+4
| | | | | | | | | | | | | | | | Current code returns 0 even if it can't handle the request. This leads to timeouts when an unhandled request is sent: Bus 001 Device 003: ID 0525:c0de Netchip Technology, Inc. Device Descriptor: [..] can't get device qualifier: Connection timed out [..] change the code to return EOPNOTSUPP in such cases. Signed-off-by: Sven Schnelle <svens@stackframe.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* usb gadget: don't save bind callback in struct usb_gadget_driverUwe Kleine-König2010-10-221-2/+1
| | | | | | | | | | | | | | | | | | | | | | To accomplish this the function to register a gadget driver takes the bind function as a second argument. To make things clearer rename the function to resemble platform_driver_probe. This fixes many section mismatches like WARNING: drivers/usb/gadget/g_printer.o(.data+0xc): Section mismatch in reference from the variable printer_driver to the function .init.text:printer_bind() The variable printer_driver references the function __init printer_bind() All callers are fixed. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> [m.nazarewicz@samsung.com: added dbgp] Signed-off-by: Michał Nazarewicz <m.nazarewicz@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: gadget: dbgp: cleanup: remove unneeded checkDan Carpenter2010-10-221-9/+7
| | | | | | | | | | | | | len is always greater than or equal to zero here. First of all, it's type is unsigned and also we only assign it numbers which are greater than or equal to zero. Removing the check lets us pull everything in an indent level. Signed-off-by: Dan Carpenter <error27@gmail.com> Acked-by: Stephane duverger <stephane.duverger@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* USB: EHCI Debug Port Device Gadgetstephane duverger2010-08-101-0/+434
This is a patch that implements an USB EHCI Debug Device using the Gadget API. This patch applies to a 2.6.35-rc3 kernel. The gadget needs a compliant usb controller that forwards the USB_DEVICE_DEBUG_MODE feature to its gadget. The gadget provides two configuration modes, one that only printk() the received data, and one that exposes a serial device to userland (/dev/ttyGSxxx). The gadget has been tested on an IGEPv2 board running a 2.6.35-rc1 kernel. The debug port was fed on the host side by a 2.6.34 kernel. Signed-off-by: Stephane Duverger <stephane.duverger@gmail.com> Cc: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>