Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 278692
b: refs/heads/master
c: e4120df
h: refs/heads/master
v: v3
  • Loading branch information
Eliad Peller authored and Luciano Coelho committed Oct 11, 2011
1 parent a834d26 commit a6b0965
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f750c82045d8f5d0d6d59e517eb485ffbbe014b2
refs/heads/master: e4120df982c2051f3cfc02f6278798c5166a72f8
2 changes: 2 additions & 0 deletions trunk/drivers/net/wireless/wl12xx/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2282,6 +2282,8 @@ static void __wl1271_op_remove_interface(struct wl1271 *wl,

wl12xx_tx_reset_wlvif(wl, wlvif);
wl1271_free_ap_keys(wl, wlvif);
if (wl->last_wlvif == wlvif)
wl->last_wlvif = NULL;
list_del(&wlvif->list);
memset(wlvif->ap.sta_hlid_map, 0, sizeof(wlvif->ap.sta_hlid_map));
wlvif->role_id = WL12XX_INVALID_ROLE_ID;
Expand Down
26 changes: 20 additions & 6 deletions trunk/drivers/net/wireless/wl12xx/tx.c
Original file line number Diff line number Diff line change
Expand Up @@ -590,14 +590,28 @@ static struct sk_buff *wl12xx_vif_skb_dequeue(struct wl1271 *wl,
static struct sk_buff *wl1271_skb_dequeue(struct wl1271 *wl)
{
unsigned long flags;
struct wl12xx_vif *wlvif;
struct wl12xx_vif *wlvif = wl->last_wlvif;
struct sk_buff *skb = NULL;

/* TODO: rememeber last vif and consider it */
wl12xx_for_each_wlvif(wl, wlvif) {
skb = wl12xx_vif_skb_dequeue(wl, wlvif);
if (skb)
break;
if (wlvif) {
wl12xx_for_each_wlvif_continue(wl, wlvif) {
skb = wl12xx_vif_skb_dequeue(wl, wlvif);
if (skb) {
wl->last_wlvif = wlvif;
break;
}
}
}

/* do another pass */
if (!skb) {
wl12xx_for_each_wlvif(wl, wlvif) {
skb = wl12xx_vif_skb_dequeue(wl, wlvif);
if (skb) {
wl->last_wlvif = wlvif;
break;
}
}
}

if (!skb &&
Expand Down
6 changes: 6 additions & 0 deletions trunk/drivers/net/wireless/wl12xx/wl12xx.h
Original file line number Diff line number Diff line change
Expand Up @@ -552,6 +552,9 @@ struct wl1271 {

/* AP-mode - number of currently connected stations */
int active_sta_count;

/* last wlvif we transmitted from */
struct wl12xx_vif *last_wlvif;
};

struct wl1271_station {
Expand Down Expand Up @@ -693,6 +696,9 @@ struct ieee80211_vif *wl12xx_wlvif_to_vif(struct wl12xx_vif *wlvif)
#define wl12xx_for_each_wlvif(wl, wlvif) \
list_for_each_entry(wlvif, &wl->wlvif_list, list)

#define wl12xx_for_each_wlvif_continue(wl, wlvif) \
list_for_each_entry_continue(wlvif, &wl->wlvif_list, list)

#define wl12xx_for_each_wlvif_bss_type(wl, wlvif, _bss_type) \
wl12xx_for_each_wlvif(wl, wlvif) \
if (wlvif->bss_type == _bss_type)
Expand Down

0 comments on commit a6b0965

Please sign in to comment.