[review] dcbw/ipv6-fixes: fix IPv6 support in core and plugins
Bjørn Mork
bjorn at mork.no
Fri Jun 13 05:37:07 PDT 2014
Dan Williams <dcbw at redhat.com> writes:
> On Wed, 2014-06-11 at 14:38 +0200, Bjørn Mork wrote:
>> Dan Williams <dcbw at redhat.com> writes:
>>
>> > Please review and test!
>> >
>> > Big changes in this branch (which we can change if we want to!) are that
>> > by default, QMI, Ericsson/MBM, and Icera devices now read and send
>> > static IP configuration in-addition-to/instead of DHCP, if we have those
>> > details. This is done for both IPv4 and IPv6.
>> >
>> > For QMI, static configuration is always used, because we can always read
>> > the IP addresses and DNS servers from the firmware.
>> >
>> > For MBM, if the firmware supports E2IPCFG we use that information,
>> > otherwise we fall back to DHCP/auto.
>
> <snip>
>
>> ModemManager[24901]: <debug> [1402489940.320635] [mm-bearer-qmi.c:475] get_current_settings_ready(): IP Family: failed (Field 'IP Family' was not found in the message)
>> ModemManager[24901]: <debug> [1402489940.321067] [mm-bearer-qmi.c:492] get_current_settings_ready(): Domains: failed (Field 'Domain Name List' was not found in the message)
>> ModemManager[24901]: <debug> [1402489940.321410] [mm-port.c:93] mm_port_set_connected(): (wwan1): port now connected
>> ModemManager[24901]: <debug> [1402489940.321869] [mm-bearer.c:489] connect_ready(): Connected bearer '/org/freedesktop/ModemManager1/Bearer/7'
>> ModemManager[24901]: <info> [1402489940.322334] [mm-iface-modem.c:1392] __iface_modem_update_state_internal(): Modem /org/freedesktop/ModemManager1/Modem/4: state changed (connecting -> connected)
>> ModemManager[24901]: <info> [1402489940.323778] [mm-iface-modem-simple.c:602] connection_step(): Simple connect state (8/8): All done
>
>> This modem does not support IPv6, so I guess the 'IP Family' TLV is just
>> left out as redundant? In any case: All the TLVs are family specific so
>> it shouldn't really be a problem parsing them without the family TLV.
>
> Pushed a fixup to just assume IPv4 if no family TLV is given.
Still fails, but with slightly different messages:
ModemManager[27662]: [/dev/cdc-wdm1] Received message...
>>>>>> RAW:
>>>>>> length = 91
>>>>>> data = 01:5A:00:80:01:01:02:02:00:2D:00:4E:00:02:04:00:00:00:00:00:1E:04:00:DA:6A:42:2E:15:04:00:04:70:D5:C1:16:04:00:C6:0F:43:82:20:04:00:D9:6A:42:2E:21:04:00:FC:FF:FF:FF:17:21:00:04:80:21:00:00:C0:21:00:00:00:00:00:00:00:00:00:00:02:DC:05:00:00:04:07:03:00:00:00:00:01:00:00:00
ModemManager[27662]: [/dev/cdc-wdm1] Received message (translated)...
>>>>>> QMUX:
>>>>>> length = 90
>>>>>> flags = 0x80
>>>>>> service = "wds"
>>>>>> client = 1
>>>>>> QMI:
>>>>>> flags = "response"
>>>>>> transaction = 2
>>>>>> tlv_length = 78
>>>>>> message = "Get Current Settings" (0x002D)
>>>>>> TLV:
>>>>>> type = "Result" (0x02)
>>>>>> length = 4
>>>>>> value = 00:00:00:00
>>>>>> translated = SUCCESS
>>>>>> TLV:
>>>>>> type = "IPv4 Address" (0x1e)
>>>>>> length = 4
>>>>>> value = DA:6A:42:2E
>>>>>> translated = 776104666
>>>>>> TLV:
>>>>>> type = "Primary IPv4 DNS Address" (0x15)
>>>>>> length = 4
>>>>>> value = 04:70:D5:C1
>>>>>> translated = 3251990532
>>>>>> TLV:
>>>>>> type = "Secondary IPv4 DNS Address" (0x16)
>>>>>> length = 4
>>>>>> value = C6:0F:43:82
>>>>>> translated = 2185433030
>>>>>> TLV:
>>>>>> type = "IPv4 Gateway Address" (0x20)
>>>>>> length = 4
>>>>>> value = D9:6A:42:2E
>>>>>> translated = 776104665
>>>>>> TLV:
>>>>>> type = "IPv4 Gateway Subnet Mask" (0x21)
>>>>>> length = 4
>>>>>> value = FC:FF:FF:FF
>>>>>> translated = 4294967292
>>>>>> TLV:
>>>>>> type = 0x17
>>>>>> length = 33
>>>>>> value = 04:80:21:00:00:C0:21:00:00:00:00:00:00:00:00:00:00:02:DC:05:00:00:04:07:03:00:00:00:00:01:00:00:00
ModemManager[27662]: <debug> [1402662737.772639] [mm-bearer-qmi.c:467] get_current_settings_ready(): IP Family: unknown
(ModemManager:27662): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory.
This indicates a bug in someone's code. You must ensure an error is NULL before it's set.
The overwriting error message was: Field 'MTU' was not found in the message
ModemManager[27662]: <debug> [1402662737.774325] [mm-bearer-qmi.c:470] get_current_settings_ready(): MTU: failed (Field 'IP Family' was not found in the message)
ModemManager[27662]: <debug> [1402662737.774576] [mm-bearer-qmi.c:492] get_current_settings_ready(): Domains: failed (Field 'Domain Name List' was not found in the message)
ModemManager[27662]: <debug> [1402662737.775143] [mm-port.c:93] mm_port_set_connected(): (wwan1): port now connected
ModemManager[27662]: <debug> [1402662737.775885] [mm-bearer.c:489] connect_ready(): Connected bearer '/org/freedesktop/ModemManager1/Bearer/1'
ModemManager[27662]: <info> [1402662737.776676] [mm-iface-modem.c:1392] __iface_modem_update_state_internal(): Modem /org/freedesktop/ModemManager1/Modem/1: state changed (connecting -> connected)
ModemManager[27662]: <info> [1402662737.779366] [mm-iface-modem-simple.c:602] connection_step(): Simple connect state (8/8): All done
Bjørn
More information about the ModemManager-devel
mailing list