Added wait event for power save request till confirm form firmware is received
PATCH 1/1 Added wait event for power save request till confirm form firmware is received
From: Sanjay Kumar Konduri <[email protected]>
Signed-off-by Sanjay Kumar Konduri <[email protected]>
--- ubuntu/rsi/rsi_91x_main.c | 1 + ubuntu/rsi/rsi_91x_mgmt.c | 5 +++++ ubuntu/rsi/rsi_main.h | 1 + 3 files changed, 7 insertions(+)
ubuntu/rsi/rsi_91x_main.c +1 -0
@@ -382,6 +382,7 @@ struct rsi_hw *ven_rsi_91x_init(void)#ifdef CONFIG_HW_SCAN_OFFLOAD rsi_init_event (&common->chan_set_event);rsi_init_event (&common->probe_cfm_event); +rsi_init_event (&common->mgmt_cfm_event);rsi_init_event (&common->chan_change_event);rsi_init_event (&common->cancel_hw_scan_event); common->scan_workqueue =
ubuntu/rsi/rsi_91x_mgmt.c +5 -0
@@ -2407,6 +2407,8 @@ void rsi_scan_start(struct work_struct *work) common->scan_in_prog = true;rsi_disable_ps (common->priv); +rsi_reset_event (&common->mgmt_cfm_event); +rsi_wait_event (&common->mgmt_cfm_event,msecs_to_jiffies (2000 ));for (ii =0 ; ii < scan_req->n_channels ; ii++) {if (common->iface_down)
@@ -2470,6 +2472,8 @@ void rsi_scan_start(struct work_struct *work)del_timer (&common->scan_timer); common->scan_in_prog = false;rsi_enable_ps (common->priv); +rsi_reset_event (&common->mgmt_cfm_event); +rsi_wait_event (&common->mgmt_cfm_event,msecs_to_jiffies (2000 ));#if (LINUX_VERSION_CODE >=KERNEL_VERSION (4 ,9 ,0 )) info.aborted = false;ieee80211_scan_completed (common->priv->hw, &info);
@@ -2693,6 +2697,7 @@ static int rsi_handle_ta_confirm(struct rsi_common *common, u8 *msg)case WAKEUP_SLEEP_REQUEST :ven_rsi_dbg (INFO_ZONE ,"Wakeup/Sleep confirmation.\n" ); +rsi_set_event (&common->mgmt_cfm_event);return rsi_handle_ps_confirm (adapter, msg);case BG_SCAN_PROBE_REQ :
ubuntu/rsi/rsi_main.h +1 -0
@@ -376,6 +376,7 @@ struct rsi_common {struct work_struct scan_work;struct rsi_event chan_set_event;struct rsi_event probe_cfm_event; +struct rsi_event mgmt_cfm_event;struct rsi_event chan_change_event;struct rsi_event cancel_hw_scan_event;struct timer_list scan_timer;
Signature · 1 line
2.7.4
Quoted 64 lines · Siva Rebbagondla
From: Sanjay Kumar Konduri <[email protected]>
Signed-off-by Sanjay Kumar Konduri <[email protected]>--- ubuntu/rsi/rsi_91x_main.c | 1 + ubuntu/rsi/rsi_91x_mgmt.c | 5 +++++ ubuntu/rsi/rsi_main.h | 1 + 3 files changed, 7 insertions(+)ubuntu/rsi/rsi_91x_main.c +1
-0@@ -382,6 +382,7 @@ struct rsi_hw *ven_rsi_91x_init(void)#ifdef CONFIG_HW_SCAN_OFFLOAD rsi_init_event (&common->chan_set_event);rsi_init_event (&common->probe_cfm_event); +rsi_init_event (&common->mgmt_cfm_event);rsi_init_event (&common->chan_change_event);rsi_init_event (&common->cancel_hw_scan_event); common->scan_workqueue =ubuntu/rsi/rsi_91x_mgmt.c +5
-0@@ -2407,6 +2407,8 @@ void rsi_scan_start(struct work_struct *work) common->scan_in_prog = true;rsi_disable_ps (common->priv); +rsi_reset_event (&common->mgmt_cfm_event); +rsi_wait_event (&common->mgmt_cfm_event,msecs_to_jiffies (2000 ));for (ii =0 ; ii < scan_req->n_channels ; ii++) {if (common->iface_down)@@ -2470,6 +2472,8 @@ void rsi_scan_start(struct work_struct *work)del_timer (&common->scan_timer); common->scan_in_prog = false;rsi_enable_ps (common->priv); +rsi_reset_event (&common->mgmt_cfm_event); +rsi_wait_event (&common->mgmt_cfm_event,msecs_to_jiffies (2000 ));#if (LINUX_VERSION_CODE >=KERNEL_VERSION (4 ,9 ,0 )) info.aborted = false;ieee80211_scan_completed (common->priv->hw, &info);@@ -2693,6 +2697,7 @@ static int rsi_handle_ta_confirm(struct rsi_common *common, u8 *msg)case WAKEUP_SLEEP_REQUEST :ven_rsi_dbg (INFO_ZONE ,"Wakeup/Sleep confirmation.\n" ); +rsi_set_event (&common->mgmt_cfm_event);return rsi_handle_ps_confirm (adapter, msg);case BG_SCAN_PROBE_REQ :ubuntu/rsi/rsi_main.h +1
-1@@ -376,6 +376,7 @@ struct rsi_common {struct work_struct scan_work;struct rsi_event chan_set_event;struct rsi_event probe_cfm_event; +struct rsi_event mgmt_cfm_event;struct rsi_event chan_change_event;struct rsi_event cancel_hw_scan_event;struct timer_list scan_timer; --
Quoted 2 lines
2.7.4
Please ignore this. It got sent by mistake.
Thanks,
Siva Rebbagondla