diff --git a/components/ipa/core/inc/wlan_ipa_core.h b/components/ipa/core/inc/wlan_ipa_core.h index c0a66ae9e817..af60703ad139 100644 --- a/components/ipa/core/inc/wlan_ipa_core.h +++ b/components/ipa/core/inc/wlan_ipa_core.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013-2020 The Linux Foundation. All rights reserved. + * Copyright (c) 2013-2021 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -592,7 +592,8 @@ static inline void ipa_set_rps_per_vdev(struct wlan_ipa_priv *ipa_ctx, uint8_t vdev_id, bool enable) { - ipa_ctx->rps_enable(vdev_id, enable); + if (ipa_ctx->rps_enable) + ipa_ctx->rps_enable(vdev_id, enable); } /** diff --git a/components/ipa/core/src/wlan_ipa_core.c b/components/ipa/core/src/wlan_ipa_core.c index cab86502813d..434f51568fab 100644 --- a/components/ipa/core/src/wlan_ipa_core.c +++ b/components/ipa/core/src/wlan_ipa_core.c @@ -2357,7 +2357,7 @@ static QDF_STATUS __wlan_ipa_wlan_evt(qdf_netdev_t net_dev, uint8_t device_mode, if (iface_ctx) wlan_ipa_cleanup_iface(iface_ctx); - if (qdf_ipa_get_lan_rx_napi()) + if (qdf_ipa_get_lan_rx_napi() && ipa_ctx->sap_num_connected_sta) ipa_set_rps_per_vdev(ipa_ctx, session_id, false); qdf_mutex_release(&ipa_ctx->event_lock);