Skip to content

Commit

Permalink
lec: Use rtnl lock/unlock when updating MTU
Browse files Browse the repository at this point in the history
The LECS response contains the MTU that should be used.  Correctly
synchronize with other layers when updating.

Signed-off-by: Chas Williams - CONTRACTOR <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
chas williams - CONTRACTOR authored and davem330 committed Aug 21, 2014
1 parent 02784f1 commit 6df378d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions net/atm/lec.c
Original file line number Diff line number Diff line change
Expand Up @@ -410,9 +410,11 @@ static int lec_atm_send(struct atm_vcc *vcc, struct sk_buff *skb)
priv->lane2_ops = NULL;
if (priv->lane_version > 1)
priv->lane2_ops = &lane2_ops;
rtnl_lock();
if (dev_set_mtu(dev, mesg->content.config.mtu))
pr_info("%s: change_mtu to %d failed\n",
dev->name, mesg->content.config.mtu);
rtnl_unlock();
priv->is_proxy = mesg->content.config.is_proxy;
break;
case l_flush_tran_id:
Expand Down

0 comments on commit 6df378d

Please sign in to comment.