GNOME Bugzilla – Bug 763323
[review] more fixes for network namespace (netns) [th/netns-aware-bgo763323]
Last modified: 2016-03-15 12:00:04 UTC
To make NM eventually capable of handling netns', we must inject the proper NMPNetns/NMPlatform as needed instead of using the global NM_PLATFORM_GET instance.
The last two patches are still unused code, but eventually we want to do something like this. Hence, I'd also just merge them. platform: add nmp_netns_bind_to_path() helper function platform: add nm_platform_link_set_netns() function
> rdisc: make NMRDisc namespace aware typedef struct { GObject parent; + NMPlatform *_platform; + NMPNetns *_netns; int ifindex; char *ifname; Nitpick: naming is different from other members (leading underscore), I don't know if it's on purpose. Otherwise LGTM.
(In reply to Beniamino Galvani from comment #2) > > rdisc: make NMRDisc namespace aware > > typedef struct { > GObject parent; > > + NMPlatform *_platform; > + NMPNetns *_netns; > > int ifindex; > char *ifname; > > Nitpick: naming is different from other members (leading underscore), I > don't know if it's on purpose. > Otherwise LGTM. It's kinda on purpose, because these members should not be used directly (there are accessor functions, like nm_rdisc_get_netns(). Merged to master: https://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=7037e0b37411cf25ff0af94f1aa7b868a1398bd7