aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi
diff options
context:
space:
mode:
authorTomas Winkler <tomas.winkler@intel.com>2008-07-10 07:28:42 -0400
committerJohn W. Linville <linville@tuxdriver.com>2008-07-14 14:52:57 -0400
commita05ffd395e1f1293d05a814ef697c12efa411ad8 (patch)
treeca1cc06ec3603d98cc79f18a1fcb1220900ba0f5 /drivers/net/wireless/iwlwifi
parentdf70b4aca5ef8a154a32ecbdd3c322d6d41a0d33 (diff)
iwlwif: remove compilation warnings iwl_add_radiotap
Use directly put_unaligned_leX instead of put_unaligned(cpu_to_leX Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-rx.c37
1 files changed, 17 insertions, 20 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-rx.c b/drivers/net/wireless/iwlwifi/iwl-rx.c
index 3e8500ecf598..e2d9afba38a5 100644
--- a/drivers/net/wireless/iwlwifi/iwl-rx.c
+++ b/drivers/net/wireless/iwlwifi/iwl-rx.c
@@ -29,6 +29,7 @@
29 29
30#include <linux/etherdevice.h> 30#include <linux/etherdevice.h>
31#include <net/mac80211.h> 31#include <net/mac80211.h>
32#include <asm/unaligned.h>
32#include "iwl-eeprom.h" 33#include "iwl-eeprom.h"
33#include "iwl-dev.h" 34#include "iwl-dev.h"
34#include "iwl-core.h" 35#include "iwl-core.h"
@@ -829,23 +830,22 @@ static void iwl_add_radiotap(struct iwl_priv *priv,
829 iwl4965_rt->rt_hdr.it_pad = 0; 830 iwl4965_rt->rt_hdr.it_pad = 0;
830 831
831 /* total header + data */ 832 /* total header + data */
832 put_unaligned(cpu_to_le16(sizeof(*iwl4965_rt)), 833 put_unaligned_le16(sizeof(*iwl4965_rt), &iwl4965_rt->rt_hdr.it_len);
833 &iwl4965_rt->rt_hdr.it_len);
834 834
835 /* Indicate all the fields we add to the radiotap header */ 835 /* Indicate all the fields we add to the radiotap header */
836 put_unaligned(cpu_to_le32((1 << IEEE80211_RADIOTAP_TSFT) | 836 put_unaligned_le32((1 << IEEE80211_RADIOTAP_TSFT) |
837 (1 << IEEE80211_RADIOTAP_FLAGS) | 837 (1 << IEEE80211_RADIOTAP_FLAGS) |
838 (1 << IEEE80211_RADIOTAP_RATE) | 838 (1 << IEEE80211_RADIOTAP_RATE) |
839 (1 << IEEE80211_RADIOTAP_CHANNEL) | 839 (1 << IEEE80211_RADIOTAP_CHANNEL) |
840 (1 << IEEE80211_RADIOTAP_DBM_ANTSIGNAL) | 840 (1 << IEEE80211_RADIOTAP_DBM_ANTSIGNAL) |
841 (1 << IEEE80211_RADIOTAP_DBM_ANTNOISE) | 841 (1 << IEEE80211_RADIOTAP_DBM_ANTNOISE) |
842 (1 << IEEE80211_RADIOTAP_ANTENNA)), 842 (1 << IEEE80211_RADIOTAP_ANTENNA),
843 &iwl4965_rt->rt_hdr.it_present); 843 &(iwl4965_rt->rt_hdr.it_present));
844 844
845 /* Zero the flags, we'll add to them as we go */ 845 /* Zero the flags, we'll add to them as we go */
846 iwl4965_rt->rt_flags = 0; 846 iwl4965_rt->rt_flags = 0;
847 847
848 put_unaligned(cpu_to_le64(tsf), &iwl4965_rt->rt_tsf); 848 put_unaligned_le64(tsf, &iwl4965_rt->rt_tsf);
849 849
850 iwl4965_rt->rt_dbmsignal = signal; 850 iwl4965_rt->rt_dbmsignal = signal;
851 iwl4965_rt->rt_dbmnoise = noise; 851 iwl4965_rt->rt_dbmnoise = noise;
@@ -853,17 +853,14 @@ static void iwl_add_radiotap(struct iwl_priv *priv,
853 /* Convert the channel frequency and set the flags */ 853 /* Convert the channel frequency and set the flags */
854 put_unaligned(cpu_to_le16(stats->freq), &iwl4965_rt->rt_channelMHz); 854 put_unaligned(cpu_to_le16(stats->freq), &iwl4965_rt->rt_channelMHz);
855 if (!(phy_flags_hw & RX_RES_PHY_FLAGS_BAND_24_MSK)) 855 if (!(phy_flags_hw & RX_RES_PHY_FLAGS_BAND_24_MSK))
856 put_unaligned(cpu_to_le16(IEEE80211_CHAN_OFDM | 856 put_unaligned_le16(IEEE80211_CHAN_OFDM | IEEE80211_CHAN_5GHZ,
857 IEEE80211_CHAN_5GHZ), 857 &iwl4965_rt->rt_chbitmask);
858 &iwl4965_rt->rt_chbitmask);
859 else if (phy_flags_hw & RX_RES_PHY_FLAGS_MOD_CCK_MSK) 858 else if (phy_flags_hw & RX_RES_PHY_FLAGS_MOD_CCK_MSK)
860 put_unaligned(cpu_to_le16(IEEE80211_CHAN_CCK | 859 put_unaligned_le16(IEEE80211_CHAN_CCK | IEEE80211_CHAN_2GHZ,
861 IEEE80211_CHAN_2GHZ), 860 &iwl4965_rt->rt_chbitmask);
862 &iwl4965_rt->rt_chbitmask);
863 else /* 802.11g */ 861 else /* 802.11g */
864 put_unaligned(cpu_to_le16(IEEE80211_CHAN_OFDM | 862 put_unaligned_le16(IEEE80211_CHAN_OFDM | IEEE80211_CHAN_2GHZ,
865 IEEE80211_CHAN_2GHZ), 863 &iwl4965_rt->rt_chbitmask);
866 &iwl4965_rt->rt_chbitmask);
867 864
868 if (rate == -1) 865 if (rate == -1)
869 iwl4965_rt->rt_rate = 0; 866 iwl4965_rt->rt_rate = 0;