WLAN is not needed in charger mode. Thus add a sysfs entry to notify
charger mode to cnss platform driver to ignore wlan init request.
Change-Id: I4719b16e7fa6914c253018284b5a5d80acf14bbb
Signed-off-by: Manikandan Mohan <quic_manikand@quicinc.com>
Instead of calling __scm_smc_call() recursively to make the
waitqueue-specific SMC calls, make them directly by populating the SMC
call arguments by hand and calling __scm_smc_do_quirk().
Motivating points for this change:
1. With the exception of get_wq_ctx(), the other two waitqueue-specific
SMC calls wq_wake_ack() and wq_resume() can return WAIT_SLEEP, and
this cycle of attempting to resume and sleeping can take place
several times. With recursive logic, this can potentially lead to
stack overflow.
2. If an SMC client call has received WAITQ_SLEEP, it must prevent other
fresh client calls from being made until it has reached completion
(success or error). Therefore, handle the waitqueue operations within
the mutex qcom_scm_lock.
Use a do-while loop to iteratively check the return values of
wq_resume() and wq_wake_ack() for WAITQ_SLEEP or WAITQ_WAKE.
Change-Id: I937eb00c753903885fb211abb2bfeec5c431ee35
Signed-off-by: Guru Das Srinagesh <quic_gurus@quicinc.com>
This change fixes bootup crash if trusted touch related dtsi entries
are not present.
Change-Id: I5436a5c90bce7f8705c98f4c2e861b1471985a05
Signed-off-by: BIVASH KUMAR SINGH <bkumarsi@codeaurora.org>
This change registers for early SSR notifications for the ADSP
remoteproc, which is responsible for running the DRV logic
when APSS enters suspend mode.
Change-Id: Ib81c61835476c582d4f07eb102c0e0594fe4a5bf
Signed-off-by: Siddharth Gupta <sidgup@codeaurora.org>
Devices which cannot tolerate latencies in notification after a
remoteproc crash (such as PCIe), need a way to be notified in a
fraction of a second to ensure they meet the QoS requirements.
This change adds APIs to provide a way for such device drivers
to register for early notifications.
Change-Id: Ieee0c3868962fc825407d7292e4be9f10248c864
Signed-off-by: Siddharth Gupta <sidgup@codeaurora.org>
Signed-off-by: Mukesh Ojha <quic_mojha@quicinc.com>
To allow for early notifications to be sent to the SSR clients the q6v5
driver needs a way to invoke the SSR subdevice for the remoteproc. This
change adds an API in the q6v5 IRQ layer to optionally register the SSR
subdevice, and registers the SSR subdevice in the PAS driver.
Change-Id: I450d262575538b6b2c2e038a41fd0cca234bc3b2
Signed-off-by: Siddharth Gupta <sidgup@codeaurora.org>
The following deadlock has been observed on a test setup:
* All tags allocated.
* The SCSI error handler calls ufshcd_eh_host_reset_handler()
* ufshcd_eh_host_reset_handler() queues work that calls ufshcd_err_handler()
* ufshcd_err_handler() locks up as follows:
Workqueue: ufs_eh_wq_0 ufshcd_err_handler.cfi_jt
Call trace:
__switch_to+0x298/0x5d8
__schedule+0x6cc/0xa94
schedule+0x12c/0x298
blk_mq_get_tag+0x210/0x480
__blk_mq_alloc_request+0x1c8/0x284
blk_get_request+0x74/0x134
ufshcd_exec_dev_cmd+0x68/0x640
ufshcd_verify_dev_init+0x68/0x35c
ufshcd_probe_hba+0x12c/0x1cb8
ufshcd_host_reset_and_restore+0x88/0x254
ufshcd_reset_and_restore+0xd0/0x354
ufshcd_err_handler+0x408/0xc58
process_one_work+0x24c/0x66c
worker_thread+0x3e8/0xa4c
kthread+0x150/0x1b4
ret_from_fork+0x10/0x30
Fix this lockup by making ufshcd_exec_dev_cmd() allocate a reserved
request.
This patch is closely related to the upstream patch with the same title.
Bug: 205080886
Link: https://lore.kernel.org/linux-scsi/700f0463-23a9-8465-f712-1188cb884dea@acm.org/T/#u
Change-Id: I9e9ba3f45ba23ecf576380aa19701d3437af6cdd
Signed-off-by: Bart Van Assche <bvanassche@google.com>
Before reducing 'can_queue' from 32 to 31, make
ufshcd_change_queue_depth() restrict the queue depth to 'can_queue'
instead of hba->nutrs (32). This is a backport of a subset of the
following patch: "[PATCH 2/2] scsi: ufs: Fix a deadlock in the error
handler".
Bug: 205080886
Link: https://lore.kernel.org/linux-scsi/20211103000529.1549411-3-bvanassche@acm.org/
Change-Id: I6e694a9698f91293fc2987217e3f939726c397dd
Signed-off-by: Bart Van Assche <bvanassche@google.com>
This change will initialize the tlmm gpios for trusted touch.
Change-Id: Ia2d1c66aac8e0be71ede7bba02c892e66773f1a7
Signed-off-by: BIVASH KUMAR SINGH <bkumarsi@codeaurora.org>
This change activate PM wakeup source in following way:
1. Activate on receive a spcom request from SPU
2. Close window in the end of packet exchange or timeout:
- end of tx of spcom response to SPU (server case)
- end of delivery of spcom request to usersace (client case)
- timeout for handling a packet exchange for 2 seconds
Change-Id: Ibbb6ba9870226299e5731fda6133c3dde780ca25
Signed-off-by: Konstantin Dorfman <kdorfman@codeaurora.org>
Adb client on device expects a blocking read from mhi. While mhi
is in suspend, it is returning with an error value. This is
causing the adb client to spawn every 1ms causing error code to
flood the serial logs. If mhi is in suspend and adb client tries
to poll for data, remove the read request from the list to block
the read.
Change-Id: Idaa70568cbddaf6b99fb5c6722a4da594d3e066d
Signed-off-by: Gauri Joshi <gaurjosh@codeaurora.org>
The CH completion commands are sent in async fashion, whereas the ch
cmd ack event is send in a sync fashion. This can lead to the host
receiving completions post the reset ch ack. These ch completion
events post ch reset would be treated as OOS events.
Making changes to send cmd ack events in async fashion to maintain the
ordering that is being sent to the host.
Change-Id: Ib2d568ea1d69486f3d1ebf4e7b209bba3315eba5
Signed-off-by: Subramanian Ananthanarayanan <skananth@codeaurora.org>
Signed-off-by: Gauri Joshi <gaurjosh@codeaurora.org>
Signed-off-by: Lakshmi Prasanna Meka <quic_lmeka@quicinc.com>
Poll for ipa_dma_disable prior to entering mhi suspend, until it returns
success. this is to prevent IPA disable failure in case on
pending transfers.
Change-Id: I38143284447b86ce34c47e100e6fe0c23cf28f0b
Signed-off-by: Subramanian Ananthanarayanan <skananth@codeaurora.org>
Signed-off-by: Nitesh Gupta <nitegupt@codeaurora.org>
Signed-off-by: Gauri Joshi <gaurjosh@codeaurora.org>
Signed-off-by: Lakshmi Prasanna Meka <quic_lmeka@quicinc.com>
Add master and slave ID constants for all Qualcomm Technologies, Inc.
Neo interconnect providers which consumers can use to set bandwidth
constraints and find paths in the NoC (Network-On-Chip) topology.
Change-Id: I2c0e62f96ba6288b6903f0dd13a2d68aa7b3ec49
Signed-off-by: Odelu Kukatla <okukatla@codeaurora.org>
Commit 4c22227e39 ("cfg80211: fix management registrations locking")
in 5.10.77, which is commit 09b1d5dc6ce1 ("cfg80211: fix management
registrations locking") upstream, moved the mgmt_registrations_lock out
of struct wireless_dev. This did not change the structure size, but
caused a CRC change in the structure pointer, which tripped the abi
checker.
So restore the variable, and comment that this is not used anymore. No
driver should ever be touching this so it is safe.
Note, using a __GENKSYMS__ hack would work, as the overall structure
size remains the same when this variable is removed, BUT the warning
that the field is gone is reported by libabigail correctly, which would
require a .xml update, so it's not worth it.
Bug: 161946584
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Ibcfe743833860e6f75611d7ebed1036a77be0a69
The management registrations locking was broken, the list was
locked for each wdev, but cfg80211_mgmt_registrations_update()
iterated it without holding all the correct spinlocks, causing
list corruption.
Rather than trying to fix it with fine-grained locking, just
move the lock to the wiphy/rdev (still need the list on each
wdev), we already need to hold the wdev lock to change it, so
there's no contention on the lock in any case. This trivially
fixes the bug since we hold one wdev's lock already, and now
will hold the lock that protects all lists.
Cc: stable@vger.kernel.org
Reported-by: Jouni Malinen <j@w1.fi>
Fixes: 6cd536fe62 ("cfg80211: change internal management frame registration API")
Link: https://lore.kernel.org/r/20211025133111.5cf733eab0f4.I7b0abb0494ab712f74e2efcd24bb31ac33f7eee9@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Bug: 204384349
(cherry picked from commit 09b1d5dc6ce1c9151777f6c4e128a59457704c97)
Signed-off-by: Veerendranath Jakkam <quic_vjakkam@quicinc.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Id1bca68277be3a5f7c7329a8195018946f686bdb
Enable the interconnect driver so that consumers are
able to obtain their path handles properly.
Change-Id: I39cb8d60fd1c8f1a0c986e28e7dbfb61acc8fe56
Signed-off-by: Odelu Kukatla <okukatla@codeaurora.org>
Add stub interconnect providers for config_noc, dc_noc,
gem_noc, lpass_ag_noc, mc_virt_noc, mmss_noc, nsp_noc
and system_noc. This will allow consumers to get their
path and set bandwidth constraints on them.
Change-Id: Ibe4324defd8003ab74da74b0d13ed82e2ebd33eb
Signed-off-by: Odelu Kukatla <okukatla@codeaurora.org>
When cpu capacities are updated, due to either thermal or frequency
limits, print trace output to understand why the change happened.
Change-Id: I5c09ddbcbfae5b26a23d6d2ca07b38c89159f878
Signed-off-by: Shaleen Agrawal <shalagra@codeaurora.org>
Ensure the rbtree entry which saves the pages associated with
a vmalloc address is removed prior to vunmapping that vmalloc
address.
Thread 1:
fast_smmu_free
qcom_dma_common_free_remap
vunmap(cpu_addr)
Thread 2:
fast_smmu_alloc
qcom_dma_common_pages_remap
/* get address which was just freed by Thread1 */
cpu_addr = vmap
/* Error - cpu_addr not yet removed from by Thread1 */
qcom_insert_vm_area
Change-Id: I4b5a621f030a1839625c4dccda4dbced4c09c584
Signed-off-by: Patrick Daly <quic_pdaly@quicinc.com>
If kgsl mem entries are being accessed in sysfs and if putting
back the mementry refcount triggers a free of the process private,
we have a mutex deadlock. Because freeing the process private triggers
removal of the sysfs directories from within a thread that is accessing
the sysfs files. Fix this by taking an extra refcount on the process
private and then putting it back in a deferred manner.
Change-Id: I7db0e6144cabec2a86df9afbc500cd0ba3af0291
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
* keystone/mirror-android12-5.10:
ANDROID: GKI: Update symbol list for VIVO
FROMGIT: usb: gadget: f_mass_storage: Disable eps during disconnect
FROMGIT: usb: gadget: udc: core: Revise comments for USB ep enable/disable
UPSTREAM: tracing/cfi: Fix cmp_entries_* functions signature mismatch
FROMGIT: scsi: ufshpb: Do not report victim error in HCM
FROMGIT: scsi: ufshpb: Verify that num_inflight_map_req is non-negative
FROMGIT: scsi: ufshpb: Use a correct max multi chunk
FROMGIT: scsi: ufshpb: rewind the read timeout on every read
ANDROID: sched: Add vendor hooks for sync_entity_load_avg
ANDROID: GKI: Add symbols to abi_gki_aarch64_oplus
ANDROID: GKI: Update symbols to symbol list
ANDROID: fips140: add name and version, and a function to retrieve them
ANDROID: fips140: add service indicators
Signed-off-by: Daniel Norman <danielnorman@google.com>
Change-Id: Idbc0a2bbb1e33c64da8ec44f46a9ebaf2d57c42a
Currently, the a6xx CP init sequence has a stale dword at the end. Fix
this by correcting the size of the CP init sequence.
Change-Id: I91fb37ed11e758f50a56287a8a17fdc8061a55ae
Signed-off-by: Akhil P Oommen <akhilpo@codeaurora.org>