summaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget/function/u_ncm.h
diff options
context:
space:
mode:
authorRomain Izard <romain.izard.pro@gmail.com>2019-04-16 16:07:32 +0200
committerFelipe Balbi <felipe.balbi@linux.intel.com>2019-05-03 08:13:47 +0200
commit793409292382027226769d0299987f06cbd97a6e (patch)
treeb03a8d710c9c2769658be58741516820aa218647 /drivers/usb/gadget/function/u_ncm.h
parentusb: gadget: f_ncm: Fix NTP-32 support (diff)
downloadlinux-793409292382027226769d0299987f06cbd97a6e.tar.xz
linux-793409292382027226769d0299987f06cbd97a6e.zip
usb: gadget: f_ncm: Add OS descriptor support
To be able to use the default USB class drivers available in Microsoft Windows, we need to add OS descriptors to the exported USB gadget to tell the OS that we are compatible with the built-in drivers. Copy the OS descriptor support from f_rndis into f_ncm. As a result, using the WINNCM compatible ID, the UsbNcm driver is loaded on enumeration without the need for a custom driver or inf file. Signed-off-by: Romain Izard <romain.izard.pro@gmail.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Diffstat (limited to 'drivers/usb/gadget/function/u_ncm.h')
-rw-r--r--drivers/usb/gadget/function/u_ncm.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/gadget/function/u_ncm.h b/drivers/usb/gadget/function/u_ncm.h
index d483e45c0f77..70da3201a1d0 100644
--- a/drivers/usb/gadget/function/u_ncm.h
+++ b/drivers/usb/gadget/function/u_ncm.h
@@ -20,6 +20,9 @@ struct f_ncm_opts {
struct net_device *net;
bool bound;
+ struct config_group *ncm_interf_group;
+ struct usb_os_desc ncm_os_desc;
+ char ncm_ext_compat_id[16];
/*
* Read/write access to configfs attributes is handled by configfs.
*