|
@@ -2833,6 +2833,7 @@ const char *hdd_action_type_to_string(enum netif_action_type action)
|
|
|
CASE_RETURN_STRING(WLAN_NETIF_VO_QUEUE_OFF);
|
|
|
CASE_RETURN_STRING(WLAN_NETIF_VI_QUEUE_ON);
|
|
|
CASE_RETURN_STRING(WLAN_NETIF_VI_QUEUE_OFF);
|
|
|
+ CASE_RETURN_STRING(WLAN_NETIF_BE_BK_QUEUE_ON);
|
|
|
CASE_RETURN_STRING(WLAN_NETIF_BE_BK_QUEUE_OFF);
|
|
|
CASE_RETURN_STRING(WLAN_WAKE_NON_PRIORITY_QUEUE);
|
|
|
CASE_RETURN_STRING(WLAN_STOP_NON_PRIORITY_QUEUE);
|
|
@@ -2863,6 +2864,7 @@ static void wlan_hdd_update_queue_oper_stats(struct hdd_adapter *adapter,
|
|
|
case WLAN_START_ALL_NETIF_QUEUE:
|
|
|
case WLAN_WAKE_ALL_NETIF_QUEUE:
|
|
|
case WLAN_START_ALL_NETIF_QUEUE_N_CARRIER:
|
|
|
+ case WLAN_NETIF_BE_BK_QUEUE_ON:
|
|
|
case WLAN_NETIF_VI_QUEUE_ON:
|
|
|
case WLAN_NETIF_VO_QUEUE_ON:
|
|
|
case WLAN_NETIF_PRIORITY_QUEUE_ON:
|
|
@@ -3131,67 +3133,101 @@ void wlan_hdd_netif_queue_control(struct hdd_adapter *adapter,
|
|
|
|
|
|
case WLAN_NETIF_PRIORITY_QUEUE_ON:
|
|
|
spin_lock_bh(&adapter->pause_map_lock);
|
|
|
- temp_map = adapter->pause_map;
|
|
|
- adapter->pause_map &= ~(1 << reason);
|
|
|
- netif_wake_subqueue(adapter->dev,
|
|
|
- HDD_LINUX_AC_HI_PRIO * TX_QUEUES_PER_AC);
|
|
|
- wlan_hdd_update_pause_time(adapter, temp_map);
|
|
|
+ if (reason == WLAN_DATA_FLOW_CTRL_PRI) {
|
|
|
+ temp_map = adapter->subqueue_pause_map;
|
|
|
+ adapter->subqueue_pause_map &= ~(1 << reason);
|
|
|
+ } else {
|
|
|
+ temp_map = adapter->pause_map;
|
|
|
+ adapter->pause_map &= ~(1 << reason);
|
|
|
+ }
|
|
|
+ if (!adapter->pause_map) {
|
|
|
+ netif_wake_subqueue(adapter->dev,
|
|
|
+ HDD_LINUX_AC_HI_PRIO * TX_QUEUES_PER_AC);
|
|
|
+ wlan_hdd_update_pause_time(adapter, temp_map);
|
|
|
+ }
|
|
|
spin_unlock_bh(&adapter->pause_map_lock);
|
|
|
break;
|
|
|
|
|
|
case WLAN_NETIF_PRIORITY_QUEUE_OFF:
|
|
|
spin_lock_bh(&adapter->pause_map_lock);
|
|
|
- netif_stop_subqueue(adapter->dev,
|
|
|
+ if (!adapter->pause_map) {
|
|
|
+ netif_stop_subqueue(adapter->dev,
|
|
|
HDD_LINUX_AC_HI_PRIO * TX_QUEUES_PER_AC);
|
|
|
- wlan_hdd_update_txq_timestamp(adapter->dev);
|
|
|
- wlan_hdd_update_unpause_time(adapter);
|
|
|
- adapter->pause_map |= (1 << reason);
|
|
|
+ wlan_hdd_update_txq_timestamp(adapter->dev);
|
|
|
+ wlan_hdd_update_unpause_time(adapter);
|
|
|
+ }
|
|
|
+ if (reason == WLAN_DATA_FLOW_CTRL_PRI)
|
|
|
+ adapter->subqueue_pause_map |= (1 << reason);
|
|
|
+ else
|
|
|
+ adapter->pause_map |= (1 << reason);
|
|
|
spin_unlock_bh(&adapter->pause_map_lock);
|
|
|
break;
|
|
|
|
|
|
case WLAN_NETIF_BE_BK_QUEUE_OFF:
|
|
|
spin_lock_bh(&adapter->pause_map_lock);
|
|
|
- hdd_stop_queues_for_ac(adapter->dev, HDD_LINUX_AC_BK);
|
|
|
- hdd_stop_queues_for_ac(adapter->dev, HDD_LINUX_AC_BE);
|
|
|
- wlan_hdd_update_txq_timestamp(adapter->dev);
|
|
|
- wlan_hdd_update_unpause_time(adapter);
|
|
|
- adapter->pause_map |= (1 << reason);
|
|
|
+ if (!adapter->pause_map) {
|
|
|
+ hdd_stop_queues_for_ac(adapter->dev, HDD_LINUX_AC_BK);
|
|
|
+ hdd_stop_queues_for_ac(adapter->dev, HDD_LINUX_AC_BE);
|
|
|
+ wlan_hdd_update_txq_timestamp(adapter->dev);
|
|
|
+ wlan_hdd_update_unpause_time(adapter);
|
|
|
+ }
|
|
|
+ adapter->subqueue_pause_map |= (1 << reason);
|
|
|
+ spin_unlock_bh(&adapter->pause_map_lock);
|
|
|
+ break;
|
|
|
+
|
|
|
+ case WLAN_NETIF_BE_BK_QUEUE_ON:
|
|
|
+ spin_lock_bh(&adapter->pause_map_lock);
|
|
|
+ temp_map = adapter->subqueue_pause_map;
|
|
|
+ adapter->subqueue_pause_map &= ~(1 << reason);
|
|
|
+ if (!adapter->pause_map) {
|
|
|
+ hdd_wake_queues_for_ac(adapter->dev, HDD_LINUX_AC_BK);
|
|
|
+ hdd_wake_queues_for_ac(adapter->dev, HDD_LINUX_AC_BE);
|
|
|
+ wlan_hdd_update_pause_time(adapter, temp_map);
|
|
|
+ }
|
|
|
spin_unlock_bh(&adapter->pause_map_lock);
|
|
|
break;
|
|
|
|
|
|
case WLAN_NETIF_VI_QUEUE_OFF:
|
|
|
spin_lock_bh(&adapter->pause_map_lock);
|
|
|
- hdd_stop_queues_for_ac(adapter->dev, HDD_LINUX_AC_VI);
|
|
|
- wlan_hdd_update_txq_timestamp(adapter->dev);
|
|
|
- wlan_hdd_update_unpause_time(adapter);
|
|
|
- adapter->pause_map |= (1 << reason);
|
|
|
+ if (!adapter->pause_map) {
|
|
|
+ hdd_stop_queues_for_ac(adapter->dev, HDD_LINUX_AC_VI);
|
|
|
+ wlan_hdd_update_txq_timestamp(adapter->dev);
|
|
|
+ wlan_hdd_update_unpause_time(adapter);
|
|
|
+ }
|
|
|
+ adapter->subqueue_pause_map |= (1 << reason);
|
|
|
spin_unlock_bh(&adapter->pause_map_lock);
|
|
|
break;
|
|
|
|
|
|
case WLAN_NETIF_VI_QUEUE_ON:
|
|
|
spin_lock_bh(&adapter->pause_map_lock);
|
|
|
- temp_map = adapter->pause_map;
|
|
|
- adapter->pause_map &= ~(1 << reason);
|
|
|
- hdd_wake_queues_for_ac(adapter->dev, HDD_LINUX_AC_VI);
|
|
|
- wlan_hdd_update_pause_time(adapter, temp_map);
|
|
|
+ temp_map = adapter->subqueue_pause_map;
|
|
|
+ adapter->subqueue_pause_map &= ~(1 << reason);
|
|
|
+ if (!adapter->pause_map) {
|
|
|
+ hdd_wake_queues_for_ac(adapter->dev, HDD_LINUX_AC_VI);
|
|
|
+ wlan_hdd_update_pause_time(adapter, temp_map);
|
|
|
+ }
|
|
|
spin_unlock_bh(&adapter->pause_map_lock);
|
|
|
break;
|
|
|
|
|
|
case WLAN_NETIF_VO_QUEUE_OFF:
|
|
|
spin_lock_bh(&adapter->pause_map_lock);
|
|
|
- hdd_stop_queues_for_ac(adapter->dev, HDD_LINUX_AC_VO);
|
|
|
- wlan_hdd_update_txq_timestamp(adapter->dev);
|
|
|
- wlan_hdd_update_unpause_time(adapter);
|
|
|
- adapter->pause_map |= (1 << reason);
|
|
|
+ if (!adapter->pause_map) {
|
|
|
+ hdd_stop_queues_for_ac(adapter->dev, HDD_LINUX_AC_VO);
|
|
|
+ wlan_hdd_update_txq_timestamp(adapter->dev);
|
|
|
+ wlan_hdd_update_unpause_time(adapter);
|
|
|
+ }
|
|
|
+ adapter->subqueue_pause_map |= (1 << reason);
|
|
|
spin_unlock_bh(&adapter->pause_map_lock);
|
|
|
break;
|
|
|
|
|
|
case WLAN_NETIF_VO_QUEUE_ON:
|
|
|
spin_lock_bh(&adapter->pause_map_lock);
|
|
|
- temp_map = adapter->pause_map;
|
|
|
- adapter->pause_map &= ~(1 << reason);
|
|
|
- hdd_wake_queues_for_ac(adapter->dev, HDD_LINUX_AC_VO);
|
|
|
- wlan_hdd_update_pause_time(adapter, temp_map);
|
|
|
+ temp_map = adapter->subqueue_pause_map;
|
|
|
+ adapter->subqueue_pause_map &= ~(1 << reason);
|
|
|
+ if (!adapter->pause_map) {
|
|
|
+ hdd_wake_queues_for_ac(adapter->dev, HDD_LINUX_AC_VO);
|
|
|
+ wlan_hdd_update_pause_time(adapter, temp_map);
|
|
|
+ }
|
|
|
spin_unlock_bh(&adapter->pause_map_lock);
|
|
|
break;
|
|
|
|
|
@@ -3273,7 +3309,12 @@ void wlan_hdd_netif_queue_control(struct hdd_adapter *adapter,
|
|
|
adapter->queue_oper_history[index].time = qdf_system_ticks();
|
|
|
adapter->queue_oper_history[index].netif_action = action;
|
|
|
adapter->queue_oper_history[index].netif_reason = reason;
|
|
|
- adapter->queue_oper_history[index].pause_map = adapter->pause_map;
|
|
|
+ if (reason >= WLAN_DATA_FLOW_CTRL_BE_BK)
|
|
|
+ adapter->queue_oper_history[index].pause_map =
|
|
|
+ adapter->subqueue_pause_map;
|
|
|
+ else
|
|
|
+ adapter->queue_oper_history[index].pause_map =
|
|
|
+ adapter->pause_map;
|
|
|
|
|
|
txq_hist_ptr = &adapter->queue_oper_history[index];
|
|
|
|