Qmuxd bridge daemon is opening /dev/gps before USB enumerated with
USB composition having GPS interface as part of it. This daemon
performs EP_LOOKUP ioctl and encounters failure. It keeps retrying
for some iterations, and later goes into sleep and doesn't perform
any IOs. This results into no GPS related IOs between daemon and
host side QMUXD driver. Hence this change sends zero length packet
for MBIM (as QBI also faces same issue) and GPS interface when
USB cable is connected and those interfaces are part of USB
composition. Both QBI and Qmuxd bridge daemon are now wait for zero
length packet as indication for change in USB cable status, and
queries using GSI_MBIM_GPS_USB_STATUS IOCTL (newly added). Based on
this IOCTL related response, both daemons performs read/write with
created control devices.
Change-Id: Ib47443fe0e473ab4e27facb3f2927b8c13966158
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
A number of kthread-related functions indirectly take task_struct->pi_lock
while holding worker->lock in the call chain like this:
spin_lock(&worker->lock)
kthread_insert_work
wake_up_process
try_to_wake_up
raw_spin_lock_irqsave(&p->pi_lock, flags)
This lock dependency exists whenever kthread_insert_work is called either
directly or indirectly via __kthread_queue_delayed_work in the following
functions:
kthread_queue_work
kthread_delayed_work_timer_fn
kthread_queue_delayed_work
kthread_flush_work
kthread_mod_delayed_work
This creates possibilities for circular dependencies like the one reported
at [1]. Break this lock dependency by moving task wakeup after worker->lock
has been released.
[1]: https://lore.kernel.org/lkml/CAJuCfpG4NkhpQvZjgXZ_3gm6Hf1QgN_eUOQ8iX9Cv1k9whLwSQ@mail.gmail.com
Reported-by: Ke Wang <ke.wang@unisoc.com>
Reported-by: Shakeel Butt <shakeelb@google.com>
Suggested-by: Peter Zijlstra <peterz@infradead.org>
Tested-by: Shakeel Butt <shakeelb@google.com>
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Link: https://lkml.org/lkml/2020/5/4/1148
Cherry picked instead of commit 461daba06bdcb9c7a3f92b9bbd110e1f7d093ffc
as an alternative solution for the lockdep error that does not break KMI.
Bug: 174875976
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I2478847f66c85dca953846cd77955928d690c97c
gps usb functionality is implemented using qmi packets.
User space entity sends and receives QMI packets using
misc device named /dev/gps.
Change-Id: I73af1caa9b272597909199022739390274a4b034
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
Signed-off-by: Elson Roy Serrao <eserrao@codeaurora.org>
If emergency system shutdown is called, like by thermal shutdown,
dm device could be alive when the block device couldn't process
I/O requests anymore. In this status, the handling of I/O errors
by new dm I/O requests or by those already in-flight can lead to
a verity corruption state, which is misjudgment.
So, skip verity work for I/O error when system is shutting down.
Change-Id: I7b2e79283bb5810cefe688bf43b9ae97030ce917
Reviewed-by: Sami Tolvanen <samitolvanen@google.com>
Signed-off-by: Hyeongseok Kim <hyeongseok@gmail.com>
Patch-mainline: dm-devel @ 12/03/20, 00:46
Signed-off-by: Ravi Kumar Siddojigari <rsiddoji@codeaurora.org>
This reverts commit b649934e08.
Based on the upstream review comments its not advised to
ignore the block error and continue so reverting this .
Change-Id: Icf18bd5bdba96b396eee3ddff7e6d39a9bed5816
Signed-off-by: Ravi Kumar Siddojigari <rsiddoji@codeaurora.org>
This change enables novatek nt36xxx config for holi target.
Change-Id: I11842aae692dd9294c314e0a7fddb1c9cf63942b
Signed-off-by: Ravikanth Tuniki <rtunik@codeaurora.org>
Cleanup the clock ID's of GPU and Video clock controllers that are
not required to be controlled from HLOS.
Change-Id: I0d5b67ddbf3f080c70ed0a1a743f3bf7afef240f
Signed-off-by: Jagadeesh Kona <jkona@codeaurora.org>
Pull the RFR line before doing stop_rx in uart driver.
This is to prevent any rx data to come into the uart rx fifo when
stop_rx is being executed.
Remove the rx length zero check in
handling dma rx to prevent race conditions with EOT and DMA_DONE
interrupt bits.
Issue scenarios could be that during baud rate change/ runtime
suspend or any other place where stop_rx is used, there might
be a race between rx data entering uart rx fifo and availability
of dma buffers in uart driver. In this scenarios there will
be interrupt storm with rx water mark interrupt.
Change-Id: I92163c4997c1709269dce67a1d492533f710abfb
Signed-off-by: Prudhvi Yarlagadda <pyarlaga@codeaurora.org>
Add snapshot of the smb358 charger as of msm-4.14
commit 790f0644f00c ("net: stmmac: Alert QTI on SDX
of host AP's SSR status"). Fix minor static analysis
tool errors.
Change-Id: I7c88f48a90cfca6c22ac4ed5289f78a32e524dc4
Signed-off-by: Kavya Nunna <knunna@codeaurora.org>
When calculating play length for FIFO play, it is out of bound
of the FIFO samples array. Fix it.
Change-Id: I8ad458802a0070f493ac53160ab90a6cf648d9e7
Signed-off-by: Fenglin Wu <fenglinw@codeaurora.org>
Add novatek chip id and firmware during boot up to
enable touch.
Change-Id: I382ae51c7bb4bf270c2e01b484281fcc24270062
Signed-off-by: Ravikanth Tuniki <rtunik@codeaurora.org>
Update phy revision information before calling phy_init(),
so that phy driver can perform revision specific configurations.
Change-Id: I834306851e30a203705ad824fc142813b989abc5
Signed-off-by: Veera Vegivada <vvegivad@codeaurora.org>
Enable MFD SPMI PMIC driver and several SPMI and PMIC drivers
which are needed to provide baseline support of PMIC peripherals.
Change-Id: Ic0b24c62bec654c61bbf0034c20d775d686eb9c4
Signed-off-by: Veera Vegivada <vvegivad@codeaurora.org>
Add support for UFS controller and add support for
QTI inline encryption.
Change-Id: I680c75448c0fd9b2e6c37d106075c1a39213abac
Signed-off-by: Veera Vegivada <vvegivad@codeaurora.org>
Enable interconnect L3 driver so that consumer can vote
for L3 performance points.
Change-Id: Id0ff3e976976a05fa6ff47c7ccb9e1a3a3aed2e3
Signed-off-by: Veera Vegivada <vvegivad@codeaurora.org>
Enable the SM8150 interconnect driver so that consumers are
able to obtain their path handles properly.
Change-Id: Ie099accf2dbfa587f23dd9f434bf04c7eca6b348
Signed-off-by: Veera Vegivada <vvegivad@codeaurora.org>
To improve OVP handling increase the min-offtime and dead-time
as per hardware recommendation.
Change-Id: I28040808d6c114b718aad0e0ab63554683e7746f
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>
Currently, interrupts of qcom-spmi-adc5 driver are registered
with name "pm-adc5". However on platforms with multiple PMICs
that can have different ADC types (adc5 or adc7), this naming
is not user friendly when looking at interrupt data. Add a name
that looks unique for different adc types so that they can be
interpreted easily.
Change-Id: Iac1080dc8e02d278b30cff0d61eca40e081bc306
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
USB secondary event ring is being freed before it is being unmap.
Fix this by calling xhci_sec_event_ring_cleanup() after unmapping.
Also move secondary event ring cleanup and unmap related duplicate
code into one API.
Change-Id: I420f53d9e3ad6aa7b310dc354c7d35ce139afbe9
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
To avoid build failures in the newer Android build systems,
run the headers_install script explicitly under 'sh'.
Change-Id: If30d2bda653c6be443345a2594e9993d9780db21
Signed-off-by: Soumil Shah <soumshah@codeaurora.org>
Signed-off-by: Raghavendra Rao Ananta <rananta@codeaurora.org>
Make local device pointer NULL when .remove is
invoked.
Change-Id: I5bf91367b633abf79cbc60ef5bdf93cca955902c
Signed-off-by: rbandi <rohitbandi@codeaurora.org>
Set ref_clk_src to NULL if clk_get() API fails to get handle
in probe(), else it results in invalid pointer derefernce.
Change-Id: I1ba5f64bc2a691923cbac1c7b4e9288b6071ff57
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
Attribute pointer used while creating the common
and monitor pmu events, needs to be freed while returning
from function.
Change-Id: I7862e8ec81754102d2700cac03bb739c9bcdf32b
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
Update available freuqency output format, previously entries in the
output is separated with new line, update this format to have space
after each entry instead of new line.
Also update the available frequency node from available_freq to
available_frequencies.
Change-Id: I2b2409168713477cbc801c8837a11c5c4613e996
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
This change enables F2FS fault injection support
to inject faults such as ENOSPC, ENOMEM etc for
debug and test purpose.
Change-Id: I55131d87c2305d0567631c1f0022ea66e24d9339
Signed-off-by: Sayali Lokhande <sayalil@codeaurora.org>
Sometimes probably crashdump timeout scenarios accessing addr_mode_cntl
registers through the host path resulting to slave timeout issue.
Hence revert this commit 'fca32c53c237("msm: kgsl: Add addr_mode_cntl
registers for legacy snapshot for holi gpu")'.
Change-Id: I771d9aecad69dd03d7e2ab771aee164c1cdfeabd
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
In case of Qsee_log we are not using the tzbsp_diag_buf
so there is no need to copy that.
Change-Id: Iabffd1708507e16ef8d75102637fd45bb7182549
Signed-off-by: Monika Singh <monising@codeaurora.org>
To prevent leakage in ship-mode toggle OVP_IGNORE_UVLO after
USB-removal and during shutdown.
Change-Id: Idb482dd63d4939be5b19594385c642a61531e662
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>