bridge: make sure objects belong to container's owner
When creating various bridge objects in /sys/class/net/... make sure that they belong to the container's owner instead of global root (if they belong to a container/namespace). Signed-off-by: Tyler Hicks <tyhicks@canonical.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
fbdeaed408
commit
705e0dea4d
@@ -283,6 +283,8 @@ struct net_bridge_port {
|
||||
u16 group_fwd_mask;
|
||||
};
|
||||
|
||||
#define kobj_to_brport(obj) container_of(obj, struct net_bridge_port, kobj)
|
||||
|
||||
#define br_auto_port(p) ((p)->flags & BR_AUTO_MASK)
|
||||
#define br_promisc_port(p) ((p)->flags & BR_PROMISC)
|
||||
|
||||
|
Reference in New Issue
Block a user