diff options
Diffstat (limited to 'drivers/scsi/fcoe')
-rw-r--r-- | drivers/scsi/fcoe/fcoe.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/scsi/fcoe/fcoe.c b/drivers/scsi/fcoe/fcoe.c index 2274fcd4c713..c1fd7561f0bd 100644 --- a/drivers/scsi/fcoe/fcoe.c +++ b/drivers/scsi/fcoe/fcoe.c | |||
@@ -249,6 +249,7 @@ static int fcoe_interface_setup(struct fcoe_interface *fcoe, | |||
249 | { | 249 | { |
250 | struct fcoe_ctlr *fip = &fcoe->ctlr; | 250 | struct fcoe_ctlr *fip = &fcoe->ctlr; |
251 | struct netdev_hw_addr *ha; | 251 | struct netdev_hw_addr *ha; |
252 | struct net_device *real_dev; | ||
252 | u8 flogi_maddr[ETH_ALEN]; | 253 | u8 flogi_maddr[ETH_ALEN]; |
253 | const struct net_device_ops *ops; | 254 | const struct net_device_ops *ops; |
254 | 255 | ||
@@ -272,8 +273,10 @@ static int fcoe_interface_setup(struct fcoe_interface *fcoe, | |||
272 | 273 | ||
273 | /* look for SAN MAC address, if multiple SAN MACs exist, only | 274 | /* look for SAN MAC address, if multiple SAN MACs exist, only |
274 | * use the first one for SPMA */ | 275 | * use the first one for SPMA */ |
276 | real_dev = (netdev->priv_flags & IFF_802_1Q_VLAN) ? | ||
277 | vlan_dev_real_dev(netdev) : netdev; | ||
275 | rcu_read_lock(); | 278 | rcu_read_lock(); |
276 | for_each_dev_addr(netdev, ha) { | 279 | for_each_dev_addr(real_dev, ha) { |
277 | if ((ha->type == NETDEV_HW_ADDR_T_SAN) && | 280 | if ((ha->type == NETDEV_HW_ADDR_T_SAN) && |
278 | (is_valid_ether_addr(ha->addr))) { | 281 | (is_valid_ether_addr(ha->addr))) { |
279 | memcpy(fip->ctl_src_addr, ha->addr, ETH_ALEN); | 282 | memcpy(fip->ctl_src_addr, ha->addr, ETH_ALEN); |