WCN7850 has support for near full indication for
the consumer srngs. This interrupt is used to take
preventive actions to avoid ring full watchdog irq
trigger.
Register for the near full irq and add the necessary
ext groups for these near-full irqs.
Change-Id: Ic16381fceabc54e6c52b34dd13abea74cad4d38c
CRs-Fixed: 2965081
Introduce intermediate EP voting state during this transition state
access the votes only if direct writes are not possible.
Change-Id: Ib4522aef2209b4797100ca84e4e230a00e14b654
CRs-Fixed: 2954903
As per current design, in failure path of hdd_wlan_start_modules,
mem_free of hif_ext_group is done (in cds_dp_close) before
free_irq (in hdd_hif_close), during next hdd_wlan_start_modules,
request_irq adds new handler entry to the list in irq_desc, this
leads to a crash on accessing older stale entry from irq handler,
so adding a bus_ops hif_grp_irq_deconfigure to free ext grp IRQs.
Change-Id: I4d0a2bee1fabee388cea8a85226fae641165a8d5
CRs-Fixed: 2949400
Runtime PM for HTC layer has multiple cases of GET/PUT operations.
Adding runtime PM stats for HTC layer, this helps in debugging
RTPM GET/PUT out of sync issues.
Change-Id: Ib27efd73dce0bb5bd3ff030bd7ae1bc833f29610
CRs-Fixed: 2923250
DHCP packet is received in the IPA exception path when
system is suspending. As part of DHCP packet processing,
WMI_PEER_SET_PARAM_CMDID is sent to FW after WOW is
enabled resulting in self recovery getting triggered by
host.
Fix is to do an explicit system wakeup if a WMI command
has to be sent post WOW enablement.
Change-Id: If1904a4fe5c861deed1b35071be10cb8cc8d6407
CRs-Fixed: 2890913
This feature is used to detect CE tasklet scheduling delay
and credit response delay issues.
Change-Id: I9a8fcb425edd5cf96fae5f6cd3bfc7f51172c814
CRs-Fixed: 2874874
Any update to the SRNG TP/HP when the device is in low power
state would result in system errors. It is recommended to disable
EXT grp irqs and drain TXRX before sending power save enter command
to the FW. This will ensure that no interrupts are received while
in power save mode and as a result there wont be any HP/TP updates.
Change-Id: Ibf952bbc2c6d13fb3e4ca6b4845bc9cc887fa694
CRs-Fixed: 2883135
In Moselle, currently CE interrupts are not disabled from apps
side during ipci bus suspend, so adding changes to disable all
the CE interrupts except wake_irq during bus suspend and do the
symmetric inverse operation during bus resume, also drain all
the pending FW diag logs from copy engine.
Change-Id: Ib54fc6660fd81aff18787b0b699f3a6cd2d7803d
CRs-Fixed: 2879752
Issue1: Driver RTPM state is ON/NONE, Kernel state is RESUMING.
cdp_runtime_resume is already complete,
hif_pm_runtime_get return -E_INPROGRESS,
dp_tx_hw_enqueue will set the flush event,
but cdp_runtime_resume is already done,
this flush event will be handled only on next pkt tx.
Issue2: Driver RTPM state: Resuming
hif_pm_runtime_get returns -EBUSY,
dp_tx_hw_enqueue is interrupted by any IRQ,
cdp_runtime_resume is completed,
dp_tx_hw_enqueue will set the flush event,
This flush event will be handled only on next pkt tx.
Fix:
Introduce a link_state_up atomic variable in hif to track the link state
change by pld_cb.
Set atomic variable link_state_up=1 in pmo_core_psoc_bus_runtime_resume
just after pld_cb. pld_cb brings the PCIe bus out of suspend state.
Set atomic variable link_state_up=0 in pmo_core_psoc_bus_runtime_suspend
just before pld_cb. pld_cb puts the PCIe bus into suspend state.
Introduce dp_runtime_get and dp_runtime_put.
dp_runtime_get get refcount with increment of an atomic variable.
dp_runtime_put return refcount with decrement of this atomic variable.
If hif_pm_runtime_get returns -EBUSY or -EINPROGRESS,
take the dp runtime refcount using dp_runtime_get,
check if the link state is up, write TX ring HP,
return the dp runtime refcount using dp_runtime_put.
cdp_runtime_suspend should reject the suspend, if dp_runtime_get is non
zero.
cdp_runtime_resume should wait until dp_runtime_get becomes zero or time
out, then flush pending tx for runtime suspend.
Change-Id: I5b97d50cba710082f117f3845f7830712b86cda7
CRs-Fixed: 2844888
Currently if the driver is in runtime suspend/suspending
state, any packet transmission will request for resume
via hif_pm_runtime_get.
Unfortunately there is a logging in the above API which
will lead to more time consumption in the NET_TX softirq
context. This can lead to other delay in processing other
softirqs in the system.
Fix this by skipping the logging in the packet transmission
path.
Change-Id: Icc9f5b67794f7666243eb059f2e07a06a987002e
CRs-Fixed: 2844126
Add wake_irq_type in HIF layer for power management,
this helps in deciding to enable sync-up between
runtime suspend and wow resume in case of moselle.
Change-Id: I23a4d02d3ae7ec543a28174461996b84b18fd95d
CRs-Fixed: 2851265
In moselle, once wow enabled there is a possibility that wow wake
interrupt can be fired from FW during runtime suspend in-progress
in host, this will introduce a race between runtime suspend and
resume, so adding a synchronization between runtime suspend and
wow triggered runtime resume.
Change-Id: I38d6a24e4421697cc2d0090ba8d19884885596cb
CRs-Fixed: 2845672
Currently DMA mask for the device is set during hif_enable_bus.
If the datapath memory prealloc feature is enabled, there are
a few dma memory allocation which is done before the DMA mask
is set for the device. This leads to the aforementioned dma
memory pre-allocation to be attempted at the default DMA mask.
Due to this the entire device capability of dma address might
not be used.
Add hif api to set dma mask before hif is initialized. This
is needed to set dma mask in case of datapath memory pre allocation.
Change-Id: I6fd25d9cb6ab3aaacd6f959abe4e060e23f37095
CRs-Fixed: 2845020
In IRQ storm scenario, the events are logged to hif
event desc history even though the SRNG is empty
resulting in overwriting of older entries useful for
debugging.
Fix is to avoid recording hif events if the SRNG is
empty in IRQ storm scenario.
Change-Id: Id4161198c60f5fae31123c936f0f4acc1082a78b
CRs-Fixed: 2753675
hif_pm_runtime_prevent_suspend_timeout is no longer supported
and hence delete this obsolete API.
Change-Id: I2c01105219adb198bbf27aee5f2d5c7e357c1e34
CRs-Fixed: 2761022
Before accessing any register on chip 6750, check if target is
ready or not.
Do not allow register access if target is not ready.
Change-Id: I41a604d04e861c97bdd676998222ccecbf12fd5a
CRs-Fixed: 2688920
A few functions in HIF component returns QDF status value with return
type as non QDF STATUS and vice versa. For such functions, update the
correct return type.
Change-Id: I806407dd0596cd03500242d97ca8220a7beb6c55
CRs-Fixed: 2734818
A few functions in HIF component returns QDF status value with return
type as non QDF STATUS and vice versa. For such functions, update the
correct return type.
Change-Id: Ifc1068d60e62f7405a15e2b4f0738d91243bd6de
CRs-Fixed: 2734818
A few functions in HIF component returns QDF status value with return
type as non QDF STATUS. For such functions, update the return type as
QDF_STATUS.
Change-Id: I69644a2206266ffe2c2d105056f9fec452f5d972
CRs-Fixed: 2734818
Fix WOW wake up interrupt from WLAN FW, in system
suspend/resume for Moselle platform.
Change-Id: I5f71c65e0aa1eeef8225f3fcfae5410233df8b78
CRs-Fixed: 2724142
Move the srng history to hif context.
Process the monitor ring only for the lmac
corresponding to the configured monitor channel.
Add the timer and srng history for monitor mode.
Change-Id: I4e5e49ad5e657b55bfafbb40ef5f59496277cb40
CRs-Fixed: 2690530
In ipq5018 CE registers(0x08400000) kept outside WCSS(0x0C000000) block.
As both regions are more than 60MB apart, not feasible to allocate
single resource which include both.
So, using a separate I/O region to access CE registers.
Change-Id: I67bb6d5ac82a1c0ed1d3e13f7776f9d69ee19956
Update QCA_NAPI_DEF_SCALE_BIN_SHIFT for defconfig builds to
the same value as the perf build.
Move the WLAN ext irqs to gold cores for defconfig builds.
Disable cpu isolation before moving the IRQs to gold cores.
Add the ability to move IRQs to gold cores when the cpus
hotplug in.
Change-Id: I4cfecd02a1a2200dc99adee9a324b90c877c13fd
CRs-Fixed: 2638820
This is to enhance statics for runtime put/get, which is
to detect if there is mismatch for usage_count.
Change-Id: I24cddb9d10e4cb675c8375cbd0f589c7718bd680
CRs-Fixed: 2647972
Macro DMA_COHERENT_MASK_IPA_VER_3_AND_ABOVE is used in non
IPA offload case also so bring this macro definition out of
IPA offload feature and change it to DMA_COHERENT_MASK_DEFAULT.
Change-Id: Ib03aa8ae2938e1de1a957660923a711d452a9337
CRs-Fixed: 2649909
Initial changes for ipq5018 compilation.
Added device ID and target type checks for ipq5018 traget.
Change-Id: Ib86a371fbe66749fcb6d114e7a4a9931b684e03d
Add HIF APIs to prevent or allow link to go into low power states. The
current implementation uses PLD APIs to make the needed configuration.
Change-Id: I22efb4bcf902f9aff674ed1872f4f23bef508aae
CRs-Fixed: 2602029
This is a public API, so move it outside to hif.h file so it can be
used elsewhere as well.
Change-Id: Ic870cf804df69f6d7bb5a792da662759d687e0ed
CRs-Fixed: 2616491
Some areas in other components are directly calling the kernel api
functions to perform runtime PM no idle operations. Create a new HIF
function to handle runtime PM no idle operations.
Change-Id: I8328bc74ccc8e8acd35d7d73ec4cc21094b8f5b2
CRs-Fixed: 2607721
Enable timer and batch count threshold interrupt for CE1, CE2
and CE5 rings through INI and retrieve the parameters through
psoc handle.
Change-Id: Ifa6cd768ed41ded46cae652ad7c910ffa62f2310
CRs-Fixed: 2593531
Change enable_runtime_pm from bool to uint8_t in correspondence to
changing CFG_INI_BOOL to CFG_INI_UINT for enabling runtime PM.
Change-Id: Ib5031ada43fac864d933cdfee875593f896b2a62
CRs-Fixed: 2603918