Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

driver: macvlan: Remove the rcu member of macvlan_port

When free macvlan_port in macvlan_port_destroy, it is safe to free
directly because netdev_rx_handler_unregister could enforce one
grace period.
So it is unnecessary to use kfree_rcu for macvlan_port.

Signed-off-by: Gao Feng <fgao@ikuai8.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Gao Feng and committed by
David S. Miller
a1f5315c 48140a21

+1 -2
+1 -2
drivers/net/macvlan.c
··· 43 43 struct net_device *dev; 44 44 struct hlist_head vlan_hash[MACVLAN_HASH_SIZE]; 45 45 struct list_head vlans; 46 - struct rcu_head rcu; 47 46 struct sk_buff_head bc_queue; 48 47 struct work_struct bc_work; 49 48 bool passthru; ··· 1150 1151 cancel_work_sync(&port->bc_work); 1151 1152 __skb_queue_purge(&port->bc_queue); 1152 1153 1153 - kfree_rcu(port, rcu); 1154 + kfree(port); 1154 1155 } 1155 1156 1156 1157 static int macvlan_validate(struct nlattr *tb[], struct nlattr *data[])