Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-05-02 Thread Johan Hovold
On Thu, Apr 26, 2018 at 02:12:32PM -0500, Dan Williams wrote:
> On Thu, 2018-04-26 at 18:29 +0200, Johan Hovold wrote:
> > On Thu, Apr 26, 2018 at 11:22:25PM +0700, Lars Melin wrote:
> > > On 4/26/2018 23:12, Johan Hovold wrote:
> > > > On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:
> > > > > On 4/26/2018 18:39, Lars Melin wrote:
> > > > > > On 4/26/2018 18:19, Bjørn Mork wrote:
> > > > > > > Anyway, Qualcomm based designs are definitely handled by
> > > > > > > both drivers.  Using qcserial only makes sense if the
> > > > > > > interface layout matches one of the defined shared
> > > > > > > schemes, which currently are:
> > > > > > > 
> > > > > > >  QCSERIAL_G2K = 0,/* Gobi 2000 */
> > > > > > >  QCSERIAL_G1K = 1,/* Gobi 1000 */
> > > > > > >  QCSERIAL_SWI = 2,/* Sierra Wireless */
> > > > > > >  QCSERIAL_HWI = 3,/* Huawei */
> > > > > > 
> > > > > > It seems to me that this Quectel device matches the
> > > > > > interface layout for Gobi1K:
> > > >
> > > > Yeah, but qcserial appears to select a different altsetting for
> > > > the DM port for Gobi 1000, an altsetting which this particular
> > > > device does not have.
> > > > 
> > > > I didn't re-read the full thread I referred to earlier, but I
> > > > think in it, Dan mentioned Gobi 1000 device requiring firmware
> > > > to be loaded too.
> > > > 
> > > > So if it's not a G1K device, we probably shouldn't be using
> > > > qcserial even if the interface layout happens to match.
> > >
> > > Good point, I forgot about the required firmware loading for
> > > Gobi1K.
> > > So this device should be handled by the option driver.
> > 
> > Yeah, we probably should document all of this at some point. :)
> > 
> > I didn't include the patch in this weeks -rc updates, but I've
> > queued it up for the next batch.
> 
> Option is likely the right driver for this device.
> 
> qcaux was mainly for mobile phones that have a TTY (often cdc-acm) as
> the modem port and a secondary DIAG/DM port driven by qcaux.  The DM
> port doesn't have an interrupt endpoint thus it's not a normal modem
> port requiring the larger buffers of option and its control signaling.
> 
> qcserial (as Bjorn mentioned) is only for actual Gobi-type devices with
> the specific layouts and the firmware loading requirement where the 1K
> and 2K devices start in a special 1-port mode waiting for firmware and
> then become 4-port devices on firmware reboot.

Thanks for that summary. I've applied SZ's patch now.

Johan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-05-02 Thread Johan Hovold
On Thu, Apr 26, 2018 at 02:12:32PM -0500, Dan Williams wrote:
> On Thu, 2018-04-26 at 18:29 +0200, Johan Hovold wrote:
> > On Thu, Apr 26, 2018 at 11:22:25PM +0700, Lars Melin wrote:
> > > On 4/26/2018 23:12, Johan Hovold wrote:
> > > > On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:
> > > > > On 4/26/2018 18:39, Lars Melin wrote:
> > > > > > On 4/26/2018 18:19, Bjørn Mork wrote:
> > > > > > > Anyway, Qualcomm based designs are definitely handled by
> > > > > > > both drivers.  Using qcserial only makes sense if the
> > > > > > > interface layout matches one of the defined shared
> > > > > > > schemes, which currently are:
> > > > > > > 
> > > > > > >  QCSERIAL_G2K = 0,/* Gobi 2000 */
> > > > > > >  QCSERIAL_G1K = 1,/* Gobi 1000 */
> > > > > > >  QCSERIAL_SWI = 2,/* Sierra Wireless */
> > > > > > >  QCSERIAL_HWI = 3,/* Huawei */
> > > > > > 
> > > > > > It seems to me that this Quectel device matches the
> > > > > > interface layout for Gobi1K:
> > > >
> > > > Yeah, but qcserial appears to select a different altsetting for
> > > > the DM port for Gobi 1000, an altsetting which this particular
> > > > device does not have.
> > > > 
> > > > I didn't re-read the full thread I referred to earlier, but I
> > > > think in it, Dan mentioned Gobi 1000 device requiring firmware
> > > > to be loaded too.
> > > > 
> > > > So if it's not a G1K device, we probably shouldn't be using
> > > > qcserial even if the interface layout happens to match.
> > >
> > > Good point, I forgot about the required firmware loading for
> > > Gobi1K.
> > > So this device should be handled by the option driver.
> > 
> > Yeah, we probably should document all of this at some point. :)
> > 
> > I didn't include the patch in this weeks -rc updates, but I've
> > queued it up for the next batch.
> 
> Option is likely the right driver for this device.
> 
> qcaux was mainly for mobile phones that have a TTY (often cdc-acm) as
> the modem port and a secondary DIAG/DM port driven by qcaux.  The DM
> port doesn't have an interrupt endpoint thus it's not a normal modem
> port requiring the larger buffers of option and its control signaling.
> 
> qcserial (as Bjorn mentioned) is only for actual Gobi-type devices with
> the specific layouts and the firmware loading requirement where the 1K
> and 2K devices start in a special 1-port mode waiting for firmware and
> then become 4-port devices on firmware reboot.

Thanks for that summary. I've applied SZ's patch now.

Johan


RE: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread 林上智


> 
> Option is likely the right driver for this device.
> 
> qcaux was mainly for mobile phones that have a TTY (often cdc-acm) as the 
> modem port
> and a secondary DIAG/DM port driven by qcaux.  The DM port doesn't have an 
> interrupt
> endpoint thus it's not a normal modem port requiring the larger buffers of 
> option and its
> control signaling.
> 
> qcserial (as Bjorn mentioned) is only for actual Gobi-type devices with the 
> specific layouts
> and the firmware loading requirement where the 1K and 2K devices start in a 
> special
> 1-port mode waiting for firmware and then become 4-port devices on firmware 
> reboot.
> 
> Dan

Thank you all. I believe that many people are confused in selecting serial 
driver (option and qcserial) 
for QUALCOMM based module. This thread has provided clearly and properly 
presented the different
between them.

SZ


RE: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread 林上智


> 
> Option is likely the right driver for this device.
> 
> qcaux was mainly for mobile phones that have a TTY (often cdc-acm) as the 
> modem port
> and a secondary DIAG/DM port driven by qcaux.  The DM port doesn't have an 
> interrupt
> endpoint thus it's not a normal modem port requiring the larger buffers of 
> option and its
> control signaling.
> 
> qcserial (as Bjorn mentioned) is only for actual Gobi-type devices with the 
> specific layouts
> and the firmware loading requirement where the 1K and 2K devices start in a 
> special
> 1-port mode waiting for firmware and then become 4-port devices on firmware 
> reboot.
> 
> Dan

Thank you all. I believe that many people are confused in selecting serial 
driver (option and qcserial) 
for QUALCOMM based module. This thread has provided clearly and properly 
presented the different
between them.

SZ


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Dan Williams
On Thu, 2018-04-26 at 18:29 +0200, Johan Hovold wrote:
> On Thu, Apr 26, 2018 at 11:22:25PM +0700, Lars Melin wrote:
> > On 4/26/2018 23:12, Johan Hovold wrote:
> > > On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:
> > > > On 4/26/2018 18:39, Lars Melin wrote:
> > > > > On 4/26/2018 18:19, Bjørn Mork wrote:
> > > > > > Anyway, Qualcomm based designs are definitely handled by
> > > > > > both drivers.
> > > > > > Using qcserial only makes sense if the interface layout
> > > > > > matches one of
> > > > > > the defined shared schemes, which currently are:
> > > > > > 
> > > > > >  QCSERIAL_G2K = 0,/* Gobi 2000 */
> > > > > >  QCSERIAL_G1K = 1,/* Gobi 1000 */
> > > > > >  QCSERIAL_SWI = 2,/* Sierra Wireless */
> > > > > >  QCSERIAL_HWI = 3,/* Huawei */
> > > > > 
> > > > > It seems to me that this Quectel device matches the interface
> > > > > layout for
> > > > > Gobi1K:
> > > Yeah, but qcserial appears to select a different altsetting for
> > > the DM
> > > port for Gobi 1000, an altsetting which this particular device
> > > does not
> > > have.
> > > 
> > > I didn't re-read the full thread I referred to earlier, but I
> > > think in
> > > it, Dan mentioned Gobi 1000 device requiring firmware to be
> > > loaded too.
> > > 
> > > So if it's not a G1K device, we probably shouldn't be using
> > > qcserial
> > > even if the interface layout happens to match.
> > Good point, I forgot about the required firmware loading for
> > Gobi1K.
> > So this device should be handled by the option driver.
> 
> Yeah, we probably should document all of this at some point. :)
> 
> I didn't include the patch in this weeks -rc updates, but I've queued
> it
> up for the next batch.

Option is likely the right driver for this device.

qcaux was mainly for mobile phones that have a TTY (often cdc-acm) as
the modem port and a secondary DIAG/DM port driven by qcaux.  The DM
port doesn't have an interrupt endpoint thus it's not a normal modem
port requiring the larger buffers of option and its control signaling.

qcserial (as Bjorn mentioned) is only for actual Gobi-type devices with
the specific layouts and the firmware loading requirement where the 1K
and 2K devices start in a special 1-port mode waiting for firmware and
then become 4-port devices on firmware reboot.

Dan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Dan Williams
On Thu, 2018-04-26 at 18:29 +0200, Johan Hovold wrote:
> On Thu, Apr 26, 2018 at 11:22:25PM +0700, Lars Melin wrote:
> > On 4/26/2018 23:12, Johan Hovold wrote:
> > > On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:
> > > > On 4/26/2018 18:39, Lars Melin wrote:
> > > > > On 4/26/2018 18:19, Bjørn Mork wrote:
> > > > > > Anyway, Qualcomm based designs are definitely handled by
> > > > > > both drivers.
> > > > > > Using qcserial only makes sense if the interface layout
> > > > > > matches one of
> > > > > > the defined shared schemes, which currently are:
> > > > > > 
> > > > > >  QCSERIAL_G2K = 0,/* Gobi 2000 */
> > > > > >  QCSERIAL_G1K = 1,/* Gobi 1000 */
> > > > > >  QCSERIAL_SWI = 2,/* Sierra Wireless */
> > > > > >  QCSERIAL_HWI = 3,/* Huawei */
> > > > > 
> > > > > It seems to me that this Quectel device matches the interface
> > > > > layout for
> > > > > Gobi1K:
> > > Yeah, but qcserial appears to select a different altsetting for
> > > the DM
> > > port for Gobi 1000, an altsetting which this particular device
> > > does not
> > > have.
> > > 
> > > I didn't re-read the full thread I referred to earlier, but I
> > > think in
> > > it, Dan mentioned Gobi 1000 device requiring firmware to be
> > > loaded too.
> > > 
> > > So if it's not a G1K device, we probably shouldn't be using
> > > qcserial
> > > even if the interface layout happens to match.
> > Good point, I forgot about the required firmware loading for
> > Gobi1K.
> > So this device should be handled by the option driver.
> 
> Yeah, we probably should document all of this at some point. :)
> 
> I didn't include the patch in this weeks -rc updates, but I've queued
> it
> up for the next batch.

Option is likely the right driver for this device.

qcaux was mainly for mobile phones that have a TTY (often cdc-acm) as
the modem port and a secondary DIAG/DM port driven by qcaux.  The DM
port doesn't have an interrupt endpoint thus it's not a normal modem
port requiring the larger buffers of option and its control signaling.

qcserial (as Bjorn mentioned) is only for actual Gobi-type devices with
the specific layouts and the firmware loading requirement where the 1K
and 2K devices start in a special 1-port mode waiting for firmware and
then become 4-port devices on firmware reboot.

Dan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Johan Hovold
On Thu, Apr 26, 2018 at 11:22:25PM +0700, Lars Melin wrote:
> On 4/26/2018 23:12, Johan Hovold wrote:
> > On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:
> >> On 4/26/2018 18:39, Lars Melin wrote:
> >>> On 4/26/2018 18:19, Bjørn Mork wrote:
>  Anyway, Qualcomm based designs are definitely handled by both drivers.
>  Using qcserial only makes sense if the interface layout matches one of
>  the defined shared schemes, which currently are:
> 
>   QCSERIAL_G2K = 0,    /* Gobi 2000 */
>   QCSERIAL_G1K = 1,    /* Gobi 1000 */
>   QCSERIAL_SWI = 2,    /* Sierra Wireless */
>   QCSERIAL_HWI = 3,    /* Huawei */
> >>>
> >>> It seems to me that this Quectel device matches the interface layout for
> >>> Gobi1K:

> > Yeah, but qcserial appears to select a different altsetting for the DM
> > port for Gobi 1000, an altsetting which this particular device does not
> > have.
> > 
> > I didn't re-read the full thread I referred to earlier, but I think in
> > it, Dan mentioned Gobi 1000 device requiring firmware to be loaded too.
> > 
> > So if it's not a G1K device, we probably shouldn't be using qcserial
> > even if the interface layout happens to match.

> Good point, I forgot about the required firmware loading for Gobi1K.
> So this device should be handled by the option driver.

Yeah, we probably should document all of this at some point. :)

I didn't include the patch in this weeks -rc updates, but I've queued it
up for the next batch.

Thanks everyone.

Johan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Johan Hovold
On Thu, Apr 26, 2018 at 11:22:25PM +0700, Lars Melin wrote:
> On 4/26/2018 23:12, Johan Hovold wrote:
> > On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:
> >> On 4/26/2018 18:39, Lars Melin wrote:
> >>> On 4/26/2018 18:19, Bjørn Mork wrote:
>  Anyway, Qualcomm based designs are definitely handled by both drivers.
>  Using qcserial only makes sense if the interface layout matches one of
>  the defined shared schemes, which currently are:
> 
>   QCSERIAL_G2K = 0,    /* Gobi 2000 */
>   QCSERIAL_G1K = 1,    /* Gobi 1000 */
>   QCSERIAL_SWI = 2,    /* Sierra Wireless */
>   QCSERIAL_HWI = 3,    /* Huawei */
> >>>
> >>> It seems to me that this Quectel device matches the interface layout for
> >>> Gobi1K:

> > Yeah, but qcserial appears to select a different altsetting for the DM
> > port for Gobi 1000, an altsetting which this particular device does not
> > have.
> > 
> > I didn't re-read the full thread I referred to earlier, but I think in
> > it, Dan mentioned Gobi 1000 device requiring firmware to be loaded too.
> > 
> > So if it's not a G1K device, we probably shouldn't be using qcserial
> > even if the interface layout happens to match.

> Good point, I forgot about the required firmware loading for Gobi1K.
> So this device should be handled by the option driver.

Yeah, we probably should document all of this at some point. :)

I didn't include the patch in this weeks -rc updates, but I've queued it
up for the next batch.

Thanks everyone.

Johan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Lars Melin

On 4/26/2018 23:12, Johan Hovold wrote:

On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:

On 4/26/2018 18:39, Lars Melin wrote:

On 4/26/2018 18:19, Bjørn Mork wrote:

Anyway, Qualcomm based designs are definitely handled by both drivers.
Using qcserial only makes sense if the interface layout matches one of
the defined shared schemes, which currently are:

 QCSERIAL_G2K = 0,    /* Gobi 2000 */
 QCSERIAL_G1K = 1,    /* Gobi 1000 */
 QCSERIAL_SWI = 2,    /* Sierra Wireless */
 QCSERIAL_HWI = 3,    /* Huawei */


It seems to me that this Quectel device matches the interface layout for
Gobi1K:

   * Gobi 1K USB layout:
   * 0: DM/DIAG (use libqcdm from ModemManager for communication)
   * 1: serial port (doesn't respond)
   * 2: AT-capable modem port
   * 3: QMI/net
   */



Ublox, not Quectel..


Yeah, but qcserial appears to select a different altsetting for the DM
port for Gobi 1000, an altsetting which this particular device does not
have.

I didn't re-read the full thread I referred to earlier, but I think in
it, Dan mentioned Gobi 1000 device requiring firmware to be loaded too.

So if it's not a G1K device, we probably shouldn't be using qcserial
even if the interface layout happens to match.

Thanks,
Johan


Good point, I forgot about the required firmware loading for Gobi1K.
So this device should be handled by the option driver.

/Lars




Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Lars Melin

On 4/26/2018 23:12, Johan Hovold wrote:

On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:

On 4/26/2018 18:39, Lars Melin wrote:

On 4/26/2018 18:19, Bjørn Mork wrote:

Anyway, Qualcomm based designs are definitely handled by both drivers.
Using qcserial only makes sense if the interface layout matches one of
the defined shared schemes, which currently are:

 QCSERIAL_G2K = 0,    /* Gobi 2000 */
 QCSERIAL_G1K = 1,    /* Gobi 1000 */
 QCSERIAL_SWI = 2,    /* Sierra Wireless */
 QCSERIAL_HWI = 3,    /* Huawei */


It seems to me that this Quectel device matches the interface layout for
Gobi1K:

   * Gobi 1K USB layout:
   * 0: DM/DIAG (use libqcdm from ModemManager for communication)
   * 1: serial port (doesn't respond)
   * 2: AT-capable modem port
   * 3: QMI/net
   */



Ublox, not Quectel..


Yeah, but qcserial appears to select a different altsetting for the DM
port for Gobi 1000, an altsetting which this particular device does not
have.

I didn't re-read the full thread I referred to earlier, but I think in
it, Dan mentioned Gobi 1000 device requiring firmware to be loaded too.

So if it's not a G1K device, we probably shouldn't be using qcserial
even if the interface layout happens to match.

Thanks,
Johan


Good point, I forgot about the required firmware loading for Gobi1K.
So this device should be handled by the option driver.

/Lars




Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Johan Hovold
On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:
> On 4/26/2018 18:39, Lars Melin wrote:
> > On 4/26/2018 18:19, Bjørn Mork wrote:
> >> Anyway, Qualcomm based designs are definitely handled by both drivers.
> >> Using qcserial only makes sense if the interface layout matches one of
> >> the defined shared schemes, which currently are:
> >>
> >> QCSERIAL_G2K = 0,    /* Gobi 2000 */
> >> QCSERIAL_G1K = 1,    /* Gobi 1000 */
> >> QCSERIAL_SWI = 2,    /* Sierra Wireless */
> >> QCSERIAL_HWI = 3,    /* Huawei */
> > 
> > It seems to me that this Quectel device matches the interface layout for 
> > Gobi1K:
> > 
> >   * Gobi 1K USB layout:
> >   * 0: DM/DIAG (use libqcdm from ModemManager for communication)
> >   * 1: serial port (doesn't respond)
> >   * 2: AT-capable modem port
> >   * 3: QMI/net
> >   */

> Ublox, not Quectel..

Yeah, but qcserial appears to select a different altsetting for the DM
port for Gobi 1000, an altsetting which this particular device does not
have.

I didn't re-read the full thread I referred to earlier, but I think in
it, Dan mentioned Gobi 1000 device requiring firmware to be loaded too. 

So if it's not a G1K device, we probably shouldn't be using qcserial
even if the interface layout happens to match.

Thanks,
Johan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Johan Hovold
On Thu, Apr 26, 2018 at 06:40:46PM +0700, Lars Melin wrote:
> On 4/26/2018 18:39, Lars Melin wrote:
> > On 4/26/2018 18:19, Bjørn Mork wrote:
> >> Anyway, Qualcomm based designs are definitely handled by both drivers.
> >> Using qcserial only makes sense if the interface layout matches one of
> >> the defined shared schemes, which currently are:
> >>
> >> QCSERIAL_G2K = 0,    /* Gobi 2000 */
> >> QCSERIAL_G1K = 1,    /* Gobi 1000 */
> >> QCSERIAL_SWI = 2,    /* Sierra Wireless */
> >> QCSERIAL_HWI = 3,    /* Huawei */
> > 
> > It seems to me that this Quectel device matches the interface layout for 
> > Gobi1K:
> > 
> >   * Gobi 1K USB layout:
> >   * 0: DM/DIAG (use libqcdm from ModemManager for communication)
> >   * 1: serial port (doesn't respond)
> >   * 2: AT-capable modem port
> >   * 3: QMI/net
> >   */

> Ublox, not Quectel..

Yeah, but qcserial appears to select a different altsetting for the DM
port for Gobi 1000, an altsetting which this particular device does not
have.

I didn't re-read the full thread I referred to earlier, but I think in
it, Dan mentioned Gobi 1000 device requiring firmware to be loaded too. 

So if it's not a G1K device, we probably shouldn't be using qcserial
even if the interface layout happens to match.

Thanks,
Johan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Lars Melin

On 4/26/2018 18:39, Lars Melin wrote:

On 4/26/2018 18:19, Bjørn Mork wrote:

Anyway, Qualcomm based designs are definitely handled by both drivers.
Using qcserial only makes sense if the interface layout matches one of
the defined shared schemes, which currently are:

QCSERIAL_G2K = 0,    /* Gobi 2000 */
QCSERIAL_G1K = 1,    /* Gobi 1000 */
QCSERIAL_SWI = 2,    /* Sierra Wireless */
QCSERIAL_HWI = 3,    /* Huawei */


It seems to me that this Quectel device matches the interface layout for 
Gobi1K:


  * Gobi 1K USB layout:
  * 0: DM/DIAG (use libqcdm from ModemManager for communication)
  * 1: serial port (doesn't respond)
  * 2: AT-capable modem port
  * 3: QMI/net
  */

/Lars


Ublox, not Quectel..



Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Lars Melin

On 4/26/2018 18:39, Lars Melin wrote:

On 4/26/2018 18:19, Bjørn Mork wrote:

Anyway, Qualcomm based designs are definitely handled by both drivers.
Using qcserial only makes sense if the interface layout matches one of
the defined shared schemes, which currently are:

QCSERIAL_G2K = 0,    /* Gobi 2000 */
QCSERIAL_G1K = 1,    /* Gobi 1000 */
QCSERIAL_SWI = 2,    /* Sierra Wireless */
QCSERIAL_HWI = 3,    /* Huawei */


It seems to me that this Quectel device matches the interface layout for 
Gobi1K:


  * Gobi 1K USB layout:
  * 0: DM/DIAG (use libqcdm from ModemManager for communication)
  * 1: serial port (doesn't respond)
  * 2: AT-capable modem port
  * 3: QMI/net
  */

/Lars


Ublox, not Quectel..



Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Lars Melin

On 4/26/2018 18:19, Bjørn Mork wrote:

Anyway, Qualcomm based designs are definitely handled by both drivers.
Using qcserial only makes sense if the interface layout matches one of
the defined shared schemes, which currently are:

QCSERIAL_G2K = 0,   /* Gobi 2000 */
QCSERIAL_G1K = 1,   /* Gobi 1000 */
QCSERIAL_SWI = 2,   /* Sierra Wireless */
QCSERIAL_HWI = 3,   /* Huawei */


It seems to me that this Quectel device matches the interface layout for 
Gobi1K:


 * Gobi 1K USB layout:
 * 0: DM/DIAG (use libqcdm from ModemManager for communication)
 * 1: serial port (doesn't respond)
 * 2: AT-capable modem port
 * 3: QMI/net
 */

/Lars


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Lars Melin

On 4/26/2018 18:19, Bjørn Mork wrote:

Anyway, Qualcomm based designs are definitely handled by both drivers.
Using qcserial only makes sense if the interface layout matches one of
the defined shared schemes, which currently are:

QCSERIAL_G2K = 0,   /* Gobi 2000 */
QCSERIAL_G1K = 1,   /* Gobi 1000 */
QCSERIAL_SWI = 2,   /* Sierra Wireless */
QCSERIAL_HWI = 3,   /* Huawei */


It seems to me that this Quectel device matches the interface layout for 
Gobi1K:


 * Gobi 1K USB layout:
 * 0: DM/DIAG (use libqcdm from ModemManager for communication)
 * 1: serial port (doesn't respond)
 * 2: AT-capable modem port
 * 3: QMI/net
 */

/Lars


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Bjørn Mork
Johan Hovold  writes:
> On Thu, Apr 26, 2018 at 02:48:54PM +0700, Lars Melin wrote:
>> On 4/26/2018 14:09, Johan Hovold wrote:
>> > On Thu, Apr 26, 2018 at 02:28:31PM +0800, SZ Lin (林上智) wrote:
>> >> This patch adds support for ublox R410M PID 0x90b2 USB modem to option
>> >> driver, this module supports LTE Cat M1 / NB1.
>> >>
>> >> Interface layout:
>> >> 0: QCDM/DIAG
>> >> 1: ADB
>> >> 2: AT
>> >> 3: RMNET
>> >>
>> >> Signed-off-by: SZ Lin (林上智) 
>> >> Cc: stable 
>> > 
>> > Applied, thanks.
>> > 
>> > Johan
>> 
>> With a Qualcomm Device Management interface, shouldn't this modem be 
>> driven by qcserial?
>
> Hmm, we already have some QCDM interfaces handled by option and qcaux so
> it's not that clear-cut.
>
> Dan and Björn had a discussion about this a while back, so adding them
> on CC. It seems to me that this device does not fit the intended use (or
> Gobi 1000 layout) for qcserial, but I may be mistaken.

tl;dr; I don't think qcserial is relevant unless a device matches one of
the pre-defined layout schemes.

But I'm too new in this game to say anything about the initial
intentions... 

My view of the present situation is that qcserial handles interface
layouts shared among many devices, while option handles interface
layouts which are unique per device, and vendor+class based function
mappings.  But I could be wrong.

Anyway, Qualcomm based designs are definitely handled by both drivers.
Using qcserial only makes sense if the interface layout matches one of
the defined shared schemes, which currently are:

QCSERIAL_G2K = 0,   /* Gobi 2000 */
QCSERIAL_G1K = 1,   /* Gobi 1000 */
QCSERIAL_SWI = 2,   /* Sierra Wireless */
QCSERIAL_HWI = 3,   /* Huawei */

or if similar logic is added for a new vendor/shceme

And I see multi-vendor-id usage as the main reason for these
schemes. There isn't much reason if you can make it a single match
against a vendor-id.

The original Gobi devices are obviously multi-vendor, and Sierra
Wireless and Huwaei are OEMs making devices for a number of laptop
vendors. This causes traditional vendor-id matching to fail, as e.g. a
HP device can be made by either OEMs (or others). qcserial has become a
convenient way to map a long list of full device IDs to a specific OEM
layout.


Bjørn





Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Bjørn Mork
Johan Hovold  writes:
> On Thu, Apr 26, 2018 at 02:48:54PM +0700, Lars Melin wrote:
>> On 4/26/2018 14:09, Johan Hovold wrote:
>> > On Thu, Apr 26, 2018 at 02:28:31PM +0800, SZ Lin (林上智) wrote:
>> >> This patch adds support for ublox R410M PID 0x90b2 USB modem to option
>> >> driver, this module supports LTE Cat M1 / NB1.
>> >>
>> >> Interface layout:
>> >> 0: QCDM/DIAG
>> >> 1: ADB
>> >> 2: AT
>> >> 3: RMNET
>> >>
>> >> Signed-off-by: SZ Lin (林上智) 
>> >> Cc: stable 
>> > 
>> > Applied, thanks.
>> > 
>> > Johan
>> 
>> With a Qualcomm Device Management interface, shouldn't this modem be 
>> driven by qcserial?
>
> Hmm, we already have some QCDM interfaces handled by option and qcaux so
> it's not that clear-cut.
>
> Dan and Björn had a discussion about this a while back, so adding them
> on CC. It seems to me that this device does not fit the intended use (or
> Gobi 1000 layout) for qcserial, but I may be mistaken.

tl;dr; I don't think qcserial is relevant unless a device matches one of
the pre-defined layout schemes.

But I'm too new in this game to say anything about the initial
intentions... 

My view of the present situation is that qcserial handles interface
layouts shared among many devices, while option handles interface
layouts which are unique per device, and vendor+class based function
mappings.  But I could be wrong.

Anyway, Qualcomm based designs are definitely handled by both drivers.
Using qcserial only makes sense if the interface layout matches one of
the defined shared schemes, which currently are:

QCSERIAL_G2K = 0,   /* Gobi 2000 */
QCSERIAL_G1K = 1,   /* Gobi 1000 */
QCSERIAL_SWI = 2,   /* Sierra Wireless */
QCSERIAL_HWI = 3,   /* Huawei */

or if similar logic is added for a new vendor/shceme

And I see multi-vendor-id usage as the main reason for these
schemes. There isn't much reason if you can make it a single match
against a vendor-id.

The original Gobi devices are obviously multi-vendor, and Sierra
Wireless and Huwaei are OEMs making devices for a number of laptop
vendors. This causes traditional vendor-id matching to fail, as e.g. a
HP device can be made by either OEMs (or others). qcserial has become a
convenient way to map a long list of full device IDs to a specific OEM
layout.


Bjørn





Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Johan Hovold
On Thu, Apr 26, 2018 at 02:48:54PM +0700, Lars Melin wrote:
> On 4/26/2018 14:09, Johan Hovold wrote:
> > On Thu, Apr 26, 2018 at 02:28:31PM +0800, SZ Lin (林上智) wrote:
> >> This patch adds support for ublox R410M PID 0x90b2 USB modem to option
> >> driver, this module supports LTE Cat M1 / NB1.
> >>
> >> Interface layout:
> >> 0: QCDM/DIAG
> >> 1: ADB
> >> 2: AT
> >> 3: RMNET
> >>
> >> Signed-off-by: SZ Lin (林上智) 
> >> Cc: stable 
> > 
> > Applied, thanks.
> > 
> > Johan
> 
> With a Qualcomm Device Management interface, shouldn't this modem be 
> driven by qcserial?

Hmm, we already have some QCDM interfaces handled by option and qcaux so
it's not that clear-cut.

Dan and Björn had a discussion about this a while back, so adding them
on CC. It seems to me that this device does not fit the intended use (or
Gobi 1000 layout) for qcserial, but I may be mistaken.

Thanks,
Johan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Johan Hovold
On Thu, Apr 26, 2018 at 02:48:54PM +0700, Lars Melin wrote:
> On 4/26/2018 14:09, Johan Hovold wrote:
> > On Thu, Apr 26, 2018 at 02:28:31PM +0800, SZ Lin (林上智) wrote:
> >> This patch adds support for ublox R410M PID 0x90b2 USB modem to option
> >> driver, this module supports LTE Cat M1 / NB1.
> >>
> >> Interface layout:
> >> 0: QCDM/DIAG
> >> 1: ADB
> >> 2: AT
> >> 3: RMNET
> >>
> >> Signed-off-by: SZ Lin (林上智) 
> >> Cc: stable 
> > 
> > Applied, thanks.
> > 
> > Johan
> 
> With a Qualcomm Device Management interface, shouldn't this modem be 
> driven by qcserial?

Hmm, we already have some QCDM interfaces handled by option and qcaux so
it's not that clear-cut.

Dan and Björn had a discussion about this a while back, so adding them
on CC. It seems to me that this device does not fit the intended use (or
Gobi 1000 layout) for qcserial, but I may be mistaken.

Thanks,
Johan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Lars Melin

On 4/26/2018 14:09, Johan Hovold wrote:

On Thu, Apr 26, 2018 at 02:28:31PM +0800, SZ Lin (林上智) wrote:

This patch adds support for ublox R410M PID 0x90b2 USB modem to option
driver, this module supports LTE Cat M1 / NB1.

Interface layout:
0: QCDM/DIAG
1: ADB
2: AT
3: RMNET

Signed-off-by: SZ Lin (林上智) 
Cc: stable 


Applied, thanks.

Johan


With a Qualcomm Device Management interface, shouldn't this modem be 
driven by qcserial?


/Lars


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Lars Melin

On 4/26/2018 14:09, Johan Hovold wrote:

On Thu, Apr 26, 2018 at 02:28:31PM +0800, SZ Lin (林上智) wrote:

This patch adds support for ublox R410M PID 0x90b2 USB modem to option
driver, this module supports LTE Cat M1 / NB1.

Interface layout:
0: QCDM/DIAG
1: ADB
2: AT
3: RMNET

Signed-off-by: SZ Lin (林上智) 
Cc: stable 


Applied, thanks.

Johan


With a Qualcomm Device Management interface, shouldn't this modem be 
driven by qcserial?


/Lars


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Johan Hovold
On Thu, Apr 26, 2018 at 02:28:31PM +0800, SZ Lin (林上智) wrote:
> This patch adds support for ublox R410M PID 0x90b2 USB modem to option
> driver, this module supports LTE Cat M1 / NB1.
> 
> Interface layout:
> 0: QCDM/DIAG
> 1: ADB
> 2: AT
> 3: RMNET
> 
> Signed-off-by: SZ Lin (林上智) 
> Cc: stable 

Applied, thanks.

Johan


Re: [PATCH] USB: serial: option: adding support for ublox R410M

2018-04-26 Thread Johan Hovold
On Thu, Apr 26, 2018 at 02:28:31PM +0800, SZ Lin (林上智) wrote:
> This patch adds support for ublox R410M PID 0x90b2 USB modem to option
> driver, this module supports LTE Cat M1 / NB1.
> 
> Interface layout:
> 0: QCDM/DIAG
> 1: ADB
> 2: AT
> 3: RMNET
> 
> Signed-off-by: SZ Lin (林上智) 
> Cc: stable 

Applied, thanks.

Johan