Hi Mika,
> > +enum ofono_gprs_addrconf {
> > + OFONO_GPRS_ADDRCONF_NONE,
> > + OFONO_GPRS_ADDRCONF_STATIC,
> > + OFONO_GPRS_ADDRCONF_DHCP,
> > +};
> > +
>
> What exactly is the _NONE addrconf for? And why don't we use
> a gboolean
> here like before?
Neither "static" nor "DHCP" makes sense for IPv6. If we have an IPv6
only context, the "Method" property will not show up at all.
I also wanted to leave the door open for additional address configuration protocols in
case e.g. IPv6 capable modems with virtual ethernet intefaces require some weird quirks. I
also felt this was a bit cleaner, although that is a matter of opinion, of course.
Normally, IPv6 addresses and routes are autoconfigured using IPv6 stateless address
autoconfiguration followed optionally by DHCPv6 to get additional settings. The kernel
actually starts stateless address autoconfiguration immediately when the interface is
configured up (which oFono does), assuming the interface already has a link-local IPv6
address (which all Ethernet interface do have, as it is calculated from the MAC address
and added automatically).
Point-to-point interfaces, on the other, require the link-local address to be added
manually to the interface before the autoconfiguration can happen. oFono should probably
add the address to be consistent with Ethernet interfaces.
I am not sure we really wanna be consistent with how Ethernet works
since we are not actually Ethernet.
So I can see benefits for having ConnMan control the link-local in case
of point-to-point, but then I also do see the benefit oFono doing it.
We might have to spin of ideas and see what is the most logical one and
what works best. Especially also in the context of LTE support in the
future.
The upshot would be that IPv6 could be autoconfigured immediately
without connman's intervention. IPv6 does not have private address spaces, so in
theory connman does not really have to care about IPv6 addresses and routes. However, the
optional DHCPv6 step would probably be controlled by connman. Configuration of IPv6
tethering would be another optional followup step controlled by connman.
Yes, DHCPv6 step needs to be done by ConnMan. We do not have DHCPv6
support right now. We only plan to use it for extra settings like
proxies, timeservers etc.
On the other hand, if we want connman to be fully in charge, we could
change oFono to always leave the network interface down and let connman do everything.
Marcels input on this would be welcome as well.
This is something we need to figure out. And of course this all needs to
be aligned with IPv4 and IPv6. Right now we are treating this similar to
how wpa_supplicant for WiFi does this.
So going back to potential LTE and IMS support; if that runs IPv6 then
it might make sense to just autoconfigure it without ConnMan
interaction.
Regards
Marcel