Hi Wojciech, W dniu 13.03.2015 o 12:05, Wojciech Zając pisze:
Hello, I was trying to create FunctionFS based, WinUSB gadget driver on EBV SoCrates board (Altera Cyclone V SoC, dwc2 UDC), running 4.0-rc3 Kernel, but this attempt ultimately failed with 'Oops'.
<snip>
I wrote my own application for FunctionFS handling, starting with the same set of descriptors (with minor changes to EP types, etc.). This also worked as expected, but adding MS OS descriptors (using functionfs.h structures) afterwards, did not. Descriptors are accepted on ep0 write, but binding UDC causes the following: [ 563.185116] ffs_do_os_descs() [ 563.185122] ffs_do_single_os_desc() [ 563.185137] Unable to handle kernel paging request at virtual address 00ffff02
It might be a bug. That said, please see below. <snip>
I am not sure if this approach is a correct way of using OS descriptors (what about MS string descriptor?) with FunctionFS
You should set the contents of MS OS string descriptor and enable it. Here is what you can find in Documentation/ABI/testing/configfs-usb-gadget: What: /config/usb-gadget/gadget/os_desc Date: May 2014 KernelVersion: 3.16 Description: This group contains "OS String" extension handling attributes. use - flag turning "OS Desctiptors" support on/off b_vendor_code - one-byte value used for custom per-device and per-interface requests qw_sign - an identifier to be reported as "OS String" proper -- 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