[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1595233498-13628-1-git-send-email-linmiaohe@huawei.com>
Date: Mon, 20 Jul 2020 16:24:58 +0800
From: linmiaohe <linmiaohe@...wei.com>
To: <satishkh@...co.com>, <sebaddel@...co.com>, <kartilak@...co.com>,
<jejb@...ux.ibm.com>, <martin.petersen@...cle.com>
CC: <linux-scsi@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
<linmiaohe@...wei.com>
Subject: [PATCH] scsi: fnic: use eth_broadcast_addr() to assign broadcast address
From: Miaohe Lin <linmiaohe@...wei.com>
Use eth_broadcast_addr() to assign broadcast address insetad of memset().
Signed-off-by: Miaohe Lin <linmiaohe@...wei.com>
---
drivers/scsi/fnic/fnic_scsi.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/scsi/fnic/fnic_scsi.c b/drivers/scsi/fnic/fnic_scsi.c
index 27535c90b248..03b1805b106c 100644
--- a/drivers/scsi/fnic/fnic_scsi.c
+++ b/drivers/scsi/fnic/fnic_scsi.c
@@ -23,6 +23,7 @@
#include <linux/scatterlist.h>
#include <linux/skbuff.h>
#include <linux/spinlock.h>
+#include <linux/etherdevice.h>
#include <linux/if_ether.h>
#include <linux/if_vlan.h>
#include <linux/delay.h>
@@ -275,7 +276,7 @@ int fnic_flogi_reg_handler(struct fnic *fnic, u32 fc_id)
}
if (fnic->ctlr.map_dest) {
- memset(gw_mac, 0xff, ETH_ALEN);
+ eth_broadcast_addr(gw_mac);
format = FCPIO_FLOGI_REG_DEF_DEST;
} else {
memcpy(gw_mac, fnic->ctlr.dest_addr, ETH_ALEN);
--
2.19.1
Powered by blists - more mailing lists