In case of rmmod if stop bss fails SAP IPA interface is not
deleted. So again at next driver load IPA will be holding the
stale IPA header and new IPA header will not be added at IPA
interface creation. In this change clean IPA interface when SAP
stop bss fails.
Change-Id: I3a1bf891752308ba1a29d6768f24880d8514d5bf
CRs-Fixed: 2224307
Before wow enable or pdev suspend host sets hardware filter bitmap
and enables the filter via a command. But after resuming it sends
bitmap as zero with filter disable. This is interpreted by Firmware
as disable the modes set in the bitmap, so none of the modes are
disabled. With this host will not receive bc/mc packets after
disabling the hw filter, which it is expecting.
Send the same bitmap after resume that was used before suspend.
Change-Id: Ic7425274c9197e907404c3ca9ba0d5269ee51690
CRs-Fixed: 2194964
Some times HTT response for suspend IPA pipes from FW host arrives
after vdev has been cleaned up at FW. After receiving FW HTT IPA
pipe suspend response HOST processes pending events. For event AP
DISCONNECT HOST sends IPA offload disable command to FW with vdev
id that has been deleted at FW. As a result FW asserts.
In this change before processing IPA WLAN pending events validate the
session. If session exists then only process the events.
Change-Id: I464a91c3a85e6002297d9ade2fbd45b45a2a4d51
CRs-Fixed: 2261111
In implementation of Android Packet Filter, functions, variables,
definitions are named after BPF, which stands for Berkely Packet
Filter. The term was more appropriate for Link Layer packet
filters implemented in the Linux kernel, known as Linux Socket
Filters.
The term BPF is obsolete now, so rename it with the
appropriate acronym, APF.
Change-Id: I9e02edbc580ffb2c559c8e864f54d255fc2d51a3
CRs-Fixed: 2191530
PMO should not know about vdev data path handle, but
pmo_unpause_all_vdev() need it, so register a wma callback to retrieve
the vdev dp handle instead of keep a copy in pmo vdev private context.
Refine current code to retrieve vdev dp handle using a wma callback
Change-Id: I1f668fff633a5e5cdfc478e7f619e9600930b333
CRs-Fixed: 2227384
There are several logs in PMO that log debugging related information
at the INFO level. Reduce the logging level of these debug logs to
avoid spamming the console.
Change-Id: Ib1bb9279d5d8104104b58bd2c83869f72c0bde4a
CRs-Fixed: 2260190
Add support for getting cfg integer from PMO. Register callbacks
during pe_open/close so that PMO can query CFG int values for
calculating parameters like listen interval etc.
Change-Id: I52d165586576e547e175ba276e6b7225db5b27e0
CRs-Fixed: 2252661
With IPA WDI unified API, IPA PM is used instad of IPA RM
for power/resource management. When checking if IPA clk
scaling is enabled or not, HDD_IPA_RM_ENABLE_MASK is thus
not applicable for WDI unified API.
Change-Id: Ie18c2ba6168a06a3bf03f6a5754ffef98113ce30
CRs-Fixed: 2256015
With IPA WDI unified API, IPA PM is initialized after WLAN IPA pipes
are connected. Initializing IPA perf profile will fail if IPA pipes
are not yet connected.
Fix is to
1. Initialize perf perofile only after IPA pipes are connected
successfully.
2. If clk scaling is disabled, initialize perf level to maximum.
3. Allow driver to proceed if perf profile initialization fails.
Change-Id: I3a63e0f1decec10440467da62cb6ccf740eda318
CRs-Fixed: 2258682
Currently while sending wmi command when target is suspend, it will
check whether command is WMI_WOW_HOSTWAKEUP_FROM_SLEEP_CMDID/
WMI_PDEV_RESUME_CMDID, but D0WOW command is an exception, to keep align
with legacy code so don't set wmi_handle->is_target_suspended if it is
D0WOW enable command.
Move out logic of checking D0WOW status from PMO tgt to core layer.
Change-Id: I164f24ea733e54e5e0dbdb77344917df5d039e53
CRs-Fixed: 2254047
There are several logs along the suspend/resume code paths that log
debugging related information at the INFO level. Reduce the logging
level of these debug logs to avoid spamming the console.
Change-Id: I0e81901e4a053038392c1012600ae125a1ad27a3
CRs-Fixed: 2258093
Total 16 number of WoW filters are PoRed for Genoa.
Define CONFIG_PMO_WOW_FILTERS in genoa defconfigs with value 16.
Change-Id: Iba3d9875c954b32a3f22cfd639f4508beb36a5d5
CRs-Fixed: 2257033
Current ucfg API's that disables wow events accept a u32 bitmap
variable. A pointer to that variable is passed to core API where
it assumes it as a u32 array of 4 bytes. This will lead to out of
bound memory access.
Change wow enable/disable API's to accept wow event type as the
parameter.
Change-Id: I220aaddfea62ab96f121014d0d65a1406988c946
CRs-Fixed: 2233108
In the case of invalid iface_ctx, the stats reset operation is not
needed, so removed it.
Change-Id: I48b4b42717451e1ccbfc9753147e65d35ff78df4
CRs-fixed: 2254683
When running embedded tput between client and SAP, there'll be
excessive logs per packet. Fix is to remove the per packet
debug message.
Change-Id: I846f4fd5e54cc8945b3159c56e04418feea0183f
CRs-Fixed: 2253186
Fix a few things in one shot.
- clean up some code to avoid potential NULL pointer dereference.
- add a helper function - wlan_ipa_free_tx_desc_list() to
avoid duplication.
- rearrage wlan_ipa_teardown_sys_pipe() to allow others' reference
Change-Id: I9d6391a7f20ae427bf59f07958bd13f349e61d83
CRs-Fixed: 2233867
In function wlan_ipa_uc_loaded_handler,the qdf_dev is as return of
wlan_psoc_get_qdf_dev(),which maybe NULL,then NULL reference could
occur later.
Change-Id: I3c6d5af35934deef643cb600b1966c22769c71ed
CRs-Fixed: 2250977
When ipa_check_hw_present() returns false, g_ipa_config
is left as NULL pointer. ipa_config_is_enabled() and
ipa_config_is_uc_enabled() will lead to NULL pointer
dereference.
Fix is to check against g_ipa_config NULL pointer
in ipa_config_is_enabled() and ipa_config_is_uc_enabled().
Change-Id: I95da7aede7d72db8591102eea7504cad59686105
CRs-Fixed: 2246224
There are two types of WLAN IPA exceptions, where WLAN driver is
involved for packet processing.
One is for RX exceptions, such as ICMP or Intra-BSS packets.
The other one is for WDI 1.0 MCC TX SW path, where packet queueing
is happening in WLAN driver.
In both cases, skb is allocated in IPA driver. If NBUF_MEMORY_DEBUG
is defined and qdf_net_buf_debug_acquire_skb() is not invoked for
the skb, qdf_nbuf_free() will trigger ASSERT to report unallocated
buffer.
For early processing of RX exceptions, dev_kfree_skb_any() needs to
be called instead of qdf_nbuf_free() otherwise above ASSERT will be
triggered.
For MCC TX SW path, ipa_free_skb() should be called to free skb to
IPA driver.
Change-Id: I039cb20673ce3aa98056529f7609801f76c4c16a
CRs-Fixed: 2247339
qdf_wait_for_event_completion() needs a timeout value in milliseconds.
msecs_to_jiffies() is not needed to convert timeout value into jiffies.
Change-Id: I95315f937d651fd200f58d89f44eb167c6f29cc8
CRs-Fixed: 2250143
IPA driver adds unified WDI API for ipa_wdi_create_smmu_mapping
and ipa_wdi_release_smmu_mapping. WLAN driver needs to adopt the
change accordingly.
Change-Id: I997aae3651831d0ecf576369fdb428c0f59be77b
CRs-Fixed: 2230075
Previously change "qcacld-3.0: Use enum QDF_OPMODE", Change-Id
Ic6f663dac11a100f168b2626c7c0fbcaccbfca4f, replaced all instances of
tQDF_ADAPTER_MODE to QDF_OPMODE in the qcacld-3.0 project. However
since tQDF_ADAPTER_MODE was originally defined in a common project,
and not all references to it could be immediately removed, a legacy
definition was left with the expectation that it would be removed when
all references to it had been updated. Unfortunately new instances of
using tQDF_ADAPTER_MODE have been subsequently added to the project,
so replace them with QDF_OPMODE.
Change-Id: I71cead84151cc0411f7cc5cc13a87a281e7502c0
CRs-Fixed: 2245247
DISA head files include lots of not used public head files, and cause
compilation issue when disable PMO feature flag.
Change-Id: I287f845a3e9f923d042463c34abaedadb905d3b2
CRs-Fixed: 2243947
Currently in functions to show IPA resource info and IPA stats
there are information related to IPA resources memory address.
This may be lead to potential information leak to the location
of IPA resources. Remove the addresses information from the
logs in res info and stats function.
Change-Id: I75d756211c8aaaea300fb207e40a08f5b1ca81e3
CRs-Fixed: 2225361
IPA RM is not used when WDI_UNIFIED_API is defined.
Remove to use wake_lock and rm_lock, which are created from RM setup.
Change-Id: I6c614fde7d6d7f0ab94aa9933578f3dca814a40e
CRs-Fixed: 2231424
Use QDF_IPA_WLAN_EVENT_MAX instead of IPA_WLAN_EVENT_MAX to record
WLAN event to IPA.
Also record QDF_SWITCH_TO_MCC/SCC and QDF_WDI_ENABLE/DISABLE event.
Change-Id: Iada6c39d2b952f6b9a1690a86c5871d2ca588cd2
CRs-Fixed: 2240425
IPA component needs to discard repetitive start_bss event in
case SAP is on DFS channel. Issue is we checked against
available SAP interface and this will lead to second SAP
interface setup failure.
Fix is to check against same SAP interface to see if it has
already been setup.
Change-Id: I2fc3656f5e1fba39dba14dba137c6202c5ec5af0
CRs-Fixed: 2240368
Use get_wmi_unified_hdl_from_psoc instead of GET_WMI_HDL_FROM_PSOC due
to incompatible return types.
Solve renaming dependencies with common side changes.
Change-Id: Ie84641327d64876877c7d26b63d632c79770a88c
CRs-Fixed: 2203055
The Change-Id: I69c813047ab4b1b129e4fb057d8aacbef5cc9efea
is missed as part of UMAC IPA componentization changes.
Propagate the missed change to IPA component.
Change-Id: I2c346a266c2c767dd37b5901d8d671e475449a01
CRs-Fixed: 2233325
Add fallthrough comment in pmo_register_wow_wakeup_events
as per linux checkpatch script. Fallthrough required to set
interface type and to set sta wow bitmask.
Change-Id: I6931371e9a2d4421354c19c12e552c75e50cb798
CRs-Fixed: 2233187
wma_is_service_enabled can't get valid service bitmap if call in
hdd_update_pmo_config, use psoc_ctx->caps.unified_wow instead to check
pattern id per vdev and legacy d0 wow capability.
Change-Id: If7bf316f482c49253fc4b95b94e172727b27ffd1
CRs-Fixed: 2225847
The following PMO functions have been identified as having off-by-one
logic errors. Address these errors.
* pmo_register_resume_handler
* pmo_register_suspend_handler
* pmo_unregister_resume_handler
* pmo_suspend_all_components
Change-Id: I6a328fc24ae6a575ef56cf9532133eb666e0dc8c
CRs-Fixed: 2232388
Add Unified WDI API support for ol_txrx_ipa_set_perf_level and fix
client parameter for ipa_wdi_set_perf_profile.
Change-Id: Ieaaf7cf5231f74cd6ba358c02032ae173d9618f0
CRs-Fixed: 2211504
There's an excessive log for IPA if IPA is disabled on ini but enabled
in FW. Change the log level to debug from info.
Change-Id: I60a49132bc00b06fc0725c7a3f648fa773321f56
CRs-Fixed: 2232196
Add feature flag for PMO component such that for high latency
and IoT devices power management and offload component can be
compiled out.
Change-Id: Iaccda7d9e895cdb4610f0ec984add3aeb7ef9926
CRs-Fixed: 2227330
Add feature flag for PMO component such that for high latency
and IoT devices power management and offload component can be
compiled out.
Change-Id: I2c88b6af33e8f10f1837263f157c1f6892a2c2fb
CRs-Fixed: 2227326
There's an excessive log for IPA uC stat request reason even when
WDI pipe is suspended.
Enable IPA uC stat request reason log only when IPA pipe is resumed.
Change-Id: I35d98e02a9180738bc9cdb25f59e31d572df9e0e
CRs-Fixed: 2181952
Extend support to get IPA HW status on all platforms if IPA OFFLOAD
feature is enabled.
Change-Id: Ideea6b7f058b3d80efecc9473a20d7a31046b4bc
CRs-Fixed: 2230316
When AP_DISCONNECT event occurs during IPA resource unloading in
progress, timeout could happen since suspending FW IPA Rx pipe took much
time. This could cause a subsequent AP_CONNECT event failed since no
interface is available.
Fix this by
- Adapter struct sanity check using hdd_validate_adapter()
- Call hdd_ipa_cleanup_iface() for AP_DISCONNECT/STA_DISCONNECT event
in loading/unloading timeout case
- Assert when no interface is available in hdd_ipa_setup_iface()
Change-Id: Ie96e4f0e96ccffacf4ce5fcc976636c440214873
CRs-Fixed: 2208347
wdi2.0 feature adds extra 2 bytes to frag_header and thus hdr_len
to IPA HW also adds 2 bytes. This change breaks pre-wdi2.0 platform
with WiFi FW discarding all TX traffic since packet payload is
with an extra 2-byte offset.
Fix is to add frag_header structure with pre-wdi2.0 pattern.
Change-Id: I467a05bab4111a305ae23250c61cecc050821611
CRs-Fixed: 2047714
IPA RM APIs are depricated from WDI UNIFIED APIs.
Remove to call IPA RM APIs when IPA_WDI_UNIFIED_API is enabled.
Change-Id: I4de2f16a9d320a769870efacdd0c067bab133a0a
CRs-Fixed: 2220247
Issue is under AP-AP MCC config, mcc event is not sent from wlan
to IPA driver. mcc mode is decided with the help of connection
table. But for AP mode, mcc mode is checked and updated before
connection table is updated by adding the SAP vdev entry.
Fix is to make ipa mcc mode check and notification when connection
table is updated. Since block is not allowed when conn table is
updated, a new work_struct mcc_work is introduced.
Change-Id: I935222e26bb3f6b31685f52b75084b034daccad2
CRs-Fixed: 2075876
Fix LLVM compilation error: implicit conversion from enumeration type
'qdf_ipa_wlan_event' to different enumeration type
'qdf_ipa_wlan_event_t'
Change-Id: Ie5f09f3e5b6f1e93d344d22483754292d370ce60
CRs-Fixed: 2216820
Historically, recovery was triggered if PDEV suspend failed, but the
logic was lost during componentization. Restore the previous logic of
triggering recovery on PDEV suspend timeout.
Change-Id: I6e193e98c5ef45fd7ab4b6595ea85d986fa84131
CRs-Fixed: 2215588
Check if IPA is enabled in ini configuration before doing
IPA operations from northbound interface calls.
Change-Id: Ic075562c1afe52d26ebefaff058fde7c90d4f7d1
CRs-Fixed: 2215269