linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] USB: serial: option: add Quectel EC200S-CN module support
@ 2021-09-30  2:11 Yu-Tung Chang
  2021-10-07  7:47 ` Johan Hovold
  0 siblings, 1 reply; 4+ messages in thread
From: Yu-Tung Chang @ 2021-09-30  2:11 UTC (permalink / raw)
  To: johan; +Cc: gregkh, linux-usb, linux-kernel, Yu-Tung Chang

Add usb product id of the Quectel EC200S-CN module.

usb-devices output for 0x6002:
T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  3 Spd=480 MxCh= 0
D:  Ver= 2.00 Cls=ef(misc ) Sub=02 Prot=01 MxPS=64 #Cfgs=  1
P:  Vendor=2c7c ProdID=6002 Rev=03.18
S:  Manufacturer=Android
S:  Product=Android
S:  SerialNumber=0000
C:  #Ifs= 5 Cfg#= 1 Atr=e0 MxPwr=500mA
I:  If#=0x0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=06 Prot=00 Driver=cdc_ether
I:  If#=0x1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=cdc_ether
I:  If#=0x2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
I:  If#=0x3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
I:  If#=0x4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)

Signed-off-by: Yu-Tung Chang <mtwget@gmail.com>
---
 drivers/usb/serial/option.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/usb/serial/option.c b/drivers/usb/serial/option.c
index 6cfb5d33609f..f65a2e7699bf 100644
--- a/drivers/usb/serial/option.c
+++ b/drivers/usb/serial/option.c
@@ -251,6 +251,7 @@ static void option_instat_callback(struct urb *urb);
 #define QUECTEL_PRODUCT_EP06			0x0306
 #define QUECTEL_PRODUCT_EM12			0x0512
 #define QUECTEL_PRODUCT_RM500Q			0x0800
+#define QUECTEL_PRODUCT_EC200S_CN		0x6002
 #define QUECTEL_PRODUCT_EC200T			0x6026
 
 #define CMOTECH_VENDOR_ID			0x16d8
@@ -1128,6 +1129,7 @@ static const struct usb_device_id option_ids[] = {
 	{ USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_RM500Q, 0xff, 0, 0) },
 	{ USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_RM500Q, 0xff, 0xff, 0x10),
 	  .driver_info = ZLP },
+	{ USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_EC200S_CN, 0xff, 0, 0) },
 	{ USB_DEVICE_AND_INTERFACE_INFO(QUECTEL_VENDOR_ID, QUECTEL_PRODUCT_EC200T, 0xff, 0, 0) },
 
 	{ USB_DEVICE(CMOTECH_VENDOR_ID, CMOTECH_PRODUCT_6001) },
-- 
2.33.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH v1] USB: serial: option: add Quectel EC200S-CN module support
  2021-09-30  2:11 [PATCH v1] USB: serial: option: add Quectel EC200S-CN module support Yu-Tung Chang
@ 2021-10-07  7:47 ` Johan Hovold
  2021-10-07  7:57   ` Johan Hovold
  0 siblings, 1 reply; 4+ messages in thread
From: Johan Hovold @ 2021-10-07  7:47 UTC (permalink / raw)
  To: Yu-Tung Chang; +Cc: gregkh, linux-usb, linux-kernel

On Thu, Sep 30, 2021 at 10:11:12AM +0800, Yu-Tung Chang wrote:
> Add usb product id of the Quectel EC200S-CN module.
> 
> usb-devices output for 0x6002:
> T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  3 Spd=480 MxCh= 0
> D:  Ver= 2.00 Cls=ef(misc ) Sub=02 Prot=01 MxPS=64 #Cfgs=  1
> P:  Vendor=2c7c ProdID=6002 Rev=03.18
> S:  Manufacturer=Android
> S:  Product=Android
> S:  SerialNumber=0000
> C:  #Ifs= 5 Cfg#= 1 Atr=e0 MxPwr=500mA
> I:  If#=0x0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=06 Prot=00 Driver=cdc_ether
> I:  If#=0x1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=cdc_ether
> I:  If#=0x2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
> I:  If#=0x3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
> I:  If#=0x4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)

Looks good now, but for completeness, could you also mention here what
the three ports are used for (and which is which)?

Johan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v1] USB: serial: option: add Quectel EC200S-CN module support
  2021-10-07  7:47 ` Johan Hovold
@ 2021-10-07  7:57   ` Johan Hovold
       [not found]     ` <CAHRgzyNcmhTJHC9vzS-1mbxMLVHw5bYWHVy1+KCvUF61tRnr=A@mail.gmail.com>
  0 siblings, 1 reply; 4+ messages in thread
From: Johan Hovold @ 2021-10-07  7:57 UTC (permalink / raw)
  To: Yu-Tung Chang; +Cc: gregkh, linux-usb, linux-kernel

On Thu, Oct 07, 2021 at 09:47:28AM +0200, Johan Hovold wrote:
> On Thu, Sep 30, 2021 at 10:11:12AM +0800, Yu-Tung Chang wrote:
> > Add usb product id of the Quectel EC200S-CN module.
> > 
> > usb-devices output for 0x6002:
> > T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  3 Spd=480 MxCh= 0
> > D:  Ver= 2.00 Cls=ef(misc ) Sub=02 Prot=01 MxPS=64 #Cfgs=  1
> > P:  Vendor=2c7c ProdID=6002 Rev=03.18
> > S:  Manufacturer=Android
> > S:  Product=Android
> > S:  SerialNumber=0000
> > C:  #Ifs= 5 Cfg#= 1 Atr=e0 MxPwr=500mA
> > I:  If#=0x0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=06 Prot=00 Driver=cdc_ether
> > I:  If#=0x1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=cdc_ether
> > I:  If#=0x2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
> > I:  If#=0x3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
> > I:  If#=0x4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
> 
> Looks good now, but for completeness, could you also mention here what
> the three ports are used for (and which is which)?

I've applied the patch now, so no need to resend, but please list the
three ports in a reply if you have that information.

Johan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v1] USB: serial: option: add Quectel EC200S-CN module support
       [not found]       ` <CAHRgzyO=VOCAV8oGSR15hiifp7NqHCu13KjcTrv3aA2QiURz_g@mail.gmail.com>
@ 2021-10-11  8:31         ` Johan Hovold
  0 siblings, 0 replies; 4+ messages in thread
From: Johan Hovold @ 2021-10-11  8:31 UTC (permalink / raw)
  To: Yu-Tung Chang; +Cc: linux-usb, linux-kernel

[ Adding back the lists on CC so that this gets archived. ]

On Sat, Oct 09, 2021 at 01:50:40PM +0800, Yu-Tung Chang wrote:
> Yu-Tung Chang <mtwget@gmail.com> 于2021年10月9日周六 下午1:39写道:
> >
> > Johan Hovold <johan@kernel.org> 于2021年10月7日周四 下午3:57写道:
> > >
> > > On Thu, Oct 07, 2021 at 09:47:28AM +0200, Johan Hovold wrote:
> > > > On Thu, Sep 30, 2021 at 10:11:12AM +0800, Yu-Tung Chang wrote:
> > > > > Add usb product id of the Quectel EC200S-CN module.
> > > > >
> > > > > usb-devices output for 0x6002:
> > > > > T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  3 Spd=480 MxCh= 0
> > > > > D:  Ver= 2.00 Cls=ef(misc ) Sub=02 Prot=01 MxPS=64 #Cfgs=  1
> > > > > P:  Vendor=2c7c ProdID=6002 Rev=03.18
> > > > > S:  Manufacturer=Android
> > > > > S:  Product=Android
> > > > > S:  SerialNumber=0000
> > > > > C:  #Ifs= 5 Cfg#= 1 Atr=e0 MxPwr=500mA
> > > > > I:  If#=0x0 Alt= 0 #EPs= 1 Cls=02(commc) Sub=06 Prot=00 Driver=cdc_ether
> > > > > I:  If#=0x1 Alt= 1 #EPs= 2 Cls=0a(data ) Sub=00 Prot=00 Driver=cdc_ether
> > > > > I:  If#=0x2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
> > > > > I:  If#=0x3 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
> > > > > I:  If#=0x4 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00 Driver=(none)
> > > >
> > > > Looks good now, but for completeness, could you also mention here what
> > > > the three ports are used for (and which is which)?
> > >
> > > I've applied the patch now, so no need to resend, but please list the
> > > three ports in a reply if you have that information.
> >
> > ttyUSB0 used for debugging, ttyUSB1 used for AT commands,
> > ttyUSB2 used for PPP dialing.

> and lsusb.py -i -e output info:
>   1-1               2c7c:6002 ef 5IFs [USB 2.00,   480 Mbps, 500mA]
> (Android Android 0000)
>                       (EP) 00: Control attr 00 len 07 max 040
>     1-1:1.0           (IF) 02:06:00 1EP  (Communications) cdc_ether net/usb0
>                         (EP) 87: Interrupt (4096ms) attr 03 len 07 max 040
>     1-1:1.1           (IF) 0a:00:00 2EPs (CDC Data) cdc_ether
>                         (EP) 83: Bulk attr 02 len 07 max 200
>                         (EP) 0c: Bulk attr 02 len 07 max 200
>     1-1:1.2           (IF) ff:00:00 2EPs (Vendor Specific Class) option ttyUSB0
>                         (EP) 0b: Bulk attr 02 len 07 max 200
>                         (EP) 82: Bulk attr 02 len 07 max 200
>     1-1:1.3           (IF) ff:00:00 3EPs (Vendor Specific Class) option ttyUSB1
>                         (EP) 89: Interrupt (4096ms) attr 03 len 07 max 040
>                         (EP) 86: Bulk attr 02 len 07 max 200
>                         (EP) 0f: Bulk attr 02 len 07 max 200
>     1-1:1.4           (IF) ff:00:00 3EPs (Vendor Specific Class) option ttyUSB2
>                         (EP) 81: Bulk attr 02 len 07 max 200
>                         (EP) 0a: Bulk attr 02 len 07 max 200
>                         (EP) 88: Interrupt (4096ms) attr 03 len 07 max 040

Perfect, thanks for the details.

Johan

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-10-11  8:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-30  2:11 [PATCH v1] USB: serial: option: add Quectel EC200S-CN module support Yu-Tung Chang
2021-10-07  7:47 ` Johan Hovold
2021-10-07  7:57   ` Johan Hovold
     [not found]     ` <CAHRgzyNcmhTJHC9vzS-1mbxMLVHw5bYWHVy1+KCvUF61tRnr=A@mail.gmail.com>
     [not found]       ` <CAHRgzyO=VOCAV8oGSR15hiifp7NqHCu13KjcTrv3aA2QiURz_g@mail.gmail.com>
2021-10-11  8:31         ` Johan Hovold

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).