|
@@ -2793,13 +2793,25 @@ static QDF_STATUS wlan_ipa_send_msg(qdf_netdev_t net_dev,
|
|
}
|
|
}
|
|
|
|
|
|
#if defined(QCA_CONFIG_RPS) && !defined(MDM_PLATFORM)
|
|
#if defined(QCA_CONFIG_RPS) && !defined(MDM_PLATFORM)
|
|
-void wlan_ipa_handle_multiple_sap_evt(struct wlan_ipa_priv *ipa_ctx,
|
|
|
|
- qdf_ipa_wlan_event type)
|
|
|
|
|
|
+/**
|
|
|
|
+ * wlan_ipa_handle_multiple_sap_evt() - Handle multiple SAP connect/disconnect
|
|
|
|
+ * @ipa_ctx: IPA global context
|
|
|
|
+ * @type: IPA event type
|
|
|
|
+ * @session_id: vdev id
|
|
|
|
+ *
|
|
|
|
+ * This function is used to disable pipes when multiple SAP are connected and
|
|
|
|
+ * enable pipes back when only one SAP is connected.
|
|
|
|
+ *
|
|
|
|
+ * Return: None
|
|
|
|
+ */
|
|
|
|
+static void wlan_ipa_handle_multiple_sap_evt(struct wlan_ipa_priv *ipa_ctx,
|
|
|
|
+ qdf_ipa_wlan_event type,
|
|
|
|
+ uint8_t session_id)
|
|
{
|
|
{
|
|
struct wlan_ipa_iface_context *iface_ctx;
|
|
struct wlan_ipa_iface_context *iface_ctx;
|
|
int i;
|
|
int i;
|
|
|
|
|
|
- if (type == QDF_IPA_AP_DISCONNECT) {
|
|
|
|
|
|
+ if (type == QDF_IPA_AP_DISCONNECT) {
|
|
ipa_debug("Multiple SAP disconnecting. Enabling IPA");
|
|
ipa_debug("Multiple SAP disconnecting. Enabling IPA");
|
|
|
|
|
|
if (ipa_ctx->sap_num_connected_sta > 0)
|
|
if (ipa_ctx->sap_num_connected_sta > 0)
|
|
@@ -2816,7 +2828,7 @@ void wlan_ipa_handle_multiple_sap_evt(struct wlan_ipa_priv *ipa_ctx,
|
|
break;
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- } else if (type == QDF_IPA_AP_CONNECT) {
|
|
|
|
|
|
+ } else if (type == QDF_IPA_AP_CONNECT) {
|
|
ipa_debug("Multiple SAP connected. Disabling IPA");
|
|
ipa_debug("Multiple SAP connected. Disabling IPA");
|
|
|
|
|
|
for (i = 0; i < WLAN_IPA_MAX_IFACE; i++) {
|
|
for (i = 0; i < WLAN_IPA_MAX_IFACE; i++) {
|
|
@@ -2834,6 +2846,27 @@ void wlan_ipa_handle_multiple_sap_evt(struct wlan_ipa_priv *ipa_ctx,
|
|
wlan_ipa_uc_handle_last_discon(ipa_ctx, true);
|
|
wlan_ipa_uc_handle_last_discon(ipa_ctx, true);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+#else
|
|
|
|
+/**
|
|
|
|
+ * wlan_ipa_handle_multiple_sap_evt() - Handle multiple SAP connect/disconnect
|
|
|
|
+ * @ipa_ctx: IPA global context
|
|
|
|
+ * @type: IPA event type
|
|
|
|
+ * @session_id: vdev id
|
|
|
|
+ *
|
|
|
|
+ * Enable IPA for new SAP when multiple SAP are turned on
|
|
|
|
+ *
|
|
|
|
+ * Return: None
|
|
|
|
+ */
|
|
|
|
+static void wlan_ipa_handle_multiple_sap_evt(struct wlan_ipa_priv *ipa_ctx,
|
|
|
|
+ qdf_ipa_wlan_event type,
|
|
|
|
+ uint8_t session_id)
|
|
|
|
+{
|
|
|
|
+ if (type == QDF_IPA_AP_CONNECT)
|
|
|
|
+ wlan_ipa_uc_offload_enable_disable(ipa_ctx,
|
|
|
|
+ WMI_AP_RX_DATA_OFFLOAD,
|
|
|
|
+ session_id,
|
|
|
|
+ true);
|
|
|
|
+}
|
|
#endif
|
|
#endif
|
|
|
|
|
|
static inline void
|
|
static inline void
|
|
@@ -3118,7 +3151,7 @@ static QDF_STATUS __wlan_ipa_wlan_evt(qdf_netdev_t net_dev, uint8_t device_mode,
|
|
if (qdf_ipa_get_lan_rx_napi() &&
|
|
if (qdf_ipa_get_lan_rx_napi() &&
|
|
ipa_ctx->num_sap_connected == 1) {
|
|
ipa_ctx->num_sap_connected == 1) {
|
|
wlan_ipa_handle_multiple_sap_evt(ipa_ctx,
|
|
wlan_ipa_handle_multiple_sap_evt(ipa_ctx,
|
|
- type);
|
|
|
|
|
|
+ type, session_id);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
@@ -3249,7 +3282,8 @@ static QDF_STATUS __wlan_ipa_wlan_evt(qdf_netdev_t net_dev, uint8_t device_mode,
|
|
qdf_mutex_release(&ipa_ctx->event_lock);
|
|
qdf_mutex_release(&ipa_ctx->event_lock);
|
|
if (qdf_ipa_get_lan_rx_napi() &&
|
|
if (qdf_ipa_get_lan_rx_napi() &&
|
|
(ipa_ctx->num_sap_connected > 1)) {
|
|
(ipa_ctx->num_sap_connected > 1)) {
|
|
- wlan_ipa_handle_multiple_sap_evt(ipa_ctx, type);
|
|
|
|
|
|
+ wlan_ipa_handle_multiple_sap_evt(ipa_ctx, type,
|
|
|
|
+ session_id);
|
|
} else {
|
|
} else {
|
|
wlan_ipa_uc_offload_enable_disable(ipa_ctx,
|
|
wlan_ipa_uc_offload_enable_disable(ipa_ctx,
|
|
WMI_AP_RX_DATA_OFFLOAD,
|
|
WMI_AP_RX_DATA_OFFLOAD,
|
|
@@ -3397,7 +3431,8 @@ static QDF_STATUS __wlan_ipa_wlan_evt(qdf_netdev_t net_dev, uint8_t device_mode,
|
|
|
|
|
|
if (qdf_ipa_get_lan_rx_napi() &&
|
|
if (qdf_ipa_get_lan_rx_napi() &&
|
|
(ipa_ctx->num_sap_connected == 1))
|
|
(ipa_ctx->num_sap_connected == 1))
|
|
- wlan_ipa_handle_multiple_sap_evt(ipa_ctx, type);
|
|
|
|
|
|
+ wlan_ipa_handle_multiple_sap_evt(ipa_ctx, type,
|
|
|
|
+ session_id);
|
|
|
|
|
|
qdf_mutex_release(&ipa_ctx->event_lock);
|
|
qdf_mutex_release(&ipa_ctx->event_lock);
|
|
break;
|
|
break;
|