summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/libertas/assoc.c
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw2@infradead.org>2007-12-13 00:32:36 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 15:07:07 -0800
commit860621347e88b23517fc4ec93fa5af940401c3ec (patch)
tree059223640a79bfe60f0dd9fe3c15d5656cac740a /drivers/net/wireless/libertas/assoc.c
parent020f3d0001cb249ceae623c1a7ae0c196326ef3f (diff)
downloadop-kernel-dev-860621347e88b23517fc4ec93fa5af940401c3ec.zip
op-kernel-dev-860621347e88b23517fc4ec93fa5af940401c3ec.tar.gz
libertas: pass channel argument directly to lbs_mesh_config()
There is weirdness here; the firmware seems to refuse to change channels at will. Signed-off-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/libertas/assoc.c')
-rw-r--r--drivers/net/wireless/libertas/assoc.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/net/wireless/libertas/assoc.c b/drivers/net/wireless/libertas/assoc.c
index ff976eb..cd8e043 100644
--- a/drivers/net/wireless/libertas/assoc.c
+++ b/drivers/net/wireless/libertas/assoc.c
@@ -205,13 +205,14 @@ static int assoc_helper_channel(struct lbs_private *priv,
goto done;
if (priv->mesh_dev) {
- /* Disconnect mesh while associating -- otherwise it
- won't let us change channels */
- lbs_mesh_config(priv, 0);
+ /* Change mesh channel first; 21.p21 firmware won't let
+ you change channel otherwise (even though it'll return
+ an error to this */
+ lbs_mesh_config(priv, 0, assoc_req->channel);
}
lbs_deb_assoc("ASSOC: channel: %d -> %d\n",
- priv->curbssparams.channel, assoc_req->channel);
+ priv->curbssparams.channel, assoc_req->channel);
ret = lbs_set_channel(priv, assoc_req->channel);
if (ret < 0)
@@ -244,7 +245,7 @@ static int assoc_helper_channel(struct lbs_private *priv,
restore_mesh:
if (priv->mesh_dev)
- lbs_mesh_config(priv, 1);
+ lbs_mesh_config(priv, 1, priv->curbssparams.channel);
done:
lbs_deb_leave_args(LBS_DEB_ASSOC, "ret %d", ret);
OpenPOWER on IntegriCloud