Re: [PATCHv2 09/10] staging: usb: gadget: Add Configurable Composite Gadget driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 11, 2012 at 02:28:42PM +0200, Andrzej Pietrasiewicz wrote:
> The Configurable Gadget driver is a composite driver that allows
> userspace to change at runtime the list of functions enabled in
> its configuration and to configure these functions. It supports
> multiple functions: acm, rndis, mass storage and accessory.
> 
> It is usually controlled by a daemon that changes the configuration
> based on user settings. For example, rndis is enabled when the user
> enables sharing the phone data connection.
> 
> As an example on how to use it, the following shell commands will
> make the gadget disconnect from the host and make it be re-enumerated
> as a composite with 1 rndis and 2 acm interfaces, and a different
> product id:
> 
> echo 0       > /sys/class/ccg_usb/ccg0/enable
> echo rndis,acm > /sys/class/ccg_usb/ccg0/functions
> echo 2       > /sys/class/ccg_usb/ccg0/f_acm/instances
> echo -n 0x2d01 > /sys/module/g_ccg/parameters/idProduct
> echo 1       > /sys/class/ccg_usb/ccg0/enable
> 
> The driver requires a gadget controller that supports software
> control of the D+ pullup and the controller driver must support
> disabling the pullup during composite_bind.
> 
> Signed-off-by: Mike Lockwood <lockwood@xxxxxxxxxxx>
> Signed-off-by: Benoit Goby <benoit@xxxxxxxxxxx>
> 	[import android.c, implement review comments, remove adb,mtp,ptp,accessory]
> Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@xxxxxxxxxxx>
> Signed-off-by: Kyungmin Park <kyungmin.park@xxxxxxxxxxx>
> ---
>  Documentation/ABI/testing/sysfs-class-ccg_usb |  128 ++++

Please put this file in drivers/staging/ccg/ as well.

>  drivers/staging/Makefile                      |    1 +
>  drivers/staging/ccg/Kconfig                   |    8 +
>  drivers/staging/ccg/Makefile                  |    4 +
>  drivers/staging/ccg/TODO                      |    6 +
>  drivers/staging/ccg/ccg.c                     |  995 +++++++++++++++++++++++++
>  drivers/usb/gadget/Kconfig                    |    2 +
>  7 files changed, 1144 insertions(+), 0 deletions(-)
>  create mode 100644 Documentation/ABI/testing/sysfs-class-ccg_usb
>  create mode 100644 drivers/staging/ccg/Kconfig
>  create mode 100644 drivers/staging/ccg/Makefile
>  create mode 100644 drivers/staging/ccg/TODO
>  create mode 100644 drivers/staging/ccg/ccg.c
> 
> diff --git a/Documentation/ABI/testing/sysfs-class-ccg_usb b/Documentation/ABI/testing/sysfs-class-ccg_usb
> new file mode 100644
> index 0000000..6317b68
> --- /dev/null
> +++ b/Documentation/ABI/testing/sysfs-class-ccg_usb
> @@ -0,0 +1,128 @@
> +What:		/sys/class/ccg_usb
> +Date:		March 2012
> +KernelVersion:	3.3

3.3 kernel?  Nice, are you going back in time now?

Please fix this...

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux