diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2014-07-17 07:53:09 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2014-07-22 08:09:28 +0200 |
commit | 62735eec55c5fbe5609d3f0d2217e941d49277be (patch) | |
tree | 18adf87dcfd056128e69df56ff4a030b624b9422 /include/usb/gadget.h | |
parent | 32f4bd130c9c46ad7404a3e600dcea8d05008d32 (diff) | |
download | barebox-62735eec55c5fbe5609d3f0d2217e941d49277be.tar.gz barebox-62735eec55c5fbe5609d3f0d2217e941d49277be.tar.xz |
USB: gadget: specify vendor/product id with device parameters
This introduces the device parameters:
usbgadget.product
usbgadget.vendor
usbgadget.manufacturer
usbgadget.productname
These variables are used to configure the USB vendor id, product id,
manufacturer name and product name.
Previously these were configured with arguments to the usbserial
and dfu command. The parameters are device static, so it's nice to
configure it somewhere in the environment instead of when calling
dfu/usbserial. Also when other gadget drivers are added we do not
have to duplicate the option parsing further.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/usb/gadget.h')
-rw-r--r-- | include/usb/gadget.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/usb/gadget.h b/include/usb/gadget.h index 8fd8b01f52..7106f9d788 100644 --- a/include/usb/gadget.h +++ b/include/usb/gadget.h @@ -554,6 +554,11 @@ struct usb_gadget { unsigned a_hnp_support:1; unsigned a_alt_hnp_support:1; unsigned quirk_ep_out_aligned_size:1; + + uint32_t vendor_id; + uint32_t product_id; + char *manufacturer; + char *productname; }; #define work_to_gadget(w) (container_of((w), struct usb_gadget, work)) |