Commit graph

590771 commits

Author SHA1 Message Date
Yimin Peng
f3d1cc36ef ARM: dts: msm: add LPASS smem nodes
This commit contains smem, smd and ipc router nodes.
They are necessary for LPASS debug by QXDM.

Change-Id: Id5184724da46997bbc4ec95dbbb4fa4f03f04567
Signed-off-by: Yimin Peng <yiminp@codeaurora.org>
2017-08-01 17:10:42 +08:00
Amit Blay
e8dcd44558 ARM: dts: msm: Add qseecom device node on msm8996 lfv platform
Add qseecom device node in guest VM configuration.
This commit adds the device node for the qseecom driver,
and also the reserved memory region for the QSEECOM ION heap.

Change-Id: Ibdf80d080208b5ab8530a1c40ecbccc7298ae89b
Signed-off-by: Amit Blay <ablay@codeaurora.org>
2017-07-31 02:31:55 -07:00
Arumuga Durai A
70817a0463 usb: bam: Remove inactivity_timer sysfs attribute
Sysfs attribute "inactivity_timer" not being used anymore so remove that
entry from sysfs.

CRs-Fixed: 2048725
Change-Id: I30d2d4a3cb9899b7975a6395eab90337fc006488
Signed-off-by: Arumuga Durai A <cadurai@codeaurora.org>
2017-07-27 22:57:43 -07:00
Linux Build Service Account
5bfe431e0a Merge "ARM: dts: msm: Add blsp1_uart2 on virtual platform." into dev/msm-4.4-8996au 2017-07-21 01:22:33 -07:00
Zhiqiang Tu
ccf9f16787 ARM: dts: msm: Add blsp1_uart2 on virtual platform.
Add blsp1_uart2 as pass through for bluetooth.

Change-Id: Ie8d0d2d92069a1e62a2967ef4b67c0b04890d314
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-07-21 09:17:12 +08:00
Zhiqiang Tu
27ebef6692 defconfig: arm64: enable HS-UART on virtual platform
HS-UART is enabled as pass through on virtual platform.

Change-Id: Ie110aea2e9cdec1029747a853c1f81d0a7846832
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-07-20 17:24:56 +08:00
Amit Blay
9e7a2e921b soc: qcom: SCM front-end over QCPE
This is an implementation of para-virtualized SCM driver.
This driver is the FE. The BE is QCPE running in an hypervisor.
The FE driver forwards SCM calls over HAB to the BE.

Change-Id: I88c269e856b0a6cc20b9ab8bf10110842d90a382
Signed-off-by: Amit Blay <ablay@codeaurora.org>
2017-07-17 08:21:17 -07:00
Linux Build Service Account
977260957b Merge "msm: kgsl: Use vma_area_struct with proper locks" into dev/msm-4.4-8996au 2017-07-17 04:01:39 -07:00
Linux Build Service Account
dd36e3bd56 Merge "input: synaptics_dsx: validate bounds of intr_reg_num" into dev/msm-4.4-8996au 2017-07-17 04:01:37 -07:00
Linux Build Service Account
a562982612 Merge "msm: camera: isp: Handle array out of bound access" into dev/msm-4.4-8996au 2017-07-17 04:01:35 -07:00
Linux Build Service Account
d0a0e91ce5 Merge "soc: qcom: glink: Remove magic number logic" into dev/msm-4.4-8996au 2017-07-17 04:01:34 -07:00
Sunil Khatri
988d8f6e83 msm: kgsl: Use vma_area_struct with proper locks
Make sure to use proper locks when using the
vma_struct_area. This will avoid the race condition
in a scenario where one thread gets a vma_struct_area
and other thread is unmapping the vma from the process.

Change-Id: I6c7837d1a8dd24fc6955ab5be8b1917a42f2cb53
Signed-off-by: Sunil Khatri <sunilkh@codeaurora.org>
2017-07-17 03:47:56 -07:00
Andrew Chant
85eadde1c4 input: synaptics_dsx: validate bounds of intr_reg_num
Validate the intr_reg_num value returned by touchscreen
to ensure no out of bounds access can occur.

Bug: 35472278
Change-Id: I22f5b67815fe7d448b5ed847e4e3d65af63bed84
Signed-off-by: Andrew Chant <achant@google.com>
Git-repo: https://android.googlesource.com/kernel/msm
Git-commit: 271baca849983ef309e82a4e5953027790f36154
Signed-off-by: Dennis Cagle <dcagle@codeaurora.org>
Signed-off-by: Shantanu Jain <shjain@qti.qualcomm.com>
2017-07-17 03:47:04 -07:00
Sriraj Hebbar
9e50d6c84d msm: camera: isp: Handle array out of bound access
The index obtained from pointer req_frm can lead to indexing
stream_info beyond its boundary. Therefore, a bound check has been
included to avoid this.

CRs-fixed: 2008683
Change-Id: I8682e09ff2ab7ba490bbbd9e20db978493c5f3e4
Signed-off-by: Senthil Kumar Rajagopal <skrajago@codeaurora.org>
Signed-off-by: Terence Ho <terenceh@codeaurora.org>
Signed-off-by: Andy Sun <bins@codeaurora.org>
2017-07-17 03:45:38 -07:00
Dhoat Harpal
5721d43e0b soc: qcom: glink: Remove magic number logic
Possible use after free issue while accessing magic number,
if the ctx is already freed.

Magic number check is removed.

CRs-Fixed: 2061287
Change-Id: Ie157a930c7eb310829766319e0af742114337e6c
Signed-off-by: Dhoat Harpal <hdhoat@codeaurora.org>
2017-07-17 03:17:17 -07:00
Manoj Prabhu B
6554f41fcb diag: dci: Add NULL pointer checks for dci buffers
The patch initializes dci peripheral buffers to NULL
to prevent access before allocation by validating buffer status.

CRs-Fixed: 2048635
Change-Id: I9be46e751da81cbbbae4fe0333c23101fdbf79ed
Signed-off-by: Manoj Prabhu B <bmanoj@codeaurora.org>
2017-07-17 03:10:49 -07:00
Linux Build Service Account
0530e3fe60 Merge "msm: camera: Use mutex lock to avoid race condition" into dev/msm-4.4-8996au 2017-07-16 07:48:43 -07:00
Linux Build Service Account
390fdea245 Merge "msm: camera: Use mutex lock to avoid race condition" into dev/msm-4.4-8996au 2017-07-16 07:40:24 -07:00
Krupal Divvela
652c891263 msm: camera: Use mutex lock to avoid race condition
Use mutex lock before using queuing ioctls like
queuing, dequeing buffers to avoid race condition.

CRs-Fixed: 2038086
Change-Id: Ia9fdfd5a766add2f8d99003b0c2bfe7d34d57a09
Signed-off-by: Krupal Divvela <kdivvela@codeaurora.org>
Signed-off-by: annamraj <annamraj@codeaurora.org>
Signed-off-by: VijayaKumar T M <vtmuni@codeaurora.org>
2017-07-13 00:39:57 -07:00
Zhiqiang Tu
b1caec8793 defconfig: arm64: msm: Enable PCI on virtual platform
Enable PCI and PCI_HOST_GENERIC on virtual platform.

Change-Id: Ifc9e2b34cc877ad9907811444de9a4577c9f62ec
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-07-12 23:05:41 -07:00
Linux Build Service Account
9d6dcc6f51 Merge "msm: ipa: add L2TP/VLAN messaging" into dev/msm-4.4-8996au 2017-07-12 20:23:00 -07:00
Vinayak Menon
045900c901 arm64: dma-mapping: fix aliasing issues with non-CMA alloc
Cache flush and clearing of logical mapping is done right now
only when the allocation is from CMA, for allocation requests
with DMA_ATTR_STRONGLY_ORDERED or DMA_ATTR_NO_KERNEL_MAPPING
set. Extend this to non-CMA allocations too, to avoid cache
aliasing issues.

Change-Id: I133d34d79665ee7159fe384121e933d7768748c2
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2017-07-12 20:10:46 -07:00
Shihuan Liu
cf2f223c28 msm: ipa: add L2TP/VLAN messaging
Add L2TP/VLAN messaging support in IPA driver
Conflicts:
	include/uapi/linux/msm_ipa.h

Change-Id: Ifce9adb1eb1946a2000f54933f1990747fe7daef
Acked-by: Shihuan Liu <shihuanl@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
2017-07-12 19:26:36 -07:00
Linux Build Service Account
9356b9c45f Merge "msm: isp: camera: Avoid potential out of bound write" into dev/msm-4.4-8996au 2017-07-12 14:02:59 -07:00
Yimin Peng
61ac0efa23 ARM: dts: msm: Enable modem over virtual platform.
Add devices needed for modem.

Change-Id: I513c388df7dabec9ee1eb0b74af5d76cec261be5
Signed-off-by: Yimin Peng <yiminp@codeaurora.org>
2017-07-11 02:23:59 -07:00
Yimin Peng
79d3d06f2e defconfig: arm64: msm: Enable modem pass through on virtual platform
Add support to modem on virtual platform.

Change-Id: I0737efca335f695230ebc5f8aaec61778dfc1581
Signed-off-by: Yimin Peng <yiminp@codeaurora.org>
2017-07-11 02:19:21 -07:00
Yimin Peng
6b21fd9ece scm: fix potential build error.
References to the header file may cause multi definition.

Change-Id: Iccac423a5906f2493b33b34fd698324138ce9bcb
Signed-off-by: Yimin Peng <yiminp@codeaurora.org>
2017-07-11 02:18:13 -07:00
Venu Yeshala
f7de988aaf msm: isp: camera: Avoid potential out of bound write
Check the validity of VFE interface parameter that is
provided from userspace.

Change-Id: I0ebb95c824ab3f832aaf500a6655829cca846c3d
Signed-off-by: Venu Yeshala <vyeshala@codeaurora.org>
2017-07-09 19:38:49 -07:00
Terence Ho
dff0e346e3 msm: camera: Use mutex lock to avoid race condition
Use mutex lock before using queuing ioctls like
queuing, dequeing buffers to avoid race condition.

Change-Id: I59c70f2abe3daddf38761a2f17671d3d49f43989
CRs-fixed: 2038086
Signed-off-by: Terence Ho <terenceh@codeaurora.org>
2017-07-09 19:37:24 -07:00
Linux Build Service Account
3610841a51 Merge "msm: camera: validate num_streams in stream_cfg_cmd before using it" into dev/msm-4.4-8996au 2017-07-07 17:38:05 -07:00
Abdulla Anam
0cf490e7c6 msm: vidc: Allocate memory dynamically for debugfs info_reads
Use dynamically allocated memory for constructing strings in
core_info_read & inst_info_read. This ensures that there is no
contention for a shared memory & hence avoids the requirement of
a lock. Allocate on demand, as the calls implement a debugfs
facility and hence rarely invoked. Statically allocated memory
otherwise remain idle.

Change-Id: I3ae04e0a51801a2fc901591e41e28ff6b7d198b4
Signed-off-by: Abdulla Anam <abdullahanam@codeaurora.org>
2017-07-07 17:16:07 -07:00
Terence Ho
9dc644af56 msm: camera: validate num_streams in stream_cfg_cmd before using it
stream_cfg_cmd->num_streams is from userspace,
need to check it against MSM_ISP_STATS_MAX before using it.

CRs-Fixed: 2029867
Change-Id: I02a71b983947981806470454654d712bcc732077
Signed-off-by: Terence Ho <terenceh@codeaurora.org>
2017-07-07 15:30:22 -07:00
Linux Build Service Account
3258c68559 Merge "msm: camera: fix untrusted pointer for power down setting" into dev/msm-4.4-8996au 2017-07-07 15:29:00 -07:00
VijayaKumar T M
5c0e1f4016 msm: camera: fix untrusted pointer for power down setting
When getting power down setting, there is an untrusted pointer
from a user space pointer. Need to copy to the kernel space first.

CRs-Fixed: 2037398
Change-Id: I64032a96e62ddfeec85eebe984d8ba52754f6148
Signed-off-by: Haibin Liu <haibinl@codeaurora.org>
Signed-off-by: VijayaKumar T M <vtmuni@codeaurora.org>
2017-07-07 14:57:17 -07:00
Terence Ho
dd76644c6c msm: camera: fix untrusted pointer for power down setting
When getting power down setting, there is an untrusted pointer
from a user space pointer.Need to copy to the kernel space first.

Change-Id: I0c66e942453581caac5ea00a54a252840a32972f
CRs-Fixed: 2037398 2037403
Signed-off-by: Terence Ho <terenceh@codeaurora.org>
2017-07-07 14:56:57 -07:00
Linux Build Service Account
87dfd9682c Merge "msm📷 correct stats query out of boundary" into dev/msm-4.4-8996au 2017-07-07 12:04:01 -07:00
Fei Zhang
54105d3ed6 msm📷 correct stats query out of boundary
fix one potential out of boundary query of stats info.

CRs-Fixed: 2041066

Change-Id: I13e4bf8802fcce529f9268c272e4727619d5ad8f
Signed-off-by: Fei Zhang <feizhang@codeaurora.org>
2017-07-07 11:47:06 -07:00
Fei Zhang
735884bc87 msm📷 correct stats query out of boundary
Fix a potential out of boundary query of stats info.

CRs-Fixed: 2041066
Change-Id: I76d4aa8c8ddd523fde007bfb6fa387a17930c2ba
Signed-off-by: Fei Zhang <feizhang@codeaurora.org>
2017-07-07 11:29:43 -07:00
Zhiqiang Tu
3f5f639b13 defconfig: arm64: msm: Enable pass through on virtual platform
Enable basic modules on virtual platform for driver pass through,
including pinctrl, gpio, clock, regulator, i2c, spi etc.

Change-Id: I3d4917e754277e0c55c55154a2ddb2f967199b48
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-06-26 22:02:18 -07:00
Linux Build Service Account
1ce84084dc Merge "defconfig: arm64: msm: Enable virtual platform" into dev/msm-4.4-8996au 2017-06-26 21:39:08 -07:00
Linux Build Service Account
18e7648d41 Merge "iommu: Fix compilation errors without CONFIG_IOMMU_API" into dev/msm-4.4-8996au 2017-06-26 21:39:06 -07:00
Zhiqiang Tu
b0b763bf53 ARM: dts: msm: Add spi_9 and i2c_8 on virtual platform
Add spi_9 and i2c_8 as pass through devices.

Change-Id: I6ccd161eee69ffa062bcb1763eebfe7a4db331ec
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-06-26 21:22:36 -07:00
Atul Raut
88dc521fe6 defconfig: arm64: msm: Enable virtual platform
Add support to build msm kernel based virtual
machine.

CRs-Fixed: 2000635
Change-Id: I76f4920a86adc8bac347c1c6c360ef55f84bc453
Signed-off-by: Atul Raut <araut@codeaurora.org>
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-06-24 07:44:17 -07:00
Patrick Daly
b9e9d37141 iommu: Fix compilation errors without CONFIG_IOMMU_API
Move code into appropriate #ifdef, and add an "inline" so the compiler no
longer gives a defined-but-not-used warning.

CRs-Fixed: 2066432
Change-Id: I226242bf994e659d8018a885f20c3a3f80b9b8e5
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
Signed-off-by: Atul Raut <araut@codeaurora.org>
2017-06-23 23:04:05 -07:00
Linux Build Service Account
6fb998c41a Merge "ARM: dts: msm: Add clock and regulator for virtual platform" into dev/msm-4.4-8996au 2017-06-23 01:47:23 -07:00
Zhiqiang Tu
e1ec43ff6d clk: msm: Add fixed rate clock support for dummy clock driver
Virtual platform uses dummy clock driver. It needs dummy clock
driver to support fixed rate clock.

Change-Id: Id0f6ce592447a443c22ad49fddeaa598cf3d047e
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-06-22 21:31:37 -07:00
Zhiqiang Tu
ca6aa324be ARM: dts: msm: Add clock and regulator for virtual platform
Add dummy clock and regulator stub for virutual platform to
bypass clock and regulator operations.

Change-Id: Ic2c15e4b939adc0ea492422c93e3f3eac2d01054
Signed-off-by: Ramachandran Venkataramani <ramavenk@codeaurora.org>
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-06-22 21:30:56 -07:00
Atul Raut
7350d1ad72 arm64: Kconfig: Enable support for guest virtual platform
Enable support for msm kernel based guest virtual machine
runs on QUIN platform.

CRs-Fixed: 2024587
Change-Id: If6b26ca5180f3a148a54c6f8980d4efbb65ab2a9
Signed-off-by: Atul Raut <araut@codeaurora.org>
2017-06-15 09:58:13 -07:00
Robin Murphy
eb7038b13a iommu/dma: Remove bogus dma_supported() implementation
Back when this was first written, dma_supported() was somewhat of a
murky mess, with subtly different interpretations being relied upon in
various places. The "does device X support DMA to address range Y?"
uses assuming Y to be physical addresses, which motivated the current
iommu_dma_supported() implementation and are alluded to in the comment
therein, have since been cleaned up, leaving only the far less ambiguous
"can device X drive address bits Y" usage internal to DMA API mask
setting. As such, there is no reason to keep a slightly misleading
callback which does nothing but duplicate the current default behaviour;
we already constrain IOVA allocations to the iommu_domain aperture where
necessary, so let's leave DMA mask business to architecture-specific
code where it belongs.

Signed-off-by: Robin Murphy <robin.murphy@arm.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Git-commit: a1831bb9403720db6d4c033fe2d6bd0116dd28fe
Git-repo:git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git

CRs-Fixed: 2040683
Change-Id: I67431608ce196bf5ca981fb9aea2afce826094f0
Signed-off-by: Atul Raut <araut@codeaurora.org>
2017-06-13 21:48:56 -07:00
Zhiqiang Tu
d992f38d6d Merge remote-tracking branch 'remotes/quic/msm-4.4' into dev/msm-4.4-8996au
Conflicts:
	arch/arm64/configs/msm-auto-perf_defconfig

Change-Id: Ibc59804762c3e14031c22b03a52d49ff2acc36d4
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
2017-06-12 15:40:13 +08:00