From: Anil Belur <askb23@gmail.com>
To: rupesh.gujare@atmel.com
Cc: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org,
devel@driverdev.osuosl.org, Anil Belur <askb23@gmail.com>
Subject: [PATCH 1/1] staging: ozwpan: ozproto.c fix for "WARNING: Prefer ether_addr_copy() over memcpy() if the Ethernet addresses are __aligned(2)"
Date: Mon, 19 May 2014 19:42:48 +1000 [thread overview]
Message-ID: <1400492568-18210-1-git-send-email-askb23@gmail.com> (raw)
From: Anil Belur <askb23@gmail.com>
Fixed the warning message by replacing memcpy() with ether_addr_copy()
Signed-off-by: Anil Belur <askb23@gmail.com>
---
drivers/staging/ozwpan/ozproto.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/ozwpan/ozproto.c b/drivers/staging/ozwpan/ozproto.c
index f09acd0..1c80132 100644
--- a/drivers/staging/ozwpan/ozproto.c
+++ b/drivers/staging/ozwpan/ozproto.c
@@ -792,7 +792,7 @@ int oz_get_pd_list(struct oz_mac_addr *addr, int max_count)
if (count >= max_count)
break;
pd = container_of(e, struct oz_pd, link);
- memcpy(&addr[count++], pd->mac_addr, ETH_ALEN);
+ ether_addr_copy((u8 *)&addr[count++], pd->mac_addr);
}
spin_unlock_bh(&g_polling_lock);
return count;
--
1.9.0
reply other threads:[~2014-05-19 9:43 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1400492568-18210-1-git-send-email-askb23@gmail.com \
--to=askb23@gmail.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rupesh.gujare@atmel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome