]> git.baikalelectronics.ru Git - kernel.git/commit
usb: gadget: udc-core: allow udc class register gadget device
authorFelipe Balbi <balbi@ti.com>
Thu, 24 Jan 2013 12:52:24 +0000 (14:52 +0200)
committerFelipe Balbi <balbi@ti.com>
Mon, 18 Mar 2013 09:16:39 +0000 (11:16 +0200)
commit3b9e8dbe20958772cb3f447fb35eae7cbead27dc
tree00e341ad9d37d01667a82462b76365ca353cfe37
parent8f643e7b77fd9a8b5ef4d46b3a3643c6b680aa52
usb: gadget: udc-core: allow udc class register gadget device

Currently all UDC drivers are calling
device_register() before calling
usb_add_gadget_udc(). In order to avoid
code duplication, we can allow udc-core.c
register that device.

However that would become a really large patch,
so to cope with the meanwhile and allow us
to write bite-sized patches, we're adding
a flag which will be set by UDC driver once
it removes the code for registering the
gadget device.

Once all are converted, the new flag will
be removed.

Reviewed-by: Tomasz Figa <tomasz.figa@gmail.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/gadget/udc-core.c
include/linux/usb/gadget.h