History log of /drivers/usb/gadget/f_sourcesink.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
6eb0de827084060e6607c8f8542d9e9566214538 03-Jul-2011 Paul Gortmaker <paul.gortmaker@windriver.com> usb: Add module.h to drivers/usb consumers who really use it.

The situation up to this point meant that module.h was pretty
much everywhere, regardless of whether you asked for it or not.
We are fixing that, so give the USB folks who want it an actual
include of it.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
/drivers/usb/gadget/f_sourcesink.c
28c9fc68ebd32d473a8787d05c74e3f39c6c866b 09-Sep-2011 Klaus Schwarzkopf <schwarzkopf@sensortherm.de> usb gadget: clean up FSF boilerplate text

remove the following two paragraphs as they are not needed:

This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
License for more details.

You should have received a copy of the GNU General Public License along with
this program; if not, write to the Free Software Foundation, Inc.,59
Temple Place - Suite 330, Boston, MA 02111-1307, USA.

Signed-off-by: Klaus Schwarzkopf <schwarzkopf@sensortherm.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
57c97c02de0e7a59cb48d3d7666f4afaf9968e84 03-Jul-2011 Amit Blay <ablay@codeaurora.org> usb: gadget: zero: add superspeed support

This patch adds SuperSpeed descriptors to the
g_zero gadget.

The SuperSpeed descriptors were added both for
f_soursesink and f_loopback function drivers.

Signed-off-by: Tatyana Brokhman <tlinder@codeaurora.org>
Signed-off-by: Amit Blay <ablay@codeaurora.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
/drivers/usb/gadget/f_sourcesink.c
5030ec730279eabafccf862f3c8393af90c258a5 23-Jun-2011 Bob Liu <lliubbo@gmail.com> USB: gadget: fix req length in sourcesink_setup()

The recent commit 2edb11cbac fixed req->length in the composite_setup()
function, but that will cause all g_zero tests to fail like:

root#> ./testusb -D /proc/bus/usb/002/021 -t14 -c 15000 -s 256 -v 1
unknown speed /proc/bus/usb/002/021
/proc/bus/usb/002/021 test 14 --> 32 (Broken pipe)

We need to fix req->length in sourcesink_setup() as well to avoid this.

Signed-off-by: Bob Liu <lliubbo@gmail.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
ea2a1df7b2b1de839a72217d85bfb4b7b049010c 28-Jun-2011 Tatyana Brokhman <tlinder@codeaurora.org> usb: gadget: use config_ep_by_speed() instead of ep_choose()

Remove obsolete functions:
1. ep_choose()
2. usb_find_endpoint()

Signed-off-by: Tatyana Brokhman <tlinder@codeaurora.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
72c973dd2b01b212a159faa330a2bc641a3ed809 28-Jun-2011 Tatyana Brokhman <tlinder@codeaurora.org> usb: gadget: add usb_endpoint_descriptor to struct usb_ep

Change usb_ep_enable() prototype to use endpoint
descriptor from usb_ep.

This optimization spares the FDs from saving the
endpoint chosen descriptor. This optimization is
not full though. To fully exploit this change, one
needs to update all the UDCs as well since in the
current implementation each of them saves the
endpoint descriptor in it's internal (and extended)
endpoint structure.

Signed-off-by: Tatyana Brokhman <tlinder@codeaurora.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
c9bfff9c98671ad50e4abbfe1ab606a9957f7539 12-Aug-2010 Uwe Kleine-König <u.kleine-koenig@pengutronix.de> usb gadget: don't save bind callback in struct usb_configuration

The bind function is most of the time only called at init time so there
is no need to save a pointer to it in the configuration structure.

This fixes many section mismatches reported by modpost.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
[m.nazarewicz@samsung.com: updated for -next]
Signed-off-by: Michał Nazarewicz <m.nazarewicz@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
e12995ec8f8d99f2a339541fc28998af2d60af0f 12-Aug-2010 Michal Nazarewicz <m.nazarewicz@samsung.com> USB: Revert "USB: gadget: section mismatch warning fixed"

This reverts a commit which proposed an invalid solution
for a section mismatch. Next 3 commits will fix it correctly.

Conflicts:

drivers/usb/gadget/mass_storage.c

Signed-off-by: Michal Nazarewicz <m.nazarewicz@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
89ba85d4015b7fa738b35bcc228075c117a9a578 21-Jun-2010 Michal Nazarewicz <m.nazarewicz@samsung.com> USB: gadget: section mismatch warning fixed

In may gadgets bind and bind like functions were in a init section
as they were only run during initialisation. However, being
callback functions they were referenced from structures in “normal”
sections. Changing the tag from “__init” to “__ref” fixes the
warnings.

Signed-off-by: Michal Nazarewicz <m.nazarewicz@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
5a0e3ad6af8660be21ca98a971cd00f331318c05 24-Mar-2010 Tejun Heo <tj@kernel.org> include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h

percpu.h is included by sched.h and module.h and thus ends up being
included when building most .c files. percpu.h includes slab.h which
in turn includes gfp.h making everything defined by the two files
universally available and complicating inclusion dependencies.

percpu.h -> slab.h dependency is about to be removed. Prepare for
this change by updating users of gfp and slab facilities include those
headers directly instead of assuming availability. As this conversion
needs to touch large number of source files, the following script is
used as the basis of conversion.

http://userweb.kernel.org/~tj/misc/slabh-sweep.py

The script does the followings.

* Scan files for gfp and slab usages and update includes such that
only the necessary includes are there. ie. if only gfp is used,
gfp.h, if slab is used, slab.h.

* When the script inserts a new include, it looks at the include
blocks and try to put the new include such that its order conforms
to its surrounding. It's put in the include block which contains
core kernel includes, in the same order that the rest are ordered -
alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
doesn't seem to be any matching order.

* If the script can't find a place to put a new include (mostly
because the file doesn't have fitting include block), it prints out
an error message indicating which .h file needs to be added to the
file.

The conversion was done in the following steps.

1. The initial automatic conversion of all .c files updated slightly
over 4000 files, deleting around 700 includes and adding ~480 gfp.h
and ~3000 slab.h inclusions. The script emitted errors for ~400
files.

2. Each error was manually checked. Some didn't need the inclusion,
some needed manual addition while adding it to implementation .h or
embedding .c file was more appropriate for others. This step added
inclusions to around 150 files.

3. The script was run again and the output was compared to the edits
from #2 to make sure no file was left behind.

4. Several build tests were done and a couple of problems were fixed.
e.g. lib/decompress_*.c used malloc/free() wrappers around slab
APIs requiring slab.h to be added manually.

5. The script was run on all .h files but without automatically
editing them as sprinkling gfp.h and slab.h inclusions around .h
files could easily lead to inclusion dependency hell. Most gfp.h
inclusion directives were ignored as stuff from gfp.h was usually
wildly available and often used in preprocessor macros. Each
slab.h inclusion directive was examined and added manually as
necessary.

6. percpu.h was updated not to include slab.h.

7. Build test were done on the following configurations and failures
were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my
distributed build env didn't work with gcov compiles) and a few
more options had to be turned off depending on archs to make things
build (like ipr on powerpc/64 which failed due to missing writeq).

* x86 and x86_64 UP and SMP allmodconfig and a custom test config.
* powerpc and powerpc64 SMP allmodconfig
* sparc and sparc64 SMP allmodconfig
* ia64 SMP allmodconfig
* s390 SMP allmodconfig
* alpha SMP allmodconfig
* um on x86_64 SMP allmodconfig

8. percpu.h modifications were reverted so that it could be applied as
a separate patch and serve as bisection point.

Given the fact that I had only a couple of failures from tests on step
6, I'm fairly confident about the coverage of this conversion patch.
If there is a breakage, it's likely to be something in one of the arch
headers which should be easily discoverable easily on most builds of
the specific arch.

Signed-off-by: Tejun Heo <tj@kernel.org>
Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
/drivers/usb/gadget/f_sourcesink.c
2bcd57ab61e7cabed626226a3771617981c11ce1 24-Sep-2009 Alexey Dobriyan <adobriyan@gmail.com> headers: utsname.h redux

* remove asm/atomic.h inclusion from linux/utsname.h --
not needed after kref conversion
* remove linux/utsname.h inclusion from files which do not need it

NOTE: it looks like fs/binfmt_elf.c do not need utsname.h, however
due to some personality stuff it _is_ needed -- cowardly leave ELF-related
headers and files alone.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
/drivers/usb/gadget/f_sourcesink.c
ab943a2e125b098489ccaa0166c2c52f8266d9ed 19-Mar-2009 David Brownell <dbrownell@users.sourceforge.net> USB: gadget: gadget zero uses new suspend/resume hooks

Use the new device-level suspend/resume hooks for Gadget Zero;
always enable them with the OTG test mode; and support remote
wakeup on both configurations even in non-OTG mode.

This ensures that both configurations can pass the USBCV remote
wakeup tests when the OTG test mode is enabled. This changes
behavior by adding autoresume support to the loopback config
even in non-OTG mode; the test failure was that it didn't work
in OTG mode.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
551509d267905705f6d723e51ec706916f06b859 11-Feb-2009 Harvey Harrison <harvey.harrison@gmail.com> USB: replace uses of __constant_{endian}

The base versions handle constant folding now.

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
36e893d25aa2abcae0f11ef263de0e8322641386 12-Sep-2008 David Brownell <dbrownell@users.sourceforge.net> usb gadget: USB_GADGET_VBUS_DRAW Kconfig option

Offer a "how much VBUS power to request" configuration option
for USB gadgets that aren't using board-specific customization
of their gadget or (composite) configuration drivers.

Also remove a couple pointless "depends on USB_GADGET" bits
from the Kconfig text; booleans inside an "if USB_GADGET" will
already have that dependency.

Based on a patch from Justin Clacherty.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Justin Clacherty <justin@redfish-group.com>
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c
a400cadc0774c31f67c419a835d80ba611128c2a 20-Jun-2008 David Brownell <dbrownell@users.sourceforge.net> usb gadget zero: split out source/sink config

This splits the gadget zero "source/sink" configuration into a standalone
"configuration driver", building on the composite gadget framework code.
It doesn't yet pull the original code out of gadget zero or update how
that driver is built.

Neither this, nor its sibling "loopback" configuration, is a function
driver that can be combined with other functions. (The host "usbtest"
driver wouldn't know how to deal with that!) However the code becomes
simpler because of this conversion, so it's a net win.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/usb/gadget/f_sourcesink.c