From: Pasi Sjöholm <[email protected]> First of all I got it all wrong due a bug in ofono. :)
a) RIL always returns the both ipv4 and ipv6-addresses to ofono which need to be setup as fixed-method in connman because the ofono also setups the addresses on the interfaces by itself. b) This works ok when either ip or ipv6-pdp type is used. c) With dual/ipv4v6 it seems that only valid ipv4-addresses are returned first and Ipv6.setting only consisting the interface. Valid ipv6-addresses are updated by the RIL few seconds later to ofono, but never signaled to its clients as currently ofono has no way to do it after the context has been set as active. Patch1: Both ipv4_method and ipv6_method need to be reset to initialization value "CONNMAN_IPCONFIG_METHOD_UNKNOWN" after disconnect. Otherwise we might end up using the old ip-address-configuration data from modem->context (eg. if first ip-pdp type is used in ofono and then switched to ipv6). Patch2: Almost as Patch1 but with this we make sure that no old configuration data is used on the connman's service-side by setting the method CONNMAN_IPCONFIG_METHOD_UNKNOWN if no configuratio data is got from ofono. Patch3: Because of a,b and c setting up addresses by fixed method is necessary (don't know if dhcp-method really works with ipv4) as otherwise connman can get into eternal "configuration"-state while trying to do plain slaac/dhcpv6 especially with ipv6-pdp as both connman and ofono are setting up the interface configuration. However.. due to a bug in ofono (c) the Ipv6.settings are never returned to connman with dual/ipv4v6-pdp, so the service will not ever know about the ipv6-configuration even though they are set to the interface by the ofono. This can be worked out by setting the ipv6-method to CONNMAN_IPCONFIG_METHOD_AUTO if no ip-address is returned in the IPv6.settings-mesage by the ofono and it will work because the the ipv4-settings have been already configured and the index-value for the ipconfig has been already set. By doing this connman also gets the configuration for ipv6 correctly. Pasi Sjöholm (3): ofono: Clean ipv4/6_method when disconnecting ofono: set ipconfig method to unknown ofono: Set CONNMAN_IPCONFIG_METHOD_AUTO when no address defined plugins/ofono.c | 81 +++++++++++++++++++++++++++++++++++++++------------------ 1 file changed, 55 insertions(+), 26 deletions(-) -- 2.1.0 _______________________________________________ connman mailing list [email protected] https://lists.connman.net/mailman/listinfo/connman
