* [PATCH] scsi: fnic: use eth_broadcast_addr() to assign broadcast address
@ 2020-07-20 8:24 linmiaohe
2020-07-25 2:50 ` Martin K. Petersen
0 siblings, 1 reply; 2+ messages in thread
From: linmiaohe @ 2020-07-20 8:24 UTC (permalink / raw)
To: satishkh, sebaddel, kartilak, jejb, martin.petersen
Cc: linux-scsi, linux-kernel, linmiaohe
From: Miaohe Lin <linmiaohe@huawei.com>
Use eth_broadcast_addr() to assign broadcast address insetad of memset().
Signed-off-by: Miaohe Lin <linmiaohe@huawei.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
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] scsi: fnic: use eth_broadcast_addr() to assign broadcast address
2020-07-20 8:24 [PATCH] scsi: fnic: use eth_broadcast_addr() to assign broadcast address linmiaohe
@ 2020-07-25 2:50 ` Martin K. Petersen
0 siblings, 0 replies; 2+ messages in thread
From: Martin K. Petersen @ 2020-07-25 2:50 UTC (permalink / raw)
To: linmiaohe, kartilak, satishkh, sebaddel, jejb
Cc: Martin K . Petersen, linux-kernel, linux-scsi
On Mon, 20 Jul 2020 16:24:58 +0800, linmiaohe wrote:
> Use eth_broadcast_addr() to assign broadcast address insetad of memset().
Applied to 5.9/scsi-queue, thanks!
[1/1] scsi: fnic: Use eth_broadcast_addr() to assign broadcast address
https://git.kernel.org/mkp/scsi/c/51d263cbdd76
--
Martin K. Petersen Oracle Linux Engineering
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-07-25 2:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-20 8:24 [PATCH] scsi: fnic: use eth_broadcast_addr() to assign broadcast address linmiaohe
2020-07-25 2:50 ` Martin K. Petersen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).