There is one race condition where mhi_prepare_channel is called
in which read pointer and write pointer is set to base address
and in parallel there could be an MHI M0 transaction which
checks any pending event rings on all channels (tre_ring)
with RP != WP and rings channel DB which causes Null pointer
access. Check for MHI channel is enabled before ringing channel
doorbell. Reset mhi channel chan_ctxt, tre_ring and buf_ring
wp and rp to NULL in mhi_deinit_chan_ctxt.
Change-Id: If30908fc7fcc26f6987bd0da886bb75468a29b9e
Signed-off-by: Vivek Pernamitta <vpernami@codeaurora.org>
The change ensures appropriate reference is held in
each function before accessing valid synx handle.
This avoids release function destroying the synx
handle while any other process is working with the
same handle, leading to use-after-free issues.
Change-Id: I5b828c5ab6f7fcdd5b5a66e04d9c7c827de5d15f
Signed-off-by: Sumukh Hallymysore Ravindra <shallymy@codeaurora.org>
Due to zero length skb packet IPA HW going to stall state.
Adding changes to avoid sending these zero length SKB frag
packets to HW.
Change-Id: I4dae51bf767588095bc1fcd9e10196e913299227
Signed-off-by: Ashok Vuyyuru <avuyyuru@codeaurora.org>
Update the copyright years of file to 2017, 2019-2021.
Change-Id: Ic5c6ad17f546b981c131fc6bd0eb573859a104b5
Signed-off-by: Mohammed Siddiq <msiddiq@codeaurora.org>
This reverts commit c6bc8ac9c5.
But there are revert conflicts in:
net/ipv4/tcp_input.c
net/ipv4/tcp_output.c
which effectively mean those files are not reverted (the relevant portions
of code area already missing).
Test: see follow up commit
Bug: 180068784
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I70bc587e7bae4090dfd101f2427d7cc4fb4435af
Git-Commit: b72347bdd09c65269646ce5eaefd0bb579552a44
Git-repo: http://source.codeaurora.org/quic/la/kernel/common
Signed-off-by: Kaustubh Pandey <kapandey@codeaurora.org>
Make sure to hold the sock_tag_list_lock while accessing the tag to
avoid a race between getting the tag and free'ing the tag.
Bug: 184018316
Fixes: c7ca0ac69702 ("ANDROID: netfilter: xt_qtaguid: add qtaguid matching module")
Signed-off-by: Will McVicker <willmcvicker@google.com>
Change-Id: Ia44dfcc1693bc3de1d767e024d09c11f4a8b02f9
Git-commit: 2398e650c58a6f4877dafce649188290f6e3b4f5
Git-repo: https://android.googlesource.com/kernel/msm
Signed-off-by: PavanKumar S.R. <pavasr@codeaurora.org>
Add ETR status check while receiving USB_QDSS_CONNECT event.
Otherwise, there will cause crash due to NULL pointer issue.
Since ETR buffer will be released if ETR is disabled.
Change-Id: I358d25477c938844df5bff5c29ddbee307b770e3
Signed-off-by: Tao Zhang <taozha@codeaurora.org>
Remove the gcc_camss_camnoc clocks from debugcc
which are not registered in GCC to avoid the crash
because of parent index in KHAJE.
Change-Id: Ia8db40e55c3f7d96abb47bb810eb4f13c20e65f2
Signed-off-by: Madhuri Medasani <mmedasan@codeaurora.org>
Consider a case where ffs_data_new is getting called from
ffs_fs_get_tree and ffs_data_new returns error pointer since
the function (e.g. adb) is already mounted. The driver is only
checking for the NULL return value for ffs but in this case it
will not be NULL, which will fail the check and driver will go
ahead accessing invalid pointer which can lead to inconsistencies.
Fix this by having NULL as well as error pointer check for ffs.
Change-Id: Idad5a0b91148325258ea3f545d4da71644c7fc53
Signed-off-by: Pratham Pratap <prathampratap@codeaurora.org>
Stop_rx is bailing out in the runtime suspend path because of
parallel data from SOC and there is no SW FLOW ON from UART,
causing SOC unable to send RX data to host.
Enabled SW flow on if the stop_rx is bailing out during
runtime suspend.
Change-Id: I0dd52fafe99466e6177a60a108132f25a5be570b
Signed-off-by: Yatish Kumar Singh <yatishku@codeaurora.org>
Enable RPM SMD cooling device driver for KHAJE. It monitors
device temperature and request different temperature band levels
to RPM hardware.
Change-Id: Ia0c4deed12ee94f8fa0a6e98950e0654576740e1
Signed-off-by: Gopala Krishna Nuthaki <gnuthaki@codeaurora.org>
Enable CONFIG_ION_SYSTEM_HEAP for bengal which is required to
get ion pool stats for system heap.
Change-Id: Ia41490fdffe3c1a1cd0a8a56e718eff42c0bc646
Signed-off-by: Vijayanand Jitta <vjitta@codeaurora.org>
Fix the unnecessary periodic wakeups of discard thread that happens under
below two conditions -
1. When f2fs is heavily utilized over 80%, the current discard policy
sets the max sleep timeout of discard thread as 50ms
(DEF_MIN_DISCARD_ISSUE_TIME). But this is set even when there are
no pending discard commands to be issued.
2. In the issue_discard_thread() path when there are no pending discard
commands, it fails to reset the wait_ms to max timeout value.
Change-Id: Ic358ea425a1e152438eb3185e6b7932c7fd4930f
Signed-off-by: Sahitya Tummala <stummala@codeaurora.org>
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Git-commit: c35b8d5e757e0fd0144890b7b536f7b756f3a648
Git-repo: https://android.googlesource.com/kernel/common/
Signed-off-by: Sayali Lokhande <sayalil@codeaurora.org>
With the default DPOLICY_BG discard thread is ioaware, which prevents
the discard thread from issuing the discard commands. On low RAM setups,
it is observed that these discard commands in the cache are consuming
high memory. This patch aims to relax the memory pressure on the system
due to f2fs pending discard cmds by changing the policy to DPOLICY_FORCE
based on the nm_i->ram_thresh configured.
Change-Id: Icac4a6ad2885eb463d7e11bfc99486a4cb96533b
Signed-off-by: Sahitya Tummala <stummala@codeaurora.org>
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Git-commit: d6d2b491a82e1e411a6766fbfb87c697d8701554
Git-repo: https://android.googlesource.com/kernel/common/
Signed-off-by: Sayali Lokhande <sayalil@codeaurora.org>
when usb_bypass_notify is called by ush_qdss_close(), no need to
response to USB_QDSS_DISCONNECT event. so add etr status check to
avoid exception.
Change-Id: I4ab5d7f4ba054b0d1ecc7026b5662ddc1c8b5ca1
Signed-off-by: Yuanfang Zhang <zhangyuanfang@codeaurora.org>
Few wakelocks tends to get stuck for no reason. Blocking them
isn't necessary and sometimes blocking them breaks basic
functionality.
Wakelocks like "tx_swr_ctrl" tends to get stuck if we keep earphones
connected and drops battery massively.
Test: Keep earphones plugged in and leave device for few hours
Expected result: No "tx_swr_ctrl" is being stuck.
Actual result: Patch is working as expected.
Change-Id: I5296990a84ab44cf6e449d6535b8b99408c415c8
Signed-off-by: Panchajanya1999 <panchajanya@azure-dev.live>
Currently both Bengal and Khaje use the same MPM pins mapping
configuration as they use the same compatible string. USB PHY
has a different GIC IRQ on Khaje, so different MPM configuration
is required.
Change-Id: I680bb0529145dfe2166f5b26d934da34e5c52f98
Signed-off-by: Raghavendra Kakarla <rkakarla@codeaurora.org>