Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=c43bff43e0617dd56515b4ea42a8037c699c86f1 Commit: c43bff43e0617dd56515b4ea42a8037c699c86f1 Parent: 313b0d3d863453cb596ea42aed07f8e1a9b0a7e2 Author: Michael Wu <[EMAIL PROTECTED]> AuthorDate: Sun Jul 15 17:09:55 2007 -0700 Committer: John W. Linville <[EMAIL PROTECTED]> CommitDate: Mon Aug 6 15:06:03 2007 -0400
[PATCH] rtl8187: ensure priv->hwaddr is always valid conf->mac_addr is not guaranteed to be set. This ensures priv->hwaddr is always set to a valid mac address. Thanks to Johannes Berg <[EMAIL PROTECTED]> for finding this problem. Signed-off-by: Michael Wu <[EMAIL PROTECTED]> Signed-off-by: John W. Linville <[EMAIL PROTECTED]> --- drivers/net/wireless/rtl8187_dev.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/net/wireless/rtl8187_dev.c b/drivers/net/wireless/rtl8187_dev.c index cea8589..e61c6d5 100644 --- a/drivers/net/wireless/rtl8187_dev.c +++ b/drivers/net/wireless/rtl8187_dev.c @@ -466,7 +466,7 @@ static int rtl8187_add_interface(struct ieee80211_hw *dev, return -EOPNOTSUPP; } - priv->hwaddr = conf->mac_addr; + priv->hwaddr = conf->mac_addr ? conf->mac_addr : dev->wiphy->perm_addr; return 0; } - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html