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>
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>
Enable PCI and PCI_HOST_GENERIC on virtual platform.
Change-Id: Ifc9e2b34cc877ad9907811444de9a4577c9f62ec
Signed-off-by: Zhiqiang Tu <ztu@codeaurora.org>
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>
References to the header file may cause multi definition.
Change-Id: Iccac423a5906f2493b33b34fd698324138ce9bcb
Signed-off-by: Yimin Peng <yiminp@codeaurora.org>
Check the validity of VFE interface parameter that is
provided from userspace.
Change-Id: I0ebb95c824ab3f832aaf500a6655829cca846c3d
Signed-off-by: Venu Yeshala <vyeshala@codeaurora.org>
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>
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>
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>
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>
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>
fix one potential out of boundary query of stats info.
CRs-Fixed: 2041066
Change-Id: I13e4bf8802fcce529f9268c272e4727619d5ad8f
Signed-off-by: Fei Zhang <feizhang@codeaurora.org>
Fix a potential out of boundary query of stats info.
CRs-Fixed: 2041066
Change-Id: I76d4aa8c8ddd523fde007bfb6fa387a17930c2ba
Signed-off-by: Fei Zhang <feizhang@codeaurora.org>
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>
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>
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>
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.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
CRs-Fixed: 2040683
Change-Id: I67431608ce196bf5ca981fb9aea2afce826094f0
Signed-off-by: Atul Raut <araut@codeaurora.org>
Host wlan driver needs to know if the drive has been
reloaded and wiphy re-registered with the kernel.
Therefore add APIs to retrieve this information.
CRs-Fixed: 2058292
Change-Id: Ia323e31e9b6779e2f5279f42b6e1860a9259a189
Signed-off-by: Amar Singhal <asinghal@codeaurora.org>