diff options
author | Horatiu Vultur <horatiu.vultur@microchip.com> | 2020-11-06 22:50:49 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2020-11-09 16:42:12 -0800 |
commit | 0169b8205431589b945c29a576c65f2037a5bc26 (patch) | |
tree | 4f83270279de8d3d3265392be10f9d8702753cf3 /net/bridge/br_mrp_netlink.c | |
parent | 084d0c13a4897a16f80950397ff3a8a8fc2ff042 (diff) | |
download | linux-0169b8205431589b945c29a576c65f2037a5bc26.tar.gz linux-0169b8205431589b945c29a576c65f2037a5bc26.tar.bz2 linux-0169b8205431589b945c29a576c65f2037a5bc26.zip |
bridge: mrp: Use hlist_head instead of list_head for mrp
Replace list_head with hlist_head for MRP list under the bridge.
There is no need for a circular list when a linear list will work.
This will also decrease the size of 'struct net_bridge'.
Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
Link: https://lore.kernel.org/r/20201106215049.1448185-1-horatiu.vultur@microchip.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/bridge/br_mrp_netlink.c')
-rw-r--r-- | net/bridge/br_mrp_netlink.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bridge/br_mrp_netlink.c b/net/bridge/br_mrp_netlink.c index 2a2fdf3500c5..ce6f63c77cc0 100644 --- a/net/bridge/br_mrp_netlink.c +++ b/net/bridge/br_mrp_netlink.c @@ -453,7 +453,7 @@ int br_mrp_fill_info(struct sk_buff *skb, struct net_bridge *br) if (!mrp_tb) return -EMSGSIZE; - list_for_each_entry_rcu(mrp, &br->mrp_list, list) { + hlist_for_each_entry_rcu(mrp, &br->mrp_list, list) { struct net_bridge_port *p; tb = nla_nest_start_noflag(skb, IFLA_BRIDGE_MRP_INFO); |