Commit Graph

226 Commits

Author SHA1 Message Date
Azmath Mohammed
842dc538f3 qcacld-3.0: Display control pipes info on WOW ack failure
Display control pipes info on WOW ack failure which helps to
debug issues when full debug history is not available.

Change-Id: I6a84aa01c07831b7109d0741337cae6ac0be2f44
CRs-Fixed: 3246284
2022-07-22 02:43:38 -07:00
Vinod Kumar Pirla
6fad793761 qcacld-3.0: Check dynamic NS offload based on trigger
Currently a userspace request to enable NS offload dynamically
gets rejected if the offloads are in disabled state.

After this change, when a request to enable or disable of NS offloads
is received in the host and if the trigger type is to dynamically update
the NS offloads, then update the dynamic offload configuations and inform
the FW.

Change-Id: Ifb4a1d37b5f2e6c89d043b00f9cc0aaf426d870e
CRs-Fixed: 3237980
2022-07-19 01:35:44 -07:00
Ananya Gupta
346a64fc9c qcacld-3.0: Register PM QOS and bus suspend module
With restructuring in hif runtime pm module, modules are
required to register with the hif runtime pm module. Also,
link states are depreciated.
This change registers PM QOS and bus suspend modules which
use runtime PM module and replace link state with resuming
link up state in PMO resume.

Change-Id: I0df48e3d31a1fb0f03faaa0617b48937c9bc224b
CRs-Fixed: 3169425
2022-06-18 23:11:04 -07:00
David Oladunjoye
5f4f7cf521 qcacld-3.0: pmo: Replace fallthrough comment withattribute
-Wimplicit-fallthrough is being enabled by default. Some compilers
such as clang require the attribute instead of just a fallthrough comment.

Change-Id: If55d68cb76589b39b88d859ea4d9fa6e10246c7e
CRs-Fixed: 3217399
2022-06-16 18:49:36 -07:00
Aravind Kishore Sukla
8282e8af3c qcacld-3.0: Replace kmsg logs to debug logs
Change kernel log level to debug level

Change-Id: I1efa9a0498acd81f2a9a12d5712299609eb5bd06
CRs-Fixed: 3182121
2022-05-06 09:49:38 -07:00
Jianmin Zhu
255d161802 qcacld-3.0: Revert "Reconfig ITO when enter WoW for runtime pm"
Avoid sending any new WMI command during RTPM WoW sequence.

Change-Id: I4313257cbf8f83e79a74970cdff5a91d9c1eebb0
CRs-Fixed: 3157005
2022-03-24 18:16:11 -07:00
Jianmin Zhu
89d99afd4c qcacld-3.0: Revert "Fix assert for wmi cmd for invalid vdev"
Avoid sending any new WMI command during RTPM WoW sequence.

Change-Id: I78554358c2f225a9ead0dd347174b1a3189300f3
CRs-Fixed: 3157005
2022-03-24 18:16:05 -07:00
Ashish
f853df3d5b Revert "qcacld-3.0: Fix arp offload not sent when suspend"
This reverts commit I06ea617df49287ee87e7b5bf8b20971b581dedf1

which introduced a fix to enable/disable arp offload on every
suspend/resume even if gActiveModeOffload is enabled, which is
not correct. The expectation here is that if gActiveModeOffload
is enabled, host should enable arp offload only onece and it
should not disable on any condition.

Change-Id: Ifc4ff1c0a39cc4c17e9a292ef8b0ebabd766a710
CRs-Fixed: 3147896
2022-03-23 11:06:21 -07:00
Arun Kumar Khandavalli
2fa9d87942 qcacld-3.0: Configure the mld address wow pattern during vdev create
Currently mac address is getting configured as the wow pattern
while the vdev is getting created, configure the mld address also
during the vdev creation so during legacy connection or roaming
between the ml-legacy vice versa there wont be packet drops because
of pattern mismatch.

Change-Id: I9b98649bca132a6665f2e4dd94d9c6b840223827
CRs-Fixed: 3124115
2022-03-22 10:43:52 -07:00
Jianmin Zhu
24bfb9a343 qcacld-3.0: Fix assert for wmi cmd for invalid vdev
During vdev creating, RTPM suspend/resume may happen, after vdev
created in host, if ITO config wmi cmd is sent to firmware
before vdev create wmi cmd, firmware will assert for invalid
vdev.

To fix it, only config ITO when vdev is up.

Change-Id: I3d744d7fffd9afc7780d3a19c92613a94556cfa0
CRs-Fixed: 3152034
2022-03-16 22:01:28 -07:00
Pragaspathi Thilagaraj
c5e40fc31a qcacld-3.0: Make PASN events as wakeable
PASN peer create request event and deauth events need
host actions and notifying the userspace.

So register for PASN events to wake up host.

Change-Id: Ic83f10984d4e4d5ee0f1e8a5d7c4fbc321395a26
CRs-Fixed: 3150120
2022-03-15 20:43:47 -07:00
Jianmin Zhu
d813137bb6 qcacld-3.0: Reconfig ITO when enter WoW for runtime pm
Some rogue AP sends beacon frames with TIM bit set for long time,
DUT STA need response a qos null frame, if ITO(inactive timeout) is 200ms,
STA can't get a chance go to sleep for long time during WoW, assert will
happen at last.
To fix it, for both system suspend and runtime suspend/resume, config
ITO to short value(50ms) when trigger FW to enter WoW mode, and config
ITO to default value(200ms) after exiting WoW mode.

Change-Id: I8f84afaf2ba030bbb9acf5c7ea78de583c634424
CRs-Fixed: 3146685
2022-03-09 08:04:08 -08:00
Jianmin Zhu
d79afa8020 qcacld-3.0: Fix arp offload not sent when suspend
When host resume, check arp offload status wrongly, so arp offload
disable cmd isn't sent to F/W. when next suspend comes, arp offload
enable cmd isn't sent too.

Change-Id: I06ea617df49287ee87e7b5bf8b20971b581dedf1
CRs-Fixed: 3106172
2022-01-13 19:13:12 -08:00
Aditya Kodukula
cefd0f71e9 qcacld-3.0: Remove ADDBA_REQ to avoid overwriting spec_mgmt
As per the current implementation, the ADDBA_REQ bitmap setting
overwrites DROP_SPEC_MGMT_ACTION_FRAME_BITMAP. Hence, to avoid it,
remove the ADDBA_REQ bitmap setting.

Change-Id: I1135a64de99248b67e477d3276b217c128c1a721
CRs-Fixed: 3081291
2021-11-25 20:04:50 -08:00
Will Huang
eb218a1c61 qcacld-3.0: Add vendor attribute to configure ARP/NS offload
In some scenario, it is required to receive every ARP/NS packet even
it is not to solicit address itself. So add this vendor attribute
configuration to enable/disable ARP/NS offload on fly.

On some platform, if target suspend to WoW mode, APF filter will drop
such ARP/NS packet in the front, so prevent runtime suspend happen
if disable ARP/NS offload. System suspend still allow in consideration
of potential power impact.

It only support on STA/P2P-Client mode device, and this configure is
optional, while default behavior is ARP/NS offload enable. It will
restore to default behavior if interface being closed.

Change-Id: Icd49e230024bc1ce51519cd9fafee9bc9f79f382
CRs-Fixed: 3058494
2021-11-10 23:02:37 -08:00
Alan Chen
d60caf55b0 qcacld-3.0: Delete use cases of INI enable_dynamic_pcie_gen_speed_switch
INI item enable_dynamic_pcie_gen_speed_switch is no longer. Hence,
delete all uses cases of it.

Change-Id: I1082620c4354bda48ebc54aae7e72e5a81c4aa94
CRs-Fixed: 3068122
2021-11-03 21:11:10 -07:00
Li Feng
1331092b43 qcacld-3.0: Configure magic pattern in line with ini setting
The ini gEnableWoW was designed to enable or disable both magic
pattern match and pattern byte match, but now host ignore the
magic pattern setting from the ini, always enable the magic
pattern instead.

configure magic pattern in line with ini gEnableWoW setting.

Change-Id: I309aff03de9bdbd36fe391784ba54cbfa0cad67b
CRs-Fixed: 3047199
2021-10-18 09:43:05 -07:00
Aditya Kodukula
25130a97ab qcacld-3.0: Correct the kernel doc of ICMP APIs
Correct the Kernel documentation of ICMP feature APIs.

Change-Id: Iec2fe332c24e11835ebd6546dda40603f6f0173d
CRs-Fixed: 3055077
2021-10-13 17:42:25 -07:00
Aditya Kodukula
37026bc3ff qcacld-3.0: Add Support to offload icmp feature to fw
Add support to offload icmp feature to fw in case of
suspended state to avoid high power consumption.

Change-Id: I3ff19d71eac530c75be57e6b52b975e755ff2a53
CRs-Fixed: 3042452
2021-10-12 00:08:44 -07:00
Alan Chen
0c0edb5670 qcacld-3.0: Always enable WoW for RTPM suspend
gSuspendMode is for system suspend to choose between WoW and pdev
suspend. For RTPM suspend, should always enable WoW.

Change-Id: Ibf95ca79ded73f9c68e14b8dac4ec68d979f9db6
CRs-Fixed: 3047812
2021-09-30 01:00:01 -07:00
Aditya Kodukula
4d93a28a54 qcacld-3.0: Add a new ini item gEnableIcmpOffload
Add new ini item gEnableIcmpOffload to enable/disable
ICMP offload to firmware.

Change-Id: I107aeec4c75ae18fbe37d373e48339a5b76797aa
CRs-Fixed: 3025650
2021-08-31 22:23:37 -07:00
Rajeev Kumar
e59ae1bbe5 qcacld-3.0: Disable SAP/GO D3 WoW features if IPA is enabled
SAP/GO D3 WoW feature is not supported when IPA is enabled and hence
disable SAP/GO D3 WoW features when IPA is enabled.

Change-Id: Ia3da37087a0ca79c81c546f43a0893e46cf08c3c
CRs-Fixed: 3015104
2021-08-27 15:12:30 -07:00
Karthik Kantamneni
dd234699a9 qcacld-3.0: Wait for reg work completion before EP access state transistion
Currently intermediate EP vote access is set without checking
for previous state and reg work handler completion.
In some of the error scenarios when resume is triggered from
suspend path, EP vote access is still enabled and work handler
will be scheduled for register updates.
So make sure reg work is completed before setting intermediate access.

Change-Id: I7a1e55c188b9a9e85309dd44ac03651181499674
CRs-Fixed: 2994039
2021-07-23 18:01:30 -07:00
Alan Chen
62341748f0 qcacld-3.0: Add new ini item enable_dynamic_pcie_gen_speed_switch
Add new ini item enable_dynamic_pcie_gen_speed_switch for enabling
dynamic PCIe gen speed change.

Change-Id: I7dde4e40e56bf894c7edd0805d09425444648e6b
CRs-Fixed: 2977079
2021-07-07 06:41:27 -07:00
Li Feng
3d05280c82 qcacld-3.0: Avoid fw crash in some wow case on third party
Due to the limitation on third party platform, add ini to take
special care of the below wow case to avoid fw crash.
The sap/p2p_go shall kick out all the connected sta/p2p_gc and
then go to suspend if d0wow/d3wow is not supported.
Although there is wakelock try to prevent suspend after tdls link
setup, it won't take effect because auto sleep mechanism is not
supported on some third party platform, so teardown tdls link
by force before suspend.

Change-Id: I14bfe32f04cfc34d4f55a09820e42e65a1d9f925
CRs-Fixed: 2935295
2021-07-02 05:02:36 -07:00
Li Feng
4548644d92 qcacld-3.0: Set moddtim dynamically in the li offload mode
Extend hdd_config_modulated_dtim() to configure moddtim
dynamically in the both non li offload and li offload mode.

Change-Id: I8669ec618d4aa9cd87c4c234972ca500c98119b6
CRs-Fixed: 2970090
2021-07-01 04:24:12 -07:00
Yu Wang
c96692a0f9 qcacld-3.0: allow DCS interference event to wake up host
Set WOW event bitmap for WMI_DCS_INTERFERENCE_EVENTID.

Change-Id: I41d9101789adfdc954e4bade974113c51c7f6141
CRs-Fixed: 2960240
2021-06-29 15:04:53 -07:00
Alan Chen
27aeb4863e qcacld-3.0: Add debug log to print link vote id
Add debug log to print more details about the link vote id when
PCIe link suspend is not allowed.

Change-Id: I5069202436e0da37b8ae22f84e28ac06d35002b5
CRs-Fixed: 2964957
2021-06-24 16:32:02 -07:00
Alan Chen
547911c026 qcacld-3.0: Add debug log for prevent suspend
Add debug log to find more details when PCIe link suspend is not allowed.

Change-Id: I0305f6aaabfcff630e863018a7e768531a9cb890
CRs-Fixed: 2963988
2021-06-18 03:22:16 -07:00
Karthik Kantamneni
239913e04c qcacld-3.0: Set intermediate EP vote access
Set intermediate EP vote access before host
wake up indication smp2p is sent to F.W,
this helps to avoid smp2p override.

Change-Id: I4b998ee5ea6b26921855bfbae434869fb93accf9
CRs-Fixed: 2953883
2021-05-28 18:30:37 -07:00
Yu Ouyang
1a3b66cbdd qcacld-3.0: Add new ini to config suspend mode
Sometimes we need PDEV suspend mode, WMI_PDEV_SUSPEND_CMDID and
WMI_PDEV_RESUME_CMDID. But currently design, only support WoW
suspend or not support two choices. And, there are two confused
ini configuration, gDisableWow and gEnableWoW.

1. Add new ini gSuspendMode to set suspend mode. Default 2.
	0, does not support suspend
	1, legency pdev suspend mode
	2, WoW suspend mode
2. Clean gDisableWow. It is replaced by gSuspendMode=0.
   HDD suspend/resume function get the value by new API
   ucfg_pmo_get_suspend_mode().

Change-Id: Icbeef3df6879ca2054f64e0292e9b9469c4936d4
CRs-fixed: 2940788
2021-05-13 12:32:44 -07:00
Karthik Kantamneni
e7f4cae651 qcacld-3.0: Set ep vote access states during suspend and resume
Set ep vote states during wlan suspend and resume opeartions

Change-Id: I5da5fb69ca99ac1d9ecd82cc61cc106eeba8eb47
CRs-Fixed: 2939902
2021-05-11 05:54:20 -07:00
Yu Tian
99ded622dc qcacld-3.0: Set HIF PM link state on in RTPM suspend failure flow
HIF PM link state is used to indicate bus is alive or not. This
indicates RING HP/TP updating directly or using async method.In
RTPM suspend failure flow, CLD reject RTPM suspent request, but
state is not resumed correctly.

Change-Id: I3b96dc1fb34e2810d721e1fcb4db609a3d1d684d
CRs-Fixed: 2919930
2021-05-06 10:44:05 -07:00
Manikanta Pubbisetty
d60dfebd0b qcacld-3.0: enabled EXT GRP IRQs after power save exit
Currently in the WoW design of Moselle, EXT GRP IRQs are
enabled before sending SMP2P power save exit message is
sent to the FW. Because of this, any pending IRQs in the
GIC will immediately fire and could race with the SMP2P
power save exit logic. Any access to the registers done
before power save exit would result in system errors.
Enable the EXT GRP IRQs after sending power save exit
command will fix the problem.

Change-Id: I16f580279b5aa24861ab5111b9c13db3e38063f4
CRs-Fixed: 2925554
2021-04-20 09:40:52 -07:00
Abdul Muqtadeer Ahmed
de4bda2169 qcacld-3.0: Remove the NULL check for a pointer which will never be NULL
psoc_cfg is pointing to the address of a structure variable,
which will never be NULL.

To address this remove the NULL check.

Change-Id: I12f539ce2feace550c403ffc996fa315994470a7
CRs-Fixed: 2911862
2021-04-20 01:32:06 -07:00
Alan Chen
753f93e6e0 qcacld-3.0: Change PMO_ACTION_BLKACK to PMO_MAC_ACTION_BLKACK
There is a compilation error due to use of PMO_ACTION_BLKACK, which
is not defined. Change PMO_ACTION_BLKACK to PMO_MAC_ACTION_BLKACK to
resolve this issue.

Change-Id: I011c4c323bfa7d104c6a6879aba93085a35fed3d
CRs-Fixed: 2923577
2021-04-15 00:12:10 -07:00
sheenam monga
6e6c139e05 qcacld-3.0: Add support to offload igmp feature to fw
offload igmp feature to fw in case of suspended state
to avoid high power consumption.

Change-Id: I05fbf23dc2836f8f5dc6e2f45b35bf2d30c39790
CRs-Fixed: 2907644
2021-04-05 15:22:23 -07:00
sheenam monga
70f283c5d8 qcacld-3.0: Add ini to enable disable igmp offload
enable/disable the IGMP offload feature to FW.

Change-Id: I57241b193598124cba147e86c2d5199c1d5c53ee
CRs-Fixed: 2904964
2021-04-05 15:22:14 -07:00
Karthik Kantamneni
54860cdcc8 qcacld-3.0: In resume sequence mark runtime resume as success properly
Currently runtime resume is marked as success after kicking
HTC queues, due to this non PM marked WMI commands are not
sent out properly.

Fix this by marking runtime resume as success before kicking
HTC queues, since resume is set as success as part of HTC kick
queues WMI commands will be sent out properly.

Change-Id: I5e3f98cbc5888bdf83f760b055c9b706c18737ef
CRs-Fixed: 2899609
2021-04-05 08:50:39 -07:00
sheenam monga
f8314f95bc qcacld-3.0: Add ini to support different versions of IGMP
Add bit mask ini support to decide IGMP version

Change-Id: I2676f9adb83c421c28a1d19efb8fe13a64f34de9
CRs-Fixed: 2907553
2021-03-31 17:11:55 -07:00
Yeshwanth Sriram Guntuka
43a40f83b0 qcacld-3.0: Set system suspend/resume state in hif ctx
Set system state in hif ctx to suspend or resume on
system suspend and resume respectively.

Change-Id: If1904a4fe5c861deed1b35071be10cb8cc8d6407
CRs-Fixed: 2899520
2021-03-31 01:03:47 -07:00
Aditya Kodukula
7beff561cc qcacld-3.0: Remove INI parameter gDataInactivityTimeout
As part of WiFi ini clean-up FR, the ini parameter
gDataInactivityTimeout, is identified as it is no longer used
and hence it can be deprecated.

Change-Id: Ic01ba8934058cf2fb3bec042f11b01ea70ef7a3f
CRs-Fixed: 2896042
2021-03-28 23:36:47 -07:00
Jingxiang Ge
333dc4602d qcacld-3.0: Add detection for tasklet delay
This is to enable feature for detection CE tasklet
scheduling delay and credit response delay issue.

Change-Id: I659aa23eabaa28bfb11051bf15e0343c94061b86
CRs-Fixed: 2874867
2021-03-16 00:45:13 -07:00
Manikanta Pubbisetty
46dc98965e qcacld-3.0: disable EXT grp irqs and drain TXRX during suspend
Any update to the SRNG TP/HP when the device is in low power
state would result in system errors. While in D3 WoW mode,
disable EXT grp irqs and drain TXRX before sending enter
power save mode to the FW. This will ensure that no interrupts
are received while in WoW mode and as a result there wont be any
HP/TP updates.

Change-Id: Ic1fb7fdd45096b458abf5d243fa652c3da878dc0
CRs-Fixed: 2890568
2021-03-14 08:42:48 +05:30
Alan Chen
eafa002519 qcacld-3.0: Add bitmap for BLOCKACK and ADDBA_REQ
Add bitmap for BLOCKACK and ADDBA_REQ.

Change-Id: I5a6bd762bc55bc82934cf260014f55c464340c4f
CRs-Fixed: 2898545
2021-03-13 00:49:53 -08:00
Abdul Muqtadeer Ahmed
e751855624 qcacld-3.0: Add a new feature to support forced dtim
Add vendor command interface/feature through which the user
or vendor can set the dtim count as per their requirement.

Change-Id: I26010948c4ed7e3c49bfe0453119235d4f438c6f
CRs-Fixed: 2894349
2021-03-11 11:58:42 -08:00
Jingxiang Ge
f375f66fe5 qcacld-3.0: Always kick htc queue if suspend failure
Possible wmi cmd is queued in suspend, if no more
htc_try_send comes from credit response or new wmi
cmd, wmi cmd will pending.

Fix is always kick htc queue if suspend failure.

Change-Id: I05e0cd6983e1d27de5bf109c3ddf05e4bdc12fd8
CRs-Fixed: 2895808
2021-03-10 07:23:12 -08:00
Dundi Raviteja
e420cbf610 qcacld-3.0: Reduce stack frame size in pmo_core_cache_ns_in_vdev_priv
Reduce stack frame size of pmo_core_cache_ns_in_vdev_priv()
by allocating dynamic memory to struct pmo_ns_offload_params.

Change-Id: I23a2bbcbc2b64c40513511479b1c8aeb9e7898d6
CRs-Fixed: 2868424
2021-02-06 22:18:41 -08:00
Pragaspathi Thilagaraj
b870f29782 qcacld-3.0: Allow TWT events to wake up wlan host
Currently when TWT commands are sent to firmware, the host driver
doesn't acquire wake lock. So the wlan can got to wow mode before
receiving the TWT command response and the response will get
dropped since host is in wow mode.

To avoid this make the TWT events as wakeable so firmware can
wake up host if host is suspended.

Change-Id: I2750049f9173de564e24114731d3fdd8ec8d6d86
CRs-Fixed: 2869865
2021-02-05 12:05:49 -08:00
Dundi Raviteja
21b49b36be qcacld-3.0: Reduce stack frame size while registering action frame
Reduce stack frame size of pmo_register_action_frame_patterns()
by allocating dynamic memory to struct pmo_action_wakeup_set_params.

Change-Id: I4beed12c18c4e213c76e35c7762e59fc7d2ab957
CRs-Fixed: 2865021
2021-02-01 07:52:31 -08:00