summaryrefslogtreecommitdiff
path: root/drivers/usb/gadget/audio.c
diff options
context:
space:
mode:
authorSebastian Andrzej Siewior <bigeasy@linutronix.de>2012-09-10 15:01:53 +0200
committerFelipe Balbi <balbi@ti.com>2012-09-10 16:12:59 +0300
commit7d16e8d3eb704f5f6eb5a271d5758b495634e8e6 (patch)
tree146c2f02239fc5df53976092384bc74ed29f7c02 /drivers/usb/gadget/audio.c
parent3b4a3fc0ba83265c0bfcfdfc3416e65e47441747 (diff)
usb: gadget: push VID/PID/USB BCD module option into gadgets
This patch moves the module options idVendor, idProduct and bcdDevice from composite.c into each gadgets. This ensures compatibility with current gadgets and removes the global variable which brings me step closer towards composite.c in libcomposite Acked-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/gadget/audio.c')
-rw-r--r--drivers/usb/gadget/audio.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/gadget/audio.c b/drivers/usb/gadget/audio.c
index 5702ce3777fb..55b593c5a9c8 100644
--- a/drivers/usb/gadget/audio.c
+++ b/drivers/usb/gadget/audio.c
@@ -13,6 +13,7 @@
#include <linux/kernel.h>
#include <linux/utsname.h>
+#include <linux/usb/composite.h>
#include "gadget_chips.h"
#define DRIVER_DESC "Linux USB Audio Gadget"
@@ -28,6 +29,7 @@
* a "gcc --combine ... part1.c part2.c part3.c ... " build would.
*/
#include "composite.c"
+USB_GADGET_COMPOSITE_OPTIONS();
/* string IDs are assigned dynamically */
@@ -174,6 +176,7 @@ static int __init audio_bind(struct usb_composite_dev *cdev)
status = usb_add_config(cdev, &audio_config_driver, audio_do_config);
if (status < 0)
goto fail;
+ usb_composite_overwrite_options(cdev, &coverwrite);
INFO(cdev, "%s, version: %s\n", DRIVER_DESC, DRIVER_VERSION);
return 0;