Commit graph

855748 commits

Author SHA1 Message Date
qctecmdr
d68b91f2a3 Merge "thermal: Read raw values for ADC_TM calibration channels" 2021-10-28 08:26:36 -07:00
qctecmdr
c0ae756bcc Merge "qdss_bridge: fix stuck issue when driver remove" 2021-10-28 03:59:25 -07:00
Archana Sriram
f64bb2ec2b thermal: Read raw values for ADC_TM calibration channels
Read raw values while measuring reference voltages for
ADC TM calibration channels REF_625mv, REF_1250v, REF_VDD
and REF_GND.

Change-Id: I3f5f032f7ebcd3c526c747de88808d56a907201d
Signed-off-by: Archana Sriram <apsrir@codeaurora.org>
2021-10-28 03:47:51 -07:00
qctecmdr
9e2b9b27e2 Merge "BACKPORT: dma-buf: Move dma_buf_release() from fops to dentry_ops" 2021-10-27 03:26:31 -07:00
qctecmdr
d093d67165 Merge "defconfig: Enable Novatek NT36xxx Touch for tron target" 2021-10-27 03:26:31 -07:00
qctecmdr
9b6023ffc3 Merge "power: smb1398-charger: Toggle UVLO for Slave CP on USB removal" 2021-10-27 03:26:31 -07:00
Yuanfang Zhang
db786c4d22 qdss_bridge: fix stuck issue when driver remove
Only the memory written to usb needs to wait for write complete
when removed driver or modem ssr happened. The "used" member is
used to mark the state of memory written to usb.

Change-Id: Ia1755a6c38f8419c5282347744a3d8f3d3b58ad7
Signed-off-by: Yuanfang Zhang <zhangyuanfang@codeaurora.org>
2021-10-25 19:18:38 -07:00
Pavankumar Kondeti
2c785c99c2 media: uvcvideo: Use cached memory for USB transfers
Use kmalloc() + DMA streaming API instead of DMA coherent
memory. The coherent memory is uncached and results in slower
decode performance.

Change-Id: Ibb5990adc3bc319fd704534721140644d76a5787
Signed-off-by: Pavankumar Kondeti <quic_pkondeti@quicinc.com>
2021-10-25 18:25:53 +05:30
Prashant Beniwal
64e09908f3 defconfig: Enable Novatek NT36xxx Touch for tron target
This change enables novatek nt36xxx config for tron target.

Change-Id: Ib250ae917e9fd4bf96a863c0a6f6013a2e4008b6
Signed-off-by: Prashant Beniwal <pbeniw@codeaurora.org>
Signed-off-by: Ravikanth Tuniki <rtunik@codeaurora.org>
2021-10-25 04:11:31 -07:00
qctecmdr
4413a8e88b Merge "cnss2: Dump PCIE SOC scratch registers along with mhi reg dumps" 2021-10-22 08:01:25 -07:00
qctecmdr
8cdb56c008 Merge "ANDROID: mm: use raw seqcount variants in vm_write_*" 2021-10-22 04:47:47 -07:00
qctecmdr
aeb2acbbab Merge "defconfig: Enable PMIC related configs for MSM8937_32" 2021-10-22 04:47:45 -07:00
Mohammed Siddiq
8ed6a3a151 cnss2: Dump PCIE SOC scratch registers along with mhi reg dumps
Add code to dump PCIE SOC scratch registers along with mhi reg
dumps to enhance debug info.

Change-Id: I65fc8324a8cccac6f5ffe73f6fc9513a561ee32e
Signed-off-by: Mohammed Siddiq <msiddiq@codeaurora.org>
2021-10-22 14:30:43 +05:30
qctecmdr
d0da52081a Merge "net: qrtr: Change error logging in callback" 2021-10-22 01:35:50 -07:00
Vinayak Menon
1091e4b2ff ANDROID: mm: use raw seqcount variants in vm_write_*
write_seqcount_begin expects to be called from a non-preemptible
context to avoid preemption by a read section that can spin due
to an odd value. But the readers of vm_sequence never retries and
thus writers need not disable preemption. Use the non-lockdep
variant as lockdep checks are now in-built to write_seqcount_begin.

Bug: 161210518
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
Change-Id: If4f0cddd7f0a79136495060d4acc1702abb46817
Git-commit: c9201630e8a53106406516ba40862e637c324480
Git-repo: https://android.googlesource.com/kernel/common/
Signed-off-by: Srinivasarao Pathipati <quic_spathi@quicinc.com>
2021-10-21 22:57:43 -07:00
qctecmdr
309d4e75f4 Merge "defconfig: Enable Charger/LED/RTC configs for MSM8937_32go" 2021-10-21 22:21:35 -07:00
qctecmdr
2152e3ff6b Merge "power: linear-charger: Report the correct battery status at SOC=0" 2021-10-21 22:21:34 -07:00
Akhil P Oommen
a7da315c33
msm: kgsl: Update the IFPC power up reglist
Update the IFPC power up reglist to include all the CP Protect
registers.

Change-Id: I1b43420c466b8a228892afac8ecf05b11b5a80e6
Signed-off-by: Akhil P Oommen <akhilpo@codeaurora.org>
2021-10-21 19:23:56 +05:30
qctecmdr
4bd53b8750 Merge "msm: ipa3: Add wait queue for the adpl" 2021-10-21 05:00:38 -07:00
qctecmdr
bac265dcd5 Merge "defconfig: arm64: msm: 8937-Turn on coresight configs" 2021-10-21 05:00:36 -07:00
qctecmdr
e585773147 Merge "cnss2: Update bound checks for sbl reg dumps to SRAM mem range" 2021-10-21 00:29:31 -07:00
qctecmdr
26fb8ab741 Merge "soc: qcom: memory_dump: Support ETB/ETR register dump" 2021-10-21 00:29:31 -07:00
qctecmdr
e3f130c799 Merge "defconfig: arm: msm: 8937-Turn on coresight configs" 2021-10-21 00:29:27 -07:00
qctecmdr
572cde9bce Merge "msm: ipa3: Fix to unlock mutex before return" 2021-10-20 21:08:44 -07:00
Ashok Vuyyuru
708cd30fd2 msm: ipa3: Add wait queue for the adpl
add changes to wait queue for the adpl.

Change-Id: I5330cbf7fe1439e04c011c143bdd68657469c36e
Signed-off-by: Ashok Vuyyuru <avuyyuru@codeaurora.org>
2021-10-20 11:51:09 -07:00
Ashok Vuyyuru
ae366eaec5 msm: ipa3: Fix to unlock mutex before return
Adding changes to unlock mutex before return from QMI
send request.

Change-Id: I39c32219db69fbc41b30507759bed16acb976005
Signed-off-by: Ashok Vuyyuru <avuyyuru@codeaurora.org>
2021-10-20 23:45:46 +05:30
Mohammed Siddiq
a1c23ce2f4 cnss2: Update bound checks for sbl reg dumps to SRAM mem range
Add code to update the bound checks for sbl reg dumps to SRAM mem
range. Due to a firmware update, the sbl start address was moved
and the bound checks to dumps sbl reg failed. Update the bound
checks to SRAM mem range, so that any future update in firmware
would not impact SRAM dumps.

Change-Id: I28026f03fe1f44f2ba6ff7f903dcb98543f8847c
Signed-off-by: Mohammed Siddiq <msiddiq@codeaurora.org>
2021-10-20 03:33:17 -07:00
Mohammed Siddiq
611fe630b2 cnss2: Fix the pbl log sram start address for QCA6490
Add code to fix the PBL log ram start address for QCA6490.

Change-Id: I2a2646947ef62d878f59aa10ab391a9c6a39200c
Signed-off-by: Mohammed Siddiq <msiddiq@codeaurora.org>
2021-10-20 03:32:08 -07:00
Shilpa Suresh
d9725fd321 defconfig: arm: msm: 8937-Turn on coresight configs
Enable all the coresight configs required for the ETR
functionality.

Change-Id: Id090afa0dbf492d90b96d930a721cce94e3d9b2f
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-20 01:56:25 -07:00
Shilpa Suresh
bc1c33a5ab arm: msm: Add support for coresight etr for 32 bit
Add all the changes and files required for turning on
coresight ETR for SDM439 32 bit builds.
Snapshots for etmv4x.h and debugv8.h are taken from
4.9 commit:1b3405b8 .

Change-Id: I1b16180bdd496f87e12c6736b7526c2ecde3502b
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-19 23:57:15 -07:00
Tingwei Zhang
157fb3045c soc: qcom: memory_dump: Support ETB/ETR register dump
Add support to dump the ETB/ETR register when enabling
ETB/ETR.

Change-Id: Ia4d4d49fe313adb4d1fe15413495909bc5f226fc
Signed-off-by: Tingwei Zhang <tingwei@codeaurora.org>
Signed-off-by: Saranya Chidura <schidura@codeaurora.org>
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-19 23:56:56 -07:00
Shilpa Suresh
3af32f4ac4 defconfig: arm64: msm: 8937-Turn on coresight configs
Enable all the coresight configs required for the ETR
functionality.

Change-Id: Ieccc48c5999fb1142265829c87b797853eb50c1b
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-19 23:55:52 -07:00
qctecmdr
2e5299cd17 Merge "msm: npu: handle system shutdown/reboot event properly" 2021-10-19 07:25:43 -07:00
qctecmdr
65ce6f8272 Merge "net: qrtr: fix a kernel-infoleak in qrtr_recvmsg()" 2021-10-18 13:18:35 -07:00
qctecmdr
c5bfb24d25 Merge "tty: Fix ->session locking" 2021-10-18 13:18:35 -07:00
Gopala Krishna Nuthaki
f391b6c81f drivers: thermal: Update a variable type in QMI encode logic
Change a variable type in QMI encode logic to avoid
buffer overflow scenario.

Change-Id: I11b10cce0e9ab5b02738b2ba13e637df979e9310
Signed-off-by: Gopala Krishna Nuthaki <gnuthaki@codeaurora.org>
2021-10-18 13:05:49 +05:30
Allen Chiu
96e6fb8126 BACKPORT: dma-buf: Move dma_buf_release() from fops to dentry_ops
Charan Teja reported a 'use-after-free' in dmabuffs_dname [1], which
happens if the dma_buf_release() is called while the userspace is
accessing the dma_buf pseudo fs's dmabuffs_dname() in another process,
and dma_buf_release() releases the dmabuf object when the last reference
to the struct file goes away.

I discussed with Arnd Bergmann, and he suggested that rather than tying
the dma_buf_release() to the file_operations' release(), we can tie it to
the dentry_operations' d_release(), which will be called when the last ref
to the dentry is removed.

The path exercised by __fput() calls f_op->release() first, and then calls
dput, which eventually calls d_op->d_release().

In the 'normal' case, when no userspace access is happening via dma_buf
pseudo fs, there should be exactly one fd, file, dentry and inode, so
closing the fd will kill of everything right away.

In the presented case, the dentry's d_release() will be called only when
the dentry's last ref is released.

Therefore, lets move dma_buf_release() from fops->release() to
d_ops->d_release()

Many thanks to Arnd for his FS insights :)

[1]: https://lore.kernel.org/patchwork/patch/1238278/

Fixes: bb2bb90 ("dma-buf: add DMA_BUF_SET_NAME ioctls")
Reported-by: syzbot+3643a18836bce555bff6@syzkaller.appspotmail.com
Cc: <stable@vger.kernel.org> [5.3+]
Cc: Arnd Bergmann <arnd@arndb.de>
Reported-by: Charan Teja Reddy <charante@codeaurora.org>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org>
Tested-by: Charan Teja Reddy <charante@codeaurora.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20200611114418.19852-1-sumit.semwal@linaro.org

Bug: 162699017

Signed-off-by: Allen Chiu <allen.chiu@mediatek.com>
Change-Id: Ief19296f201132c3e32b11958a857798c34f81fb
Git-commit: 2581e5be6555232e784487fc00961ce83c5236a1
Git-repo: https://android.googlesource.com/kernel/msm
Signed-off-by: PavanKumar S.R. <pavasr@codeaurora.org>
2021-10-18 12:32:23 +05:30
Anirudh Ghayal
1b2e4c4392 power: smb1398-charger: Toggle UVLO for Slave CP on USB removal
In addition to the master CP, toggle the UVLO config for slave CP
on USB removal to avoid poweroff-leakage.

Change-Id: I1f5d5185d003cfe104b4a67efc1fe88f105f0151
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>
2021-10-18 07:48:40 +05:30
Jilai Wang
48b897f215 msm: npu: handle system shutdown/reboot event properly
When system shuts down while there are work running on NPU,
NPUSS will be shut down without notifying kernel driver which
causes IPC commands timedout and triggers SSR handling.
This change is to detect this case and handle it properly
to avoid SSR.

Change-Id: I4ba6d702c2d39aa8e1894eba2ec049787df14aa8
Signed-off-by: Jilai Wang <jilaiw@codeaurora.org>
2021-10-17 19:14:20 -04:00
Linux Build Service Account
a9961fafc7 Merge d079ef6772 on remote branch
Change-Id: I111d0e2aa2bbc0661339f06e95ac257abeaddb46
2021-10-17 03:53:43 -07:00
qctecmdr
b43d06a654 Merge "USB: gadget: f_uvc: Enable more controls for CT and PU" 2021-10-13 23:26:24 -07:00
Patrick Daly
e29f5d1c4e dma-mapping-fast: Fix iova address leak with non-zero scatterlist offset
The underlying arm-smmu hardware only supports mapping addresses
aligned to PAGE_SIZE. Thus the actual mapped region may be larger than
the range returned by iommu_map_sg():

[sg_dma_address(), sg_dma_address() + sg->length)

When unmapping, ensure the same alignment requirements are applied
in order to avoid leaking iova addresses.

Change-Id: I1f5d5185d003cfe104b4a67efc1fe88f105f015f
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
2021-10-13 18:20:46 +05:30
Sarannya S
99ac515580 net: qrtr: Change error logging in callback
Print error logs in the callback by using pr_err_ratelimited
so that watchdog bark will not occur due to excessive logging
when the callback is triggered before probe is completed.

Change-Id: I82bb84b7812cef5cb8a37e99c5cf1a54411cbdb8
Signed-off-by: Sarannya S <sarannya@codeaurora.org>
2021-10-12 18:54:56 +05:30
qctecmdr
d079ef6772 Merge "net: qualcomm: rmnet: enable support for cksumv3" 2021-10-11 21:04:25 -07:00
qctecmdr
e53f9c37b1 Merge "usb: dwc3: dwc3-msm: optimize perf vote work" 2021-10-11 09:28:11 -07:00
Shilpa Suresh
9dd5d135be defconfig: Enable PMIC related configs for MSM8937_32
For MSM8937_32, add the configs related to charging,
vibrator and rtc.

Change-Id: I584a8520a9cd9344f72549a0bf62dc57ac9d8507
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-11 17:02:15 +05:30
Shilpa Suresh
53bda56b4f defconfig: Enable PMIC related configs for MSM8937_64
For MSM8937_64 targets, add PMIC configs related to
charging, vibrator and rtc.

Change-Id: I2891118f051ff9697aafcfa394940e1765fba2e4
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-11 16:56:46 +05:30
Shilpa Suresh
c4285df71f defconfig: Enable Charger/LED/RTC configs for MSM8937_32go
For MSM8937_32go, add the configs related
to charging, vibration and rtc.

Change-Id: I0f7ca9fab3eddff785c9c755daf15796973d0226
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-11 16:48:14 +05:30
Shilpa Suresh
874f7ea12c power: linear-charger: Report the correct battery status at SOC=0
Userspace initiates a shutdown if battery_status != charging
and SOC = 0, this is to prevent a deep-discharge of the battery
when the discharge current is higher than the charge current
at SOC = 0. Report this status from the kernel driver when
additionally the current voltage is below the cutoff threshold.

Change-Id: I89bb283ce9c0e01cd8c04cba2d7d33d5baca3fe7
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-11 16:40:23 +05:30
Shilpa Suresh
06b2ca9274 power: charger/fg: Add charger/fg/bms drivers for QM215
Add Charger/FG/BMS drivers qpnp-linear-charger.c, qpn-vm-bms.c,
smb1360-charger-fg.c and related files for QM215 target.
Add snapshots of the new files as of msm-4.9 commit 0848b3af1d2f
("ARM: dts: qcom: disabled wled bl type for sim_vid panel").

Change-Id: Ibc5d2a8daace8351020c53a9129fff9999f552da
Signed-off-by: Shilpa Suresh <sbsure@codeaurora.org>
2021-10-11 01:55:10 -07:00