Documentation usb serial: fixed how to provide vendor and product id
Subsystems (2)
PATCH v2 1/1 Documentation usb serial: fixed how to provide vendor and product id
From: "H. Nikolaus Schaller" <[email protected]>
While trying to test a Cinterion GSM/GPS/3G module I had reconfigured the USB interface by mistake and therefore needed to run a different USB driver than CDC-ACM. It turned out that I need the "usbserial" driver.
This file is an official description how to use it: Documentation/usb/usb-serial.txt
But it is outdated. The parameters vendor= and product= are only available if compiled as a kernel module and have been superseded by a /sys interface.
Here was the solution:
https://bbs.archlinux.org/viewtopic.php?id=175499
insmod usbserial vendor=0x#### product=0x####
becomes (first #### is vendor, second is product)
modprobe usbserial
echo #### #### >/sys/bus/usb-serial/drivers/generic/new_id
This patch changes the documentation file to describe the modern variant. Please note that the old one still works (if compiled as module).
---
changes from v1:
- add modern variant with /sys as preferred but also old one works so keep it in documentation (was removed in first version which was not correct)
Documentation/usb/usb-serial.txt | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-)
Documentation/usb/usb-serial.txt +7 -4
@@ -465,12 +465,15 @@ Generic Serial driver device, and does not support any kind of device flow control. All that is required of your device is that it has at least one bulk in endpoint, or one bulk out endpoint. - - To enable the generic driver to recognize your device, build the driver - as a module and load it by the following invocation: - insmod usbserial vendor=0x#### product=0x#### + + To enable the generic driver to recognize your device, provide + echo #### #### >/sys/bus/usb-serial/drivers/generic/new_id where the #### is replaced with the hex representation of your device's vendor id and product id. + If the driver is compiled as a module, you can either + modprobe usbserial + or, you can also provide the parameters directly + insmod usbserial vendor=0x#### product=0x#### This driver has been successfully used to connect to the NetChip USB development board, providing a way to develop USB firmware without
Signature · 1 line
1.9.1
Quoted 25 lines · Marek Belisko
From: "H. Nikolaus Schaller" <[email protected]>
While trying to test a Cinterion GSM/GPS/3G module I had reconfigured the USB interface by mistake and therefore needed to run a different USB driver than CDC-ACM. It turned out that I need the "usbserial" driver.
This file is an official description how to use it:
Documentation/usb/usb-serial.txtBut it is outdated. The parameters vendor= and product= are only available if compiled as a kernel module and have been superseded by a /sys interface.
Here was the solution:
https://bbs.archlinux.org/viewtopic.php?id=175499
insmod usbserial vendor=0x#### product=0x####
becomes (first #### is vendor, second is product)
modprobe usbserial
echo #### #### >/sys/bus/usb-serial/drivers/generic/new_idThis patch changes the documentation file to describe the modern variant. Please note that the old one still works (if compiled as module).
Quoted 7 lines
Signed-off-by H. Nikolaus Schaller <[email protected]>Signed-off-by Marek Belisko <[email protected]>---
changes from v1:
- add modern variant with /sys as preferred but also old one works so keep it in documentation (was removed in first version which was not correct)
Thanks for the update. Much better.
Quoted 10 lines
Documentation/usb/usb-serial.txt | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-)Documentation/usb/usb-serial.txt +0
-0@@ -465,12 +465,15 @@ Generic Serial driver device, and does not support any kind of device flow control. All that is required of your device is that it has at least one bulk in endpoint,
Documentation/usb/usb-serial.txt Generic Serial driver · line 472
Quoted 10 lines
Documentation/usb/usb-serial.txt +3
-4or one bulk out endpoint. - - To enable the generic driver to recognize your device, build the driver - as a module and load it by the following invocation: - insmod usbserial vendor=0x#### product=0x#### + + To enable the generic driver to recognize your device, provide + echo #### #### >/sys/bus/usb-serial/drivers/generic/new_id where the #### is replaced with the hex representation of your device's vendor id and product id.
Could you use distinct symbols for vendor and product if (e.g. <vid> and <pid>) to make it clear which is which?
Documentation/usb/usb-serial.txt Generic Serial driver · line 474
Quoted 2 lines
Documentation/usb/usb-serial.txt +2
-0+ If the driver is compiled as a module, you can either + modprobe usbserial
This isn't needed.
Documentation/usb/usb-serial.txt Generic Serial driver · line 475
Quoted 1 line
Documentation/usb/usb-serial.txt +1
-0+ or, you can also provide the parameters directly
This could be "you can also provide one id when loading the module".
Documentation/usb/usb-serial.txt Generic Serial driver · line 476
Quoted 1 line
Documentation/usb/usb-serial.txt +1
-0+ insmod usbserial vendor=0x#### product=0x####
Thanks,
Johan
PATCH v2 1/1 Documentation usb serial: fixed how to provide vendor and product id
In reply to Marek BeliskoFrom: "H. Nikolaus Schaller" <[email protected]>
While trying to test a Cinterion GSM/GPS/3G module I had reconfigured the USB interface by mistake and therefore needed to run a different USB driver than CDC-ACM. It turned out that I need the "usbserial" driver.
This file is an official description how to use it: Documentation/usb/usb-serial.txt
But it is outdated. The parameters vendor= and product= are only available if compiled as a kernel module and have been superseded by a /sys interface.
Here was the solution:
https://bbs.archlinux.org/viewtopic.php?id=175499
insmod usbserial vendor=0x#### product=0x####
becomes (first #### is vendor, second is product)
modprobe usbserial
echo #### #### >/sys/bus/usb-serial/drivers/generic/new_id
This patch changes the documentation file to describe the modern variant. Please note that the old one still works (if compiled as module).
---
- fixed 2 sentences suggested by Johan Hovold
Documentation/usb/usb-serial.txt | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-)
Documentation/usb/usb-serial.txt +7 -5
@@ -465,12 +465,14 @@ Generic Serial driver device, and does not support any kind of device flow control. All that is required of your device is that it has at least one bulk in endpoint, or one bulk out endpoint. - - To enable the generic driver to recognize your device, build the driver - as a module and load it by the following invocation: + + To enable the generic driver to recognize your device, provide + echo <vid> <pid> >/sys/bus/usb-serial/drivers/generic/new_id + where the <vid> and <pid> is replaced with the hex representation of your + device's vendor id and product id. + If the driver is compiled as a module you can also provide one id when + loading the module insmod usbserial vendor=0x#### product=0x#### - where the #### is replaced with the hex representation of your device's - vendor id and product id. This driver has been successfully used to connect to the NetChip USB development board, providing a way to develop USB firmware without
Signature · 1 line
1.9.1
Quoted 22 lines · Marek Belisko
From: "H. Nikolaus Schaller" <[email protected]>
While trying to test a Cinterion GSM/GPS/3G module I had reconfigured the USB interface by mistake and therefore needed to run a different USB driver than CDC-ACM. It turned out that I need the "usbserial" driver.
This file is an official description how to use it:
Documentation/usb/usb-serial.txtBut it is outdated. The parameters vendor= and product= are only available if compiled as a kernel module and have been superseded by a /sys interface.
Here was the solution:
https://bbs.archlinux.org/viewtopic.php?id=175499
insmod usbserial vendor=0x#### product=0x####
becomes (first #### is vendor, second is product)
modprobe usbserial
echo #### #### >/sys/bus/usb-serial/drivers/generic/new_id
Quoted 8 lines
This patch changes the documentation file to describe the modern variant. Please note that the old one still works (if compiled as module).
Signed-off-by H. Nikolaus Schaller <[email protected]>Signed-off-by Marek Belisko <[email protected]>---
- fixed 2 sentences suggested by Johan Hovold
Thanks for fixing this. Looks good now.
Johan
Quoted 5 lines · Johan Hovold
Quoted 4 lines · Marek Belisko
From: "H. Nikolaus Schaller" <[email protected]>
The parameters vendor= and product= are only available if compiled as a kernel module
Really? I believe you should be able to do
usbserial.vendor=vid usbserial.product=pid
on the command line if usbserial is built-in. Not that I recommend doing that. But it should work.
Bjørn
Quoted 7 lines · Bjørn Mork
Quoted 5 lines · Johan Hovold
Quoted 4 lines · Marek Belisko
From: "H. Nikolaus Schaller" <[email protected]>
The parameters vendor= and product= are only available if compiled as a kernel module
Quoted 6 lines
Really? I believe you should be able to do
usbserial.vendor=vid usbserial.product=pid
on the command line if usbserial is built-in. Not that I recommend doing that. But it should work.
You're right, the commit message is a little misleading, but the updated documentation is correct. The current text does not mention the option to pass module parameters on the kernel command line explicitly either.
Johan
Jonathan Corbet
maintainerQuoted 10 lines · On Tue, 21 Apr 2015 15:03:10 +0200 Johan Hovold <[email protected]> wrote:
Quoted 6 lines
Really? I believe you should be able to do
usbserial.vendor=vid usbserial.product=pid
on the command line if usbserial is built-in. Not that I recommend doing that. But it should work.
You're right, the commit message is a little misleading, but the updated documentation is correct. The current text does not mention the option to pass module parameters on the kernel command line explicitly either.
OK, I've taken this into the docs tree with a commit message tweak to reflect this discussion.
Thanks,
jon