From: "Bjørn Mork" <bjorn-yOkvZcmFvRU@public.gmane.org>
To: netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Cc: "Bjørn Mork" <bjorn-yOkvZcmFvRU@public.gmane.org>,
"John W. Linville"
<linville-2XuSBdqkA4R54TAoqtyWWQ@public.gmane.org>,
linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
"Jouni Malinen" <j@w1.fi>
Subject: [PATCH v2 net-next 7/9] net: hostap: inherit addr_assign_type along with dev_addr
Date: Fri, 30 Aug 2013 18:08:50 +0200 [thread overview]
Message-ID: <1377878932-26881-8-git-send-email-bjorn@mork.no> (raw)
In-Reply-To: <1377878932-26881-1-git-send-email-bjorn-yOkvZcmFvRU@public.gmane.org>
A device inheriting a random or set address should reflect this in
its addr_assign_type.
Cc: Jouni Malinen <j@w1.fi>
Signed-off-by: Bjørn Mork <bjorn-yOkvZcmFvRU@public.gmane.org>
---
drivers/net/wireless/hostap/hostap_hw.c | 2 +-
drivers/net/wireless/hostap/hostap_main.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/hostap/hostap_hw.c b/drivers/net/wireless/hostap/hostap_hw.c
index 6307a4e..c275dc1 100644
--- a/drivers/net/wireless/hostap/hostap_hw.c
+++ b/drivers/net/wireless/hostap/hostap_hw.c
@@ -1425,7 +1425,7 @@ static int prism2_hw_init2(struct net_device *dev, int initial)
}
list_for_each(ptr, &local->hostap_interfaces) {
iface = list_entry(ptr, struct hostap_interface, list);
- memcpy(iface->dev->dev_addr, dev->dev_addr, ETH_ALEN);
+ eth_hw_addr_inherit(iface->dev, dev);
}
} else if (local->fw_ap)
prism2_check_sta_fw_version(local);
diff --git a/drivers/net/wireless/hostap/hostap_main.c b/drivers/net/wireless/hostap/hostap_main.c
index e4f56ad..a1257c9 100644
--- a/drivers/net/wireless/hostap/hostap_main.c
+++ b/drivers/net/wireless/hostap/hostap_main.c
@@ -66,7 +66,7 @@ struct net_device * hostap_add_interface(struct local_info *local,
list_add(&iface->list, &local->hostap_interfaces);
mdev = local->dev;
- memcpy(dev->dev_addr, mdev->dev_addr, ETH_ALEN);
+ eth_hw_addr_inherit(dev, mdev);
dev->base_addr = mdev->base_addr;
dev->irq = mdev->irq;
dev->mem_start = mdev->mem_start;
--
1.7.10.4
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
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 ` Bjørn Mork [this message]
2013-08-30 16:08 ` [PATCH v2 net-next 8/9] net: libertas: " Bjørn Mork
2013-08-30 16:08 ` [PATCH v2 net-next 9/9] staging: vt6655: " Bjørn Mork
2013-08-30 16:56 ` 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-8-git-send-email-bjorn@mork.no \
--to=bjorn-yokvzcmfvru@public.gmane.org \
--cc=j@w1.fi \
--cc=linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linville-2XuSBdqkA4R54TAoqtyWWQ@public.gmane.org \
--cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.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).