Re: [MM] Handling devices with multiple QMI ports



Aleksander Morgado <aleksander lanedo com> writes:

> Hey Bjørn;
>
> Can you take a look at the following patches to see if they are enough to handle
> the devices with multiple QMI ports? Not sure if the udev logic to find the
> matching QMI port of a given WWAN port is correct or not.
>
> The general idea with multiple bearers is that you can create as many bearers
> as data ports you have; and then, when connecting each of them we'll just look
> for the first non-connected data port and use that. Note that bearers are not
> matched with specific data ports until the connection is fired. In the QMI case,
> once we have a non-connected data port, we'll look for the associated QMI port
> to use for WDS.

Looks very good:

bjorn@nemi:~$ mmcli -m 0  --list-bearers

Found 2 bearers:

        /org/freedesktop/ModemManager1/Bearer/0

        /org/freedesktop/ModemManager1/Bearer/1
bjorn@nemi:~$ mmcli -b 0 -c
successfully connected the bearer
bjorn@nemi:~$ mmcli -b 1 -c
successfully connected the bearer

bjorn@nemi:~$ mmcli -b 0
Bearer '/org/freedesktop/ModemManager1/Bearer/0'
  -------------------------
  Status             |   connected: 'yes'
                     |   suspended: 'no'
                     |   interface: 'wwan0'
                     |  IP timeout: '20'
  -------------------------
  Properties         |         apn: 'telenor'
                     |     roaming: 'allowed'
                     |     IP type: 'ipv4'
                     |        user: 'none'
                     |    password: 'none'
                     |      number: 'none'
                     | Rm protocol: 'unknown'
  -------------------------
  IPv4 configuration |   method: 'dhcp'
  -------------------------
  IPv6 configuration |   method: 'unknown'
bjorn@nemi:~$ mmcli -b 1 
Bearer '/org/freedesktop/ModemManager1/Bearer/1'
  -------------------------
  Status             |   connected: 'yes'
                     |   suspended: 'no'
                     |   interface: 'wwan1'
                     |  IP timeout: '20'
  -------------------------
  Properties         |         apn: 'pilot.telenor'
                     |     roaming: 'allowed'
                     |     IP type: 'ipv4'
                     |        user: 'none'
                     |    password: 'none'
                     |      number: 'none'
                     | Rm protocol: 'unknown'
  -------------------------
  IPv4 configuration |   method: 'dhcp'
  -------------------------
  IPv6 configuration |   method: 'unknown'


nemi:/home/bjorn# dhclient -4 -d wwan0
Internet Systems Consortium DHCP Client 4.2.2
Copyright 2004-2011 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/wwan0/a6:88:d1:db:b0:bf
Sending on   LPF/wwan0/a6:88:d1:db:b0:bf
Sending on   Socket/fallback
DHCPDISCOVER on wwan0 to 255.255.255.255 port 67 interval 6
DHCPREQUEST on wwan0 to 255.255.255.255 port 67
DHCPOFFER from 77.16.212.70
DHCPACK from 77.16.212.70
bound to 77.16.212.69 -- renewal in 3301 seconds.
^Z
[1]+  Stopped                 dhclient -4 -d wwan0
nemi:/home/bjorn# bg
[1]+ dhclient -4 -d wwan0 &
nemi:/home/bjorn# dhclient -4 -d wwan1
Internet Systems Consortium DHCP Client 4.2.2
Copyright 2004-2011 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/wwan1/a6:88:d1:db:b0:bf
Sending on   LPF/wwan1/a6:88:d1:db:b0:bf
Sending on   Socket/fallback
DHCPDISCOVER on wwan1 to 255.255.255.255 port 67 interval 5
DHCPREQUEST on wwan1 to 255.255.255.255 port 67
DHCPOFFER from 10.127.161.177
DHCPACK from 10.127.161.177
bound to 10.127.161.176 -- renewal in 3434 seconds.



Bjørn


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]