Lines Matching refs:wl
19 struct wl1251 *wl; in wl1251_elp_work() local
22 wl = container_of(dwork, struct wl1251, elp_work); in wl1251_elp_work()
26 mutex_lock(&wl->mutex); in wl1251_elp_work()
28 if (wl->elp || wl->station_mode == STATION_ACTIVE_MODE) in wl1251_elp_work()
32 wl1251_write_elp(wl, HW_ACCESS_ELP_CTRL_REG_ADDR, ELPCTRL_SLEEP); in wl1251_elp_work()
33 wl->elp = true; in wl1251_elp_work()
36 mutex_unlock(&wl->mutex); in wl1251_elp_work()
42 void wl1251_ps_elp_sleep(struct wl1251 *wl) in wl1251_ps_elp_sleep() argument
46 if (wl->station_mode != STATION_ACTIVE_MODE) { in wl1251_ps_elp_sleep()
48 ieee80211_queue_delayed_work(wl->hw, &wl->elp_work, delay); in wl1251_ps_elp_sleep()
52 int wl1251_ps_elp_wakeup(struct wl1251 *wl) in wl1251_ps_elp_wakeup() argument
57 cancel_delayed_work(&wl->elp_work); in wl1251_ps_elp_wakeup()
59 if (!wl->elp) in wl1251_ps_elp_wakeup()
67 wl1251_write_elp(wl, HW_ACCESS_ELP_CTRL_REG_ADDR, ELPCTRL_WAKE_UP); in wl1251_ps_elp_wakeup()
69 elp_reg = wl1251_read_elp(wl, HW_ACCESS_ELP_CTRL_REG_ADDR); in wl1251_ps_elp_wakeup()
81 elp_reg = wl1251_read_elp(wl, HW_ACCESS_ELP_CTRL_REG_ADDR); in wl1251_ps_elp_wakeup()
87 wl->elp = false; in wl1251_ps_elp_wakeup()
92 int wl1251_ps_set_mode(struct wl1251 *wl, enum wl1251_station_mode mode) in wl1251_ps_set_mode() argument
101 ret = wl1251_acx_beacon_filter_opt(wl, true); in wl1251_ps_set_mode()
105 ret = wl1251_acx_wake_up_conditions(wl, in wl1251_ps_set_mode()
107 wl->listen_int); in wl1251_ps_set_mode()
111 ret = wl1251_acx_bet_enable(wl, WL1251_ACX_BET_ENABLE, in wl1251_ps_set_mode()
116 ret = wl1251_cmd_ps_mode(wl, CHIP_POWER_SAVE_MODE); in wl1251_ps_set_mode()
120 ret = wl1251_acx_sleep_auth(wl, WL1251_PSM_ELP); in wl1251_ps_set_mode()
127 ret = wl1251_acx_sleep_auth(wl, WL1251_PSM_ELP); in wl1251_ps_set_mode()
131 ret = wl1251_cmd_template_set(wl, CMD_DISCONNECT, NULL, 0); in wl1251_ps_set_mode()
139 ret = wl1251_acx_sleep_auth(wl, WL1251_PSM_CAM); in wl1251_ps_set_mode()
144 ret = wl1251_acx_bet_enable(wl, WL1251_ACX_BET_DISABLE, in wl1251_ps_set_mode()
150 ret = wl1251_acx_beacon_filter_opt(wl, false); in wl1251_ps_set_mode()
154 ret = wl1251_acx_wake_up_conditions(wl, in wl1251_ps_set_mode()
156 wl->listen_int); in wl1251_ps_set_mode()
160 ret = wl1251_cmd_ps_mode(wl, CHIP_ACTIVE_MODE); in wl1251_ps_set_mode()
166 wl->station_mode = mode; in wl1251_ps_set_mode()