]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/commit
MFC r279538:
authorhrs <hrs@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Thu, 23 Jul 2015 19:57:47 +0000 (19:57 +0000)
committerhrs <hrs@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Thu, 23 Jul 2015 19:57:47 +0000 (19:57 +0000)
commita9994d4eff026fb96962178942eaabce53c7950c
tree1a14580f897ff42b69efb58a4aca6dd9f1e1b4ca
parentcbc16c07c0cdaf6481bc615cd237f0c381e584b2
MFC r279538:

Fix group membership of cloned interfaces when one is moved by
if_vmove().

In if_vmove(), if_detach_internal() and if_attach_internal() were
called in series to detach and reattach the interface.  When
detaching, if_delgroup() was called and the interface leaves all of
the group membership.  And then upon attachment, if_addgroup(ifp,
IFG_ALL) was called and it joined only "all" group again.

This had a problem. Normally, a cloned interface automatically joins
a group whose name is ifc_name of the cloner in addition to "all"
upon creation.  However, if_vmove() removed the membership and did
not restore upon attachment.

Approved by: re (gjb)

git-svn-id: svn://svn.freebsd.org/base/stable/10@285824 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/net/if.c
sys/net/if_clone.c
sys/net/if_clone.h