Linux wireless drivers development
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: John Linville <linville@tuxdriver.com>
Cc: Michael Wu <flamingice@sourmilk.net>,
	linux-wireless <linux-wireless@vger.kernel.org>,
	Zhu Yi <yi.zhu@intel.com>
Subject: [PATCH] iwlwifi: select proper rate control algorithm
Date: Sun, 28 Oct 2007 14:53:36 +0100	[thread overview]
Message-ID: <1193579616.5197.13.camel@johannes.berg> (raw)

Prior to this patch, iwlwifi would always use the first
registered rate control algorithm which, depending on system
setup, could be anything. After the mac80211 patch to make
the simple algorithm built-in, it would always be simple.

This has always been a bug in iwlwifi.

This fixes it by requesting that mac80211 selects the right
rate control algorithm.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>

---
Untested, and the iwlwifi base code that registers rate control
algorithms is a *total* mess. They should only be registered once at
module load rather than at hardware probe time! Hence, I have no idea
whether this will suffice or if rate control algorithm initialisation
has to be rewritten.

 drivers/net/wireless/iwlwifi/iwl3945-base.c |    2 ++
 drivers/net/wireless/iwlwifi/iwl4965-base.c |    2 ++
 2 files changed, 4 insertions(+)

--- linux-2.6.orig/drivers/net/wireless/iwlwifi/iwl3945-base.c	2007-10-28 14:31:02.845330022 +0100
+++ linux-2.6/drivers/net/wireless/iwlwifi/iwl3945-base.c	2007-10-28 14:31:54.255349989 +0100
@@ -8317,6 +8317,8 @@ static int iwl_pci_probe(struct pci_dev 
 	}
 	SET_IEEE80211_DEV(hw, &pdev->dev);
 
+	hw->rate_control_algorithm = "iwl-3945-rs";
+
 	IWL_DEBUG_INFO("*** LOAD DRIVER ***\n");
 	priv = hw->priv;
 	priv->hw = hw;
--- linux-2.6.orig/drivers/net/wireless/iwlwifi/iwl4965-base.c	2007-10-28 14:31:03.005056368 +0100
+++ linux-2.6/drivers/net/wireless/iwlwifi/iwl4965-base.c	2007-10-28 14:32:07.735049425 +0100
@@ -8918,6 +8918,8 @@ static int iwl_pci_probe(struct pci_dev 
 	}
 	SET_IEEE80211_DEV(hw, &pdev->dev);
 
+	hw->rate_control_algorithm = "iwl-4965-rs";
+
 	IWL_DEBUG_INFO("*** LOAD DRIVER ***\n");
 	priv = hw->priv;
 	priv->hw = hw;



             reply	other threads:[~2007-10-28 13:52 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-28 13:53 Johannes Berg [this message]
2007-10-29  2:40 ` [PATCH] iwlwifi: select proper rate control algorithm Zhu Yi
2007-10-29  8:07   ` Johannes Berg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1193579616.5197.13.camel@johannes.berg \
    --to=johannes@sipsolutions.net \
    --cc=flamingice@sourmilk.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=yi.zhu@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox