Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 278657
b: refs/heads/master
c: 252efa4
h: refs/heads/master
i:
  278655: 3a79236
v: v3
  • Loading branch information
Eliad Peller authored and Luciano Coelho committed Oct 7, 2011
1 parent 5e9d921 commit 82a5ff8
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 9 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: f75c753f3c77b758fa5ace90c15b2ea3b7a3d46d
refs/heads/master: 252efa4f978a2901039fffc934060fb8ccf82ac7
8 changes: 4 additions & 4 deletions trunk/drivers/net/wireless/wl12xx/event.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ void wl1271_pspoll_work(struct work_struct *work)
int ret;

dwork = container_of(work, struct delayed_work, work);
wl = container_of(dwork, struct wl1271, pspoll_work);
vif = wl->vif; /* TODO: move work into vif struct */
wlvif = wl12xx_vif_to_data(vif);
wlvif = container_of(dwork, struct wl12xx_vif, pspoll_work);
vif = container_of((void *)wlvif, struct ieee80211_vif, drv_priv);
wl = wlvif->wl;

wl1271_debug(DEBUG_EVENT, "pspoll work");

Expand Down Expand Up @@ -90,7 +90,7 @@ static void wl1271_event_pspoll_delivery_fail(struct wl1271 *wl,
if (ret < 0)
return;
set_bit(WL1271_FLAG_PSPOLL_FAILURE, &wl->flags);
ieee80211_queue_delayed_work(wl->hw, &wl->pspoll_work,
ieee80211_queue_delayed_work(wl->hw, &wlvif->pspoll_work,
msecs_to_jiffies(delay));
}

Expand Down
8 changes: 5 additions & 3 deletions trunk/drivers/net/wireless/wl12xx/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1766,7 +1766,7 @@ static int wl1271_op_suspend(struct ieee80211_hw *hw,

wl1271_enable_interrupts(wl);
flush_work(&wl->tx_work);
flush_delayed_work(&wl->pspoll_work);
flush_delayed_work(&wlvif->pspoll_work);
flush_delayed_work(&wl->elp_work);

return 0;
Expand Down Expand Up @@ -1902,6 +1902,8 @@ static int wl12xx_init_vif_data(struct ieee80211_vif *vif)
wlvif->rate_set = CONF_TX_RATE_MASK_BASIC;
wlvif->beacon_int = WL1271_DEFAULT_BEACON_INT;

INIT_DELAYED_WORK(&wlvif->pspoll_work, wl1271_pspoll_work);

return 0;
}

Expand Down Expand Up @@ -1941,6 +1943,7 @@ static int wl1271_op_add_interface(struct ieee80211_hw *hw,
if (ret < 0)
goto out;

wlvif->wl = wl;
role_type = wl12xx_get_role_type(wl, wlvif);
if (role_type == WL12XX_INVALID_ROLE_TYPE) {
ret = -EINVAL;
Expand Down Expand Up @@ -2126,7 +2129,7 @@ static void __wl1271_op_remove_interface(struct wl1271 *wl,
del_timer_sync(&wl->rx_streaming_timer);
cancel_work_sync(&wl->rx_streaming_enable_work);
cancel_work_sync(&wl->rx_streaming_disable_work);
cancel_delayed_work_sync(&wl->pspoll_work);
cancel_delayed_work_sync(&wlvif->pspoll_work);
cancel_delayed_work_sync(&wl->elp_work);

mutex_lock(&wl->mutex);
Expand Down Expand Up @@ -4874,7 +4877,6 @@ struct ieee80211_hw *wl1271_alloc_hw(void)
skb_queue_head_init(&wl->deferred_tx_queue);

INIT_DELAYED_WORK(&wl->elp_work, wl1271_elp_work);
INIT_DELAYED_WORK(&wl->pspoll_work, wl1271_pspoll_work);
INIT_WORK(&wl->netstack_work, wl1271_netstack_work);
INIT_WORK(&wl->tx_work, wl1271_tx_work);
INIT_WORK(&wl->recovery_work, wl1271_recovery_work);
Expand Down
4 changes: 3 additions & 1 deletion trunk/drivers/net/wireless/wl12xx/wl12xx.h
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,6 @@ struct wl1271 {
struct completion *elp_compl;
struct completion *ps_compl;
struct delayed_work elp_work;
struct delayed_work pspoll_work;

/* counter for ps-poll delivery failures */
int ps_poll_failures;
Expand Down Expand Up @@ -604,6 +603,7 @@ struct wl1271_station {
};

struct wl12xx_vif {
struct wl1271 *wl;
u8 bss_type;
u8 p2p; /* we are using p2p role */
u8 role_id;
Expand Down Expand Up @@ -650,6 +650,8 @@ struct wl12xx_vif {

/* Session counter for the chipset */
int session_counter;

struct delayed_work pspoll_work;
};

static inline struct wl12xx_vif *wl12xx_vif_to_data(struct ieee80211_vif *vif)
Expand Down

0 comments on commit 82a5ff8

Please sign in to comment.