Commit a88e2676 authored by Zhang Shengju's avatar Zhang Shengju Committed by David S. Miller

macvlan: propagate the mac address change status for lowerdev

The macvlan dev should propagate the return value of mac address change for
lower device in the passthru mode, instead of always return 0.
Signed-off-by: default avatarZhang Shengju <zhangshengju@cmss.chinamobile.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 55ce889f
...@@ -703,10 +703,8 @@ static int macvlan_set_mac_address(struct net_device *dev, void *p) ...@@ -703,10 +703,8 @@ static int macvlan_set_mac_address(struct net_device *dev, void *p)
if (!is_valid_ether_addr(addr->sa_data)) if (!is_valid_ether_addr(addr->sa_data))
return -EADDRNOTAVAIL; return -EADDRNOTAVAIL;
if (vlan->mode == MACVLAN_MODE_PASSTHRU) { if (vlan->mode == MACVLAN_MODE_PASSTHRU)
dev_set_mac_address(vlan->lowerdev, addr); return dev_set_mac_address(vlan->lowerdev, addr);
return 0;
}
return macvlan_sync_address(dev, addr->sa_data); return macvlan_sync_address(dev, addr->sa_data);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment