Grafik Komit

757 Melakukan

Penulis SHA1 Pesan Tanggal
Michael Adisumarta
f848576a1c msm: ipa: remove initing head again if dma mapping fails
Remove Initializing rx_pkt link if dma mapping fails.

Change-Id: I49d08555c875fc9039805ef8775be3b676f51d08
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-08-30 11:16:34 -07:00
qctecmdr
f82564b226 Merge "msm: ipa: fix max number of pipes check" 2021-08-27 19:30:30 -07:00
Michael Adisumarta
78e9ad583c msm: ipa: Fix init and add overflow check for drop stats
Fix init_drop_stats to have it only enable 4 pipes max.
Enable different pipes depending on kernel version.
Use more descriptive names for WLAN2_CONS pipes drop stats.
Add a temp variable to not enable drop stats bitmask when # of
pipes is more than allocated.

Change-Id: I3d678569eb94bfd43d90d2d4f84f5b1148b8ec42
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-08-26 21:25:13 -07:00
qctecmdr
a0ca972920 Merge "ipa: Null persistent pointers after free" 2021-08-26 10:55:37 -07:00
qctecmdr
d2a3698807 Merge "msm: ipa3: upgrade reg save to IPAv5" 2021-08-26 01:30:37 -07:00
Michael Adisumarta
947630a1ca msm: ipa: fix max number of pipes check
Fix max number of pipes check for getting ep index
for adding filtering rules.

Change-Id: Ifcb92c3f5dacbe1fbafe615ec36e5dd74fd10540
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-08-20 15:04:20 -07:00
Michael Adisumarta
c6e2859a34 msm: ipa: debugfs: Update keep_awake to use PM APIs
Update the keep_awake script to call into IPA PM and
add/remove dummy clients to change the clk vote dynamically
based on the loaded device's power thresholds.

Change-Id: Ifaa4ef1e312428245605008998ac59afddf09d99
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-08-18 17:15:26 -07:00
qctecmdr
bf2a8f464b Merge "msm: ipa: add null check for unregister netdev" 2021-08-18 16:00:02 -07:00
Michael Adisumarta
669d4f210f msm: ipa: Fix use-after-free in ipa3_alloc_counter_id
Make changes to memcopy before preload end.

Change-Id: 	Icc056a3bcd5b739b8165813202c87dd84e72c78a
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-08-13 13:09:42 -07:00
Michael Adisumarta
455afc1857 msm: ipa: correct the pointer in idr for FnR stats counter
The stats counter which saved in idr was some stack memory which
could be freed and cause memory corruption. The fix is to use
the memory allocated in heap instead.

Change-Id: Ie398b0271571fcff41cdb85de4d77d202b6552b5
Signed-off-by: Bojun Pan <bojunp@codeaurora.org>
Signed-off-by: Michael Adisumarta <madisuma@quicinc.com>
2021-08-13 00:38:26 -07:00
Piyush Dhyani
3f8db17505 msm: ipa: Fix string out of bound issue.
Currently during RMNET_IOCTL_GET_MTU and RMNET_IOCTL_SET_MTU ioctls
we can recieve not null terminated string for if_name which was
resulting in string out of bound error while accessing the if_name.
Now adding null character at the end of string to prevent access
beyond its size.

Change-Id: I4d82a4b491f04a85d6ab4f0211671520156f7c61
Signed-off-by: Piyush Dhyani <pdhyani@codeaurora.org>
2021-08-11 20:41:21 -07:00
Ilia Lin
15ae40cd76 ipa-kernel-tests: ULSO tests, HPC based header insertion tests
Unit tests for the IPv5 ULSO feature and for HPC based
header insertion feature.

Change-Id: I312b135f33486c1171a355a69e6631764d021947
Acked-by: Eliad Ben Yishay <ebenyish@qti.qualcomm.com>
Signed-off-by: Ilia Lin <ilialin@codeaurora.org>
2021-08-11 14:51:51 +03:00
Ilia Lin
bedfbae7e6 ip_accelerator: Adding network_traffic
Network traffic generation and handling.

Change-Id: Ia1de9cf235d732f721f93d12cb11a69739683a72
Acked-by: Eliad Ben Yishay <ebenyish@qti.qualcomm.com>
Signed-off-by: Ilia Lin <ilialin@codeaurora.org>
2021-08-11 04:20:13 -07:00
qctecmdr
087fa1d80e Merge "msm: ipa3: Enabling the HOLB on USB consumer pipe for APQ target" 2021-08-10 18:31:11 -07:00
Michael Adisumarta
e8006a750d msm: ipa: add null check for unregister netdev
Changes include null check for IPA netdev and gsihal_ctx.

Change-Id: If897281663e0ae0f29b7110fcbaa4dd98f67eb8d
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-08-10 11:52:11 -07:00
Ashok Vuyyuru
6d4fa6b6e8 msm: ipa3: Enabling the HOLB on USB consumer pipe for APQ target
Enabling the HOLB on USB consumer pipe to avoid IPA HW stall
if USB host slow in pulling the data.

Change-Id: Ifc4b13ce52e241a3b1942bd81745f1ef3b2903e7
Signed-off-by: Ashok Vuyyuru <avuyyuru@codeaurora.org>
2021-08-11 00:14:43 +05:30
qctecmdr
335b3560aa Merge "msm: ipa: fix KW errors on LA.VENDOR.1.0" 2021-08-08 22:27:18 -07:00
qctecmdr
a3f07f8468 Merge "msm: ipa: distingusih between userspace and kernel rt rule addition" 2021-08-08 21:45:10 -07:00
Skylar Chang
be8e39c3eb msm: ipa3: add support for DPM port query in pcie mode
Add support for dpm ep-ip/IPA pipe info for user-space
module to query.

Change-Id: I06ecea1ecfc953315a2cc826e81517b3a97b0d7b
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
2021-08-05 11:06:26 -07:00
Ilia Lin
d91efadf01 ipa: Null persistent pointers after free
Assign NULL to pointers that may be used later
after calling kfree on them.

Change-Id: I3298eb484c92ee2373f0bc41aae8ae45fb373cf0
Signed-off-by: Ilia Lin <ilialin@codeaurora.org>
2021-08-05 13:27:53 +03:00
qctecmdr
0ff1f757d2 Merge "msm: ipa: ulso wa fixes" 2021-08-04 22:24:36 -07:00
Michael Adisumarta
a2e7a586a7 msm: ipa: fix KW errors on LA.VENDOR.1.0
Fixing recent KW errors.

Change-Id: I8fd8dcab5ed982f5bdb09e0fcfbe93bf74a0dcef
Signed-ogg-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-08-04 16:44:07 -07:00
Chaitanya Pratapa
7cfc02d8c0 msm: ipa: ulso wa fixes
ULSO WA cannot be used with full pipeline clear option in same chain.
Avoid using it as it can result in HW stalls.

Also make sure to use ULSO WA whenever we send force close
on coalescing pipe to avoid HW stalls.

Change-Id: Ie81d885f82b201d35cd1832a3a87313c37da76b8
Signed-off-by: Chaitanya Pratapa <cpratapa@codeaurora.org>
2021-08-04 15:04:48 -07:00
Armaan Siddiqui
5e4d4e39a1 msm: ipa: fix potential race condition ioctls
There are potential race condition ioctls in
the IPA driver when it copies the actual
arguments from the user-space memory to the
IPA-driver. The fix is to add check on the
2nd copy to make sure the same payload size
is copied to the pre-allocated kernel memory
as during the 1st copy.

Change-Id: I3d31cb11a24e969db4fd1728cf6ab1ce983a75e9
Signed-off-by: Armaan Siddiqui <asiddiqu@codeaurora.org>
2021-08-04 01:06:58 -07:00
qctecmdr
d1f804e2ac Merge "msm: ipa3: Changes to remove the CNTXT_SCRATCH_1 config" 2021-08-03 17:33:42 -07:00
Ashok Vuyyuru
3d2bf967c0 msm: ipa3: Changes to remove the CNTXT_SCRATCH_1 config
Context scratch 1 register configuration not required, So removing
these changes.

Change-Id: Ic72fc128fc6468e5844d10d9321a85a85c4ed60c
2021-08-03 00:01:19 +05:30
Michael Adisumarta
4eff4ff2e7 msm: ipa: distingusih between userspace and kernel rt rule addition
Add changes to Distinguish between userspace and kernel
route rule addition.

Change-Id: Ieb53ea45e22907d48b47fb20f82e391dc036073f
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-07-29 16:18:19 -07:00
Michael Adisumarta
a32e97b893 msm: ipa: Update qtimer granularity for IPA_hw_type > 5.0
Update qtimer granularity for IPA_hw_type > 5.0 to match
HPG requirement. Use the new granularity for configuring
timer if the lower granularities fail. Remove assert
for debugfs to gracefully handle bad timer value.

Change-Id: I57d4913950afd0dec9adddc65441043263302872
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-07-29 16:06:03 -07:00
Ilia Lin
e927e01f4f msm: ipa3: upgrade reg save to IPAv5
Add support for IPAv5 and GSIv3 reg collection.
Undef obsolete registers and Add support for array
registers.

Change-Id: I15f91a3f4562cc40b4095605d95487a319520029
Signed-off-by: Amir Levy <alevy@codeaurora.org>
Signed-off-by: Ilia Lin <ilialin@codeaurora.org>
2021-07-27 11:53:50 +03:00
Goutam Bose
fd487e6278 msm: ipa: fix use-after-free of rt_tbl
Fix use-after-free of rt_tbl in __ipa_del_flt_rule
by checking if the rt_tbl is already freed.

Change-Id: I09541f65f474dc42f262c603d99f6bbcbb0ce8ec
Signed-off-by: Goutam Bose <gbose@codeaurora.org>
2021-07-26 18:49:04 -07:00
qctecmdr
d523e31764 Merge "msm: ipa: Updating the last index of qmi handler array with NULL" 2021-07-26 14:39:21 -07:00
qctecmdr
5d8fee29fc Merge "ipa: Remove unneeded warning" 2021-07-26 10:05:46 -07:00
Skylar Chang
a89c78b8a7 msm: ipa3: directly give prot_id in stats_dealloc
Directly to give prot_id in ipa3_uc_debug_stats_dealloc
instead of using IpaHwOffloadStatsDeAllocCmdData_t
structure.

Change-Id: I20d717e43dc3c8161e05338a21d053245e5502f7
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
2021-07-23 13:02:20 -07:00
qctecmdr
2179be587b Merge "msm: ipa3: Disable HOLB for ODL pipe during suspend" 2021-07-23 10:17:48 -07:00
qctecmdr
b2c0cdf9b2 Merge "ipa: NTN3 EDMA mode limitation DB fix" 2021-07-22 06:06:34 -07:00
Ashok Vuyyuru
8cea05c6ab msm: ipa3: Disable HOLB for ODL pipe during suspend
1. Disable HOLB for ODL pipe during suspend to avoid dropping the packet
2. Enable HOLB while unsuspend the pipes.
3. Enable drop stats for ODL pipe.

Change-Id: Id0a5871ebe4a0925c60dea39f197af9e1892d05e
Signed-off-by: Ashok Vuyyuru <avuyyuru@codeaurora.org
2021-07-22 14:06:10 +05:30
Ilia Lin
d9c21ec0f3 ipa: NTN3 EDMA mode limitation DB fix
Provide MSI DB register address instead of DB register.

Change-Id: If31998b71c71f11020577c7a581cc11ac93db29f
Acked-by: Eliad Ben Yishay <ebenyish@qti.qualcomm.com>
Signed-off-by: Ilia Lin <ilialin@codeaurora.org>
2021-07-22 10:06:30 +03:00
qctecmdr
96433bd0f6 Merge "msm: ipa5: ipa_stats support for ipa_lnx_agent" 2021-07-20 19:55:14 -07:00
Michael Adisumarta
8e3953ea4e msm: ipa5: ipa_stats support for ipa_lnx_agent
Includes support for IPA stats to be able to send log packet
to ipa_lnx_agent and then to SPEARHEAD framework.

Change-Id: I3112fc6b2e66e15140f638bfff9905bba6997e46
Signed-off-by: Michael Adisumarta <madisuma@codeaurora.org>
2021-07-20 13:44:23 -07:00
qctecmdr
b63f1930db Merge "msm: ipa3: ignore multiple crash for active_clients" 2021-07-19 17:49:34 -07:00
qctecmdr
fbd3bfa6f7 Merge "msm: ipa3: Return the correct max PDN value for all IPA HW types" 2021-07-19 15:28:21 -07:00
Skylar Chang
e16486e14d msm: ipa3: ignore multiple crash for active_clients
Ignore recursive panic and multiple crash instances
for ipa3_active_clients_panic_notifier.

Change-Id: I1abcb641dc4ceb18e3638f9cd8a8725b029bb524
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
2021-07-19 09:53:13 -07:00
qctecmdr
50c4f795a9 Merge "msm: ipa3: increase pkt ctx for cv2x rsrc grp" 2021-07-19 04:58:28 -07:00
Raghavendar rao l
155c5abe4b msm: ipa: Updating the last index of qmi handler array with NULL
Update in the qmi handler structures last index to NULL, to avoid
the out of bound access attempt while handling qmi notifications
from IPA.

Change-Id: I51b3e4369fcf4c9c235307cfd7c6415c525da496
Signed-off-by: Raghavendar rao l <rlomte@codeaurora.org>
2021-07-19 10:59:04 +05:30
qctecmdr
3f75dd9c55 Merge "msm: ipa3: Fix to prevent Integer Overflow" 2021-07-17 09:13:54 -07:00
Pooja Kumari
be8c107e27 msm: ipa3: increase pkt ctx for cv2x rsrc grp
Made the changes to increase rsrc pkt conexts
from 1 to 6 to support cv2x auto case.

Change-Id: I2f9774fd473248ce4f86748be83c2a9b58ab16a8
Signed-off-by: Pooja Kumari <kumarip@codeaurora.org>
2021-07-15 12:00:28 +05:30
Ilia Lin
01285ef741 ipa: Remove unneeded warning
If userspace commands to delete last rule in a routing table,
then a an empty table may be commited. This is possible case,
so no warning is needed.

Change-Id: I04b6a9d3bdcaf28f35046c328e46a2719680d2a1
Signed-off-by: Ilia Lin <ilialin@codeaurora.org>
2021-07-15 08:11:12 +03:00
qctecmdr
0739e92588 Merge "ipa: Fix dangling HPC entry rndis/ecm composition switch when ULSO enabled in dts" 2021-07-14 11:15:43 -07:00
Piyush Dhyani
46ca374819 msm: ipa3: Fix to prevent Integer Overflow
The value of `req->filter_spec_ex2_list_len`
is user input via ioctl and it's type is uint32,
so an integer overflow may occur. Which can result
in out of bound access in the following loop. Now
add changes to prevent Integer overflow.

Change-Id: Ia29b9ddc674e5dd3d5baf6623cf0a464c156d8f7
Signed-off-by: Piyush Dhyani <pdhyani@codeaurora.org>
2021-07-14 20:36:31 +05:30
qctecmdr
daf9ada1b3 Merge "msm: ipa3: add dymaic IPPT SW-flt functionality" 2021-07-13 23:09:22 -07:00