aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-3945.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-3945.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-3945.c32
1 files changed, 14 insertions, 18 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wireless/iwlwifi/iwl-3945.c
index 598e4eef4f40..d3406830c8e3 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945.c
+++ b/drivers/net/wireless/iwlwifi/iwl-3945.c
@@ -554,40 +554,36 @@ static void iwl3945_add_radiotap(struct iwl3945_priv *priv,
554 iwl3945_rt->rt_hdr.it_pad = 0; 554 iwl3945_rt->rt_hdr.it_pad = 0;
555 555
556 /* total header + data */ 556 /* total header + data */
557 put_unaligned(cpu_to_le16(sizeof(*iwl3945_rt)), 557 put_unaligned_le16(sizeof(*iwl3945_rt), &iwl3945_rt->rt_hdr.it_len);
558 &iwl3945_rt->rt_hdr.it_len);
559 558
560 /* Indicate all the fields we add to the radiotap header */ 559 /* Indicate all the fields we add to the radiotap header */
561 put_unaligned(cpu_to_le32((1 << IEEE80211_RADIOTAP_TSFT) | 560 put_unaligned_le32((1 << IEEE80211_RADIOTAP_TSFT) |
562 (1 << IEEE80211_RADIOTAP_FLAGS) | 561 (1 << IEEE80211_RADIOTAP_FLAGS) |
563 (1 << IEEE80211_RADIOTAP_RATE) | 562 (1 << IEEE80211_RADIOTAP_RATE) |
564 (1 << IEEE80211_RADIOTAP_CHANNEL) | 563 (1 << IEEE80211_RADIOTAP_CHANNEL) |
565 (1 << IEEE80211_RADIOTAP_DBM_ANTSIGNAL) | 564 (1 << IEEE80211_RADIOTAP_DBM_ANTSIGNAL) |
566 (1 << IEEE80211_RADIOTAP_DBM_ANTNOISE) | 565 (1 << IEEE80211_RADIOTAP_DBM_ANTNOISE) |
567 (1 << IEEE80211_RADIOTAP_ANTENNA)), 566 (1 << IEEE80211_RADIOTAP_ANTENNA),
568 &iwl3945_rt->rt_hdr.it_present); 567 &iwl3945_rt->rt_hdr.it_present);
569 568
570 /* Zero the flags, we'll add to them as we go */ 569 /* Zero the flags, we'll add to them as we go */
571 iwl3945_rt->rt_flags = 0; 570 iwl3945_rt->rt_flags = 0;
572 571
573 put_unaligned(cpu_to_le64(tsf), &iwl3945_rt->rt_tsf); 572 put_unaligned_le64(tsf, &iwl3945_rt->rt_tsf);
574 573
575 iwl3945_rt->rt_dbmsignal = signal; 574 iwl3945_rt->rt_dbmsignal = signal;
576 iwl3945_rt->rt_dbmnoise = noise; 575 iwl3945_rt->rt_dbmnoise = noise;
577 576
578 /* Convert the channel frequency and set the flags */ 577 /* Convert the channel frequency and set the flags */
579 put_unaligned(cpu_to_le16(stats->freq), &iwl3945_rt->rt_channelMHz); 578 put_unaligned_le16(stats->freq, &iwl3945_rt->rt_channelMHz);
580 if (!(phy_flags_hw & RX_RES_PHY_FLAGS_BAND_24_MSK)) 579 if (!(phy_flags_hw & RX_RES_PHY_FLAGS_BAND_24_MSK))
581 put_unaligned(cpu_to_le16(IEEE80211_CHAN_OFDM | 580 put_unaligned_le16(IEEE80211_CHAN_OFDM | IEEE80211_CHAN_5GHZ,
582 IEEE80211_CHAN_5GHZ),
583 &iwl3945_rt->rt_chbitmask); 581 &iwl3945_rt->rt_chbitmask);
584 else if (phy_flags_hw & RX_RES_PHY_FLAGS_MOD_CCK_MSK) 582 else if (phy_flags_hw & RX_RES_PHY_FLAGS_MOD_CCK_MSK)
585 put_unaligned(cpu_to_le16(IEEE80211_CHAN_CCK | 583 put_unaligned_le16(IEEE80211_CHAN_CCK | IEEE80211_CHAN_2GHZ,
586 IEEE80211_CHAN_2GHZ),
587 &iwl3945_rt->rt_chbitmask); 584 &iwl3945_rt->rt_chbitmask);
588 else /* 802.11g */ 585 else /* 802.11g */
589 put_unaligned(cpu_to_le16(IEEE80211_CHAN_OFDM | 586 put_unaligned_le16(IEEE80211_CHAN_OFDM | IEEE80211_CHAN_2GHZ,
590 IEEE80211_CHAN_2GHZ),
591 &iwl3945_rt->rt_chbitmask); 587 &iwl3945_rt->rt_chbitmask);
592 588
593 if (rate == -1) 589 if (rate == -1)