Netdev List
 help / color / mirror / Atom feed
* [PATCH] d80211: configure hardware when the interface is brought up
@ 2007-01-26  0:37 Pavel Roskin
  0 siblings, 0 replies; only message in thread
From: Pavel Roskin @ 2007-01-26  0:37 UTC (permalink / raw)
  To: netdev

ieee80211_hw_config() is called from scanning functions and ioctl
handlers, but not when the interface is brought up.  This is
unreasonable.  Since the config function is provided by hardware drivers
to d80211, the later should be responsible for calling it in all
situations when the hardware needs to be reconfigured.

Without this patch, bcm43xx_d80211 needs the channel to be set again
after the interface goes down and up.  Similar problems are reported for
rt2x00 drivers.

Failure in ieee80211_hw_config() leads to the interface staying down.

Signed-off-by: Pavel Roskin <proski@gnu.org>
---

 net/d80211/ieee80211.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/net/d80211/ieee80211.c b/net/d80211/ieee80211.c
index 2f1dce5..7219416 100644
--- a/net/d80211/ieee80211.c
+++ b/net/d80211/ieee80211.c
@@ -2239,6 +2239,8 @@ static int ieee80211_open(struct net_device *dev)
 		res = 0;
 		if (local->ops->open)
 			res = local->ops->open(local_to_hw(local));
+		if (res == 0)
+			res = ieee80211_hw_config(local);
 		if (res == 0) {
 			res = dev_open(local->mdev);
 			if (res) {


-- 
Regards,
Pavel Roskin



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2007-01-26  0:37 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-01-26  0:37 [PATCH] d80211: configure hardware when the interface is brought up Pavel Roskin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox