Skip to content

Commit

Permalink
wl1271: remove workaround for disconnection
Browse files Browse the repository at this point in the history
Now we're using a the idle information coming from mac80211 to decide when to
disconnect.  If we have joined (ie. we're listening to a channel), whenever
the interface goes to idle, we will issue a disconnect command.  So the
workaround to send a disconnect command before joining is not needed anymore.

Signed-off-by: Luciano Coelho <luciano.coelho@nokia.com>
Reviewed-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Luciano Coelho authored and John W. Linville committed Dec 28, 2009
1 parent c7f43e4 commit 9cf25fe
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions drivers/net/wireless/wl12xx/wl1271_cmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -344,19 +344,6 @@ int wl1271_cmd_join(struct wl1271 *wl)
do_cal = false;
}

/* FIXME: This is a workaround, because with the current stack, we
* cannot know when we have disassociated. So, if we have already
* joined, we disconnect before joining again. */
if (wl->joined) {
ret = wl1271_cmd_disconnect(wl);
if (ret < 0) {
wl1271_error("failed to disconnect before rejoining");
goto out;
}

wl->joined = false;
}

join = kzalloc(sizeof(*join), GFP_KERNEL);
if (!join) {
ret = -ENOMEM;
Expand Down Expand Up @@ -421,8 +408,6 @@ int wl1271_cmd_join(struct wl1271 *wl)
goto out_free;
}

wl->joined = true;

/*
* ugly hack: we should wait for JOIN_EVENT_COMPLETE_ID but to
* simplify locking we just sleep instead, for now
Expand Down

0 comments on commit 9cf25fe

Please sign in to comment.