summaryrefslogtreecommitdiffstats
path: root/drivers/net/macvlan.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2013-05-29 12:52:16 +0200
committerTakashi Iwai <tiwai@suse.de>2013-05-29 12:52:16 +0200
commit8a90bb5116889e98008fbc8178fc2a77bb51df4a (patch)
tree210b6755c9ae2d0d66a79f8696469ab50b7621ad /drivers/net/macvlan.c
parentd47333ddb234dbc661ab2a4fe019758bd33ba33b (diff)
parent1ab9ecc24819a8cf8ee982aaf6fb83298f094b0d (diff)
downloadop-kernel-dev-8a90bb5116889e98008fbc8178fc2a77bb51df4a.zip
op-kernel-dev-8a90bb5116889e98008fbc8178fc2a77bb51df4a.tar.gz
Merge tag 'asoc-v3.10-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
ASoC: Updates for v3.10 A series of driver specific updates, none particularly critical, plus one fix to the compressed API code to handle capture streams properly which is very safe for mainline as there's no current users.
Diffstat (limited to 'drivers/net/macvlan.c')
-rw-r--r--drivers/net/macvlan.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/macvlan.c b/drivers/net/macvlan.c
index d5a141c..1c502bb 100644
--- a/drivers/net/macvlan.c
+++ b/drivers/net/macvlan.c
@@ -229,7 +229,8 @@ static rx_handler_result_t macvlan_handle_frame(struct sk_buff **pskb)
}
if (port->passthru)
- vlan = list_first_entry(&port->vlans, struct macvlan_dev, list);
+ vlan = list_first_or_null_rcu(&port->vlans,
+ struct macvlan_dev, list);
else
vlan = macvlan_hash_lookup(port, eth->h_dest);
if (vlan == NULL)
@@ -814,7 +815,7 @@ int macvlan_common_newlink(struct net *src_net, struct net_device *dev,
if (err < 0)
goto upper_dev_unlink;
- list_add_tail(&vlan->list, &port->vlans);
+ list_add_tail_rcu(&vlan->list, &port->vlans);
netif_stacked_transfer_operstate(lowerdev, dev);
return 0;
@@ -842,7 +843,7 @@ void macvlan_dellink(struct net_device *dev, struct list_head *head)
{
struct macvlan_dev *vlan = netdev_priv(dev);
- list_del(&vlan->list);
+ list_del_rcu(&vlan->list);
unregister_netdevice_queue(dev, head);
netdev_upper_dev_unlink(vlan->lowerdev, dev);
}
OpenPOWER on IntegriCloud