diff options
author | Bing Zhao <bzhao@marvell.com> | 2012-08-27 23:32:54 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-09-07 15:03:41 -0400 |
commit | 84f6a95a265d3716537be91dc1bc04d229ad6000 (patch) | |
tree | 164287a075d08fc19da8d48f8bd1b0131a7cb564 /drivers/net/wireless/mwifiex/scan.c | |
parent | a3c2c4f6d8bcd473a7016db93da4f10b3f10f25f (diff) |
mwifiex: make use of is_zero_ether_addr()
Use is_zero_ether_addr() instead of directly using memcmp() to
determine if the ethernet address is all zeros.
Cc: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/mwifiex/scan.c')
-rw-r--r-- | drivers/net/wireless/mwifiex/scan.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/wireless/mwifiex/scan.c b/drivers/net/wireless/mwifiex/scan.c index 215d07e6c462..9e077e5fc64a 100644 --- a/drivers/net/wireless/mwifiex/scan.c +++ b/drivers/net/wireless/mwifiex/scan.c | |||
@@ -726,7 +726,6 @@ mwifiex_config_scan(struct mwifiex_private *priv, | |||
726 | struct mwifiex_ie_types_num_probes *num_probes_tlv; | 726 | struct mwifiex_ie_types_num_probes *num_probes_tlv; |
727 | struct mwifiex_ie_types_wildcard_ssid_params *wildcard_ssid_tlv; | 727 | struct mwifiex_ie_types_wildcard_ssid_params *wildcard_ssid_tlv; |
728 | struct mwifiex_ie_types_rates_param_set *rates_tlv; | 728 | struct mwifiex_ie_types_rates_param_set *rates_tlv; |
729 | const u8 zero_mac[ETH_ALEN] = { 0, 0, 0, 0, 0, 0 }; | ||
730 | u8 *tlv_pos; | 729 | u8 *tlv_pos; |
731 | u32 num_probes; | 730 | u32 num_probes; |
732 | u32 ssid_len; | 731 | u32 ssid_len; |
@@ -840,8 +839,7 @@ mwifiex_config_scan(struct mwifiex_private *priv, | |||
840 | * or BSSID filter applied to the scan results in the firmware. | 839 | * or BSSID filter applied to the scan results in the firmware. |
841 | */ | 840 | */ |
842 | if ((i && ssid_filter) || | 841 | if ((i && ssid_filter) || |
843 | memcmp(scan_cfg_out->specific_bssid, &zero_mac, | 842 | !is_zero_ether_addr(scan_cfg_out->specific_bssid)) |
844 | sizeof(zero_mac))) | ||
845 | *filtered_scan = true; | 843 | *filtered_scan = true; |
846 | } else { | 844 | } else { |
847 | scan_cfg_out->bss_mode = (u8) adapter->scan_mode; | 845 | scan_cfg_out->bss_mode = (u8) adapter->scan_mode; |