[PATCH] iwlwifi: set correct base rate for A band in rs_dbgfs_set_mcs
authorRon Rindjunsky <ron.rindjunsky@intel.com>
Mon, 15 Oct 2007 12:40:56 +0000 (14:40 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 18 Oct 2007 19:46:52 +0000 (15:46 -0400)
This patch fixes base rate needed for fixed rate operation in A band

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/iwlwifi/iwl-4965-rs.c

index 60caaea210765928ebf2ad55dca124dd482d9b65..8dc78c0bf1ff26d5cff33c31e8e66399930ce225 100644 (file)
@@ -2021,12 +2021,18 @@ static int open_file_generic(struct inode *inode, struct file *file)
 static void rs_dbgfs_set_mcs(struct iwl_rate_scale_priv *rs_priv,
                                struct iwl_rate *mcs, int index)
 {
-       const u32 cck_rate = 0x820A;
+       u32 base_rate;
+
+       if (rs_priv->phymode == (u8) MODE_IEEE80211A)
+               base_rate = 0x800D;
+       else
+               base_rate = 0x820A;
+
        if (rs_priv->dbg_fixed.rate_n_flags) {
                if (index < 12)
                        mcs->rate_n_flags = rs_priv->dbg_fixed.rate_n_flags;
                else
-                       mcs->rate_n_flags = cck_rate;
+                       mcs->rate_n_flags = base_rate;
                IWL_DEBUG_RATE("Fixed rate ON\n");
                return;
        }