From: Gertjan van Wingerde Date: Sun, 30 Jan 2011 12:23:03 +0000 (+0100) Subject: rt2x00: Copy the MAC address to the WCID entry properly. X-Git-Tag: v3.12-rc1~6925^2~417^2~7 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=10026f77b3555af13e43b8de0a91ad94cd2119d7;p=kernel%2Fkernel-generic.git rt2x00: Copy the MAC address to the WCID entry properly. Use the specific mac field of the wcid_entry structure to copy the MAC address to, instead of just overwriting the structure. Previous code resulted in the same, but this form is cleaner. Signed-off-by: Gertjan van Wingerde Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c index 4c34fce..c9bf074 100644 --- a/drivers/net/wireless/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/rt2x00/rt2800lib.c @@ -1030,7 +1030,7 @@ static void rt2800_config_wcid_attr(struct rt2x00_dev *rt2x00dev, memset(&wcid_entry, 0, sizeof(wcid_entry)); if (crypto->cmd == SET_KEY) - memcpy(&wcid_entry, crypto->address, ETH_ALEN); + memcpy(wcid_entry.mac, crypto->address, ETH_ALEN); rt2800_register_multiwrite(rt2x00dev, offset, &wcid_entry, sizeof(wcid_entry)); }