Point to Point interface over qmi_wwan device

Dan Williams dcbw at redhat.com
Wed Oct 5 20:36:44 UTC 2016


On Wed, 2016-10-05 at 19:23 +0000, Tang Nguyen wrote:
> --------------------------------------------
> On Wed, 10/5/16, Bjørn Mork <bjorn at mork.no> wrote:
> 
>  Subject: Re: Point to Point interface over qmi_wwan device
>  To: "Tang Nguyen" <tang_nguyen at yahoo.com>
>  Cc: "Dan Williams" <dcbw at redhat.com>, "Reinhard Speyerer" <rspmn at arc
> or.de>, "libqmi (development)" <libqmi-devel at lists.freedesktop.org>
>  Date: Wednesday, October 5, 2016, 9:26 AM
>  
>  Tang Nguyen <tang_nguyen at yahoo.com>
>  writes:
>  
>  > I try to use
>  --set-expected-data-format=raw-ip command, but I got error
>  message of non-existence
>  "'/sys/class/net/wwan-6-1.ip/qmi/raw_ip' 
>  file.
>  > I found Bjon's patch : https://patchwork.ozlabs.org/patch/552408/
>  from patchwork regarding about raw-ip support in
>  qmi_wwan driver.  
>  > Is this patch
>  already available in upstream kernel , or it will happen
>  soon ? 
>  
>  >It's in Linux
>  >v4.5 and later.
>  
>  
>  >Bjørn
> 
> Applying cleanly Bjon's patch to kernel 3.14.68, I can set raw-ip
> data format, but not able to make a connection. Do i need to apply
> another patch to get it work.

These logs say that the device refused to set raw-ip through the CTL
service request.  Can you try the WDA method instead?  IIRC newer
devices don't do this through CTL anymore.

qmicli -d /dev/cdc-wdm0 --wda-set-data-format=raw-ip
qmicli -d /dev/cdc-wdm0 --set-expected-data-format=raw-ip

then try to connect.

Dan


> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Opening device with
> flags 'sync, net-raw-ip, net-no-qos-header'...
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Running sync...
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Sent message...
> <<<<<< RAW:
> <<<<<<   length = 12
> <<<<<<   data   = 01:0B:00:00:00:00:00:01:27:00:00:00
> 
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Sent message
> (translated)...
> <<<<<< QMUX:
> <<<<<<   length  = 11
> <<<<<<   flags   = 0x00
> <<<<<<   service = "ctl"
> <<<<<<   client  = 0
> <<<<<< QMI:
> <<<<<<   flags       = "none"
> <<<<<<   transaction = 1
> <<<<<<   tlv_length  = 0
> <<<<<<   message     = "Sync" (0x0027)
> 
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Received message...
> > 
> > > 
> > > > 
> > > > > 
> > > > > > 
> > > > > > > 
> > > > > > > RAW:
> > > > > > >   length = 19
> > > > > > >   data   =
> > > > > > > 01:12:00:80:00:00:01:01:27:00:07:00:02:04:00:00:00:00:00
> 
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Received message
> (translated)...
> > 
> > > 
> > > > 
> > > > > 
> > > > > > 
> > > > > > > 
> > > > > > > QMUX:
> > > > > > >   length  = 18
> > > > > > >   flags   = 0x80
> > > > > > >   service = "ctl"
> > > > > > >   client  = 0
> > > > > > > QMI:
> > > > > > >   flags       = "response"
> > > > > > >   transaction = 1
> > > > > > >   tlv_length  = 7
> > > > > > >   message     = "Sync" (0x0027)
> > > > > > > TLV:
> > > > > > >   type       = "Result" (0x02)
> > > > > > >   length     = 4
> > > > > > >   value      = 00:00:00:00
> > > > > > >   translated = SUCCESS
> 
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Sync operation
> finished
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Setting network port
> data format...
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Sent message...
> <<<<<< RAW:
> <<<<<<   length = 21
> <<<<<<   data   =
> 01:14:00:00:00:00:00:02:26:00:09:00:10:02:00:02:00:01:01:00:00
> 
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Sent message
> (translated)...
> <<<<<< QMUX:
> <<<<<<   length  = 20
> <<<<<<   flags   = 0x00
> <<<<<<   service = "ctl"
> <<<<<<   client  = 0
> <<<<<< QMI:
> <<<<<<   flags       = "none"
> <<<<<<   transaction = 2
> <<<<<<   tlv_length  = 9
> <<<<<<   message     = "Set Data Format" (0x0026)
> <<<<<< TLV:
> <<<<<<   type       = "Protocol" (0x10)
> <<<<<<   length     = 2
> <<<<<<   value      = 02:00
> <<<<<<   translated = raw-ip
> <<<<<< TLV:
> <<<<<<   type       = "Format" (0x01)
> <<<<<<   length     = 1
> <<<<<<   value      = 00
> <<<<<<   translated = absent
> 
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Received message...
> > 
> > > 
> > > > 
> > > > > 
> > > > > > 
> > > > > > > 
> > > > > > > RAW:
> > > > > > >   length = 19
> > > > > > >   data   =
> > > > > > > 01:12:00:80:00:00:01:02:26:00:07:00:02:04:00:01:00:46:00
> 
> [05 Oct 2016, 14:06:07] [Debug] [/dev/cdc-wdm0] Received message
> (translated)...
> > 
> > > 
> > > > 
> > > > > 
> > > > > > 
> > > > > > > 
> > > > > > > QMUX:
> > > > > > >   length  = 18
> > > > > > >   flags   = 0x80
> > > > > > >   service = "ctl"
> > > > > > >   client  = 0
> > > > > > > QMI:
> > > > > > >   flags       = "response"
> > > > > > >   transaction = 2
> > > > > > >   tlv_length  = 7
> > > > > > >   message     = "Set Data Format" (0x0026)
> > > > > > > TLV:
> > > > > > >   type       = "Result" (0x02)
> > > > > > >   length     = 4
> > > > > > >   value      = 01:00:46:00
> > > > > > >   translated = FAILURE: InvalidOperation
> _______________________________________________
> libqmi-devel mailing list
> libqmi-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/libqmi-devel


More information about the libqmi-devel mailing list