From: "Bjørn Mork" <bjorn@mork.no>
To: netdev@vger.kernel.org
Cc: devel@driverdev.osuosl.org,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Forest Bond" <forest@alittletooquiet.net>,
"Bjørn Mork" <bjorn@mork.no>
Subject: [PATCH v2 net-next 9/9] staging: vt6655: inherit addr_assign_type along with dev_addr
Date: Fri, 30 Aug 2013 18:08:52 +0200 [thread overview]
Message-ID: <1377878932-26881-10-git-send-email-bjorn@mork.no> (raw)
In-Reply-To: <1377878932-26881-1-git-send-email-bjorn@mork.no>
A device inheriting a random or set address should reflect this in
its addr_assign_type.
Cc: Forest Bond <forest@alittletooquiet.net>
Signed-off-by: Bjørn Mork <bjorn@mork.no>
---
drivers/staging/vt6655/hostap.c | 2 +-
drivers/staging/vt6655/ioctl.c | 2 +-
drivers/staging/vt6655/wpactl.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/vt6655/hostap.c b/drivers/staging/vt6655/hostap.c
index 57a08c5..8acff44 100644
--- a/drivers/staging/vt6655/hostap.c
+++ b/drivers/staging/vt6655/hostap.c
@@ -86,7 +86,7 @@ static int hostap_enable_hostapd(PSDevice pDevice, int rtnl_locked)
apdev_priv = netdev_priv(pDevice->apdev);
*apdev_priv = *pDevice;
- memcpy(pDevice->apdev->dev_addr, dev->dev_addr, ETH_ALEN);
+ eth_hw_addr_inherit(pDevice->apdev, dev);
pDevice->apdev->netdev_ops = &apdev_netdev_ops;
diff --git a/drivers/staging/vt6655/ioctl.c b/drivers/staging/vt6655/ioctl.c
index 46e0e41..b5cd2e4 100644
--- a/drivers/staging/vt6655/ioctl.c
+++ b/drivers/staging/vt6655/ioctl.c
@@ -460,7 +460,7 @@ int private_ioctl(PSDevice pDevice, struct ifreq *rq)
}
if (sValue.dwValue == 1) {
DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "up wpadev\n");
- memcpy(pDevice->wpadev->dev_addr, pDevice->dev->dev_addr, ETH_ALEN);
+ eth_hw_addr_inherit(pDevice->wpadev, pDevice->dev);
pDevice->bWPADEVUp = true;
} else {
DBG_PRT(MSG_LEVEL_DEBUG, KERN_INFO "close wpadev\n");
diff --git a/drivers/staging/vt6655/wpactl.c b/drivers/staging/vt6655/wpactl.c
index 869f62c..e8d9ecd 100644
--- a/drivers/staging/vt6655/wpactl.c
+++ b/drivers/staging/vt6655/wpactl.c
@@ -96,7 +96,7 @@ static int wpa_init_wpadev(PSDevice pDevice)
wpadev_priv = netdev_priv(pDevice->wpadev);
*wpadev_priv = *pDevice;
- memcpy(pDevice->wpadev->dev_addr, dev->dev_addr, ETH_ALEN);
+ eth_hw_addr_inherit(pDevice->wpadev, dev);
pDevice->wpadev->base_addr = dev->base_addr;
pDevice->wpadev->irq = dev->irq;
pDevice->wpadev->mem_start = dev->mem_start;
--
1.7.10.4
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
next prev parent reply other threads:[~2013-08-30 16:08 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-30 16:08 [PATCH v2 net-next 0/9] set addr_assign_type when inheriting a dev_addr Bjørn Mork
2013-08-30 16:08 ` [PATCH v2 net-next 1/9] net: etherdevice: add address inherit helper Bjørn Mork
2013-08-30 16:08 ` [PATCH v2 net-next 2/9] net: vlan: inherit addr_assign_type along with dev_addr Bjørn Mork
2013-08-30 16:08 ` [PATCH v2 net-next 3/9] net: dsa: " Bjørn Mork
2013-08-30 16:08 ` [PATCH v2 net-next 4/9] net: macvlan: " Bjørn Mork
2013-08-30 16:08 ` [PATCH v2 net-next 5/9] net: team: " Bjørn Mork
2013-08-30 16:08 ` [PATCH v2 net-next 6/9] net: airo: " Bjørn Mork
[not found] ` <1377878932-26881-1-git-send-email-bjorn-yOkvZcmFvRU@public.gmane.org>
2013-08-30 16:08 ` [PATCH v2 net-next 7/9] net: hostap: " Bjørn Mork
2013-08-30 16:08 ` [PATCH v2 net-next 8/9] net: libertas: " Bjørn Mork
2013-08-30 16:08 ` Bjørn Mork [this message]
2013-08-30 16:56 ` [PATCH v2 net-next 9/9] staging: vt6655: " Greg Kroah-Hartman
2013-09-01 2:50 ` [PATCH v2 net-next 0/9] set addr_assign_type when inheriting a dev_addr David Miller
2013-09-03 7:38 ` Bjørn Mork
2013-09-04 1:41 ` David Miller
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=1377878932-26881-10-git-send-email-bjorn@mork.no \
--to=bjorn@mork.no \
--cc=devel@driverdev.osuosl.org \
--cc=forest@alittletooquiet.net \
--cc=gregkh@linuxfoundation.org \
--cc=netdev@vger.kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).