|
@@ -1582,10 +1582,13 @@ out:
|
|
static int wl1271_op_set_rts_threshold(struct ieee80211_hw *hw, u32 value)
|
|
static int wl1271_op_set_rts_threshold(struct ieee80211_hw *hw, u32 value)
|
|
{
|
|
{
|
|
struct wl1271 *wl = hw->priv;
|
|
struct wl1271 *wl = hw->priv;
|
|
- int ret;
|
|
|
|
|
|
+ int ret = 0;
|
|
|
|
|
|
mutex_lock(&wl->mutex);
|
|
mutex_lock(&wl->mutex);
|
|
|
|
|
|
|
|
+ if (unlikely(wl->state == WL1271_STATE_OFF))
|
|
|
|
+ goto out;
|
|
|
|
+
|
|
ret = wl1271_ps_elp_wakeup(wl, false);
|
|
ret = wl1271_ps_elp_wakeup(wl, false);
|
|
if (ret < 0)
|
|
if (ret < 0)
|
|
goto out;
|
|
goto out;
|