IPA-driver needs to config ep metadata with
embedded call QMAP_ID which IPACM will pass.
The fix is have right qmap_id configure in ep
metadata.
CRs-Fixed: 991570
Change-Id: I0a9549a5c30f53c75fd9ff961ae5dcdc0741c866
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
Signed-off-by: Ghanim Fodi <gfodi@codeaurora.org>
LED switch node operations are invoked both from LED trigger framework
callback and LED work thread. As work thread and LED trigger framework
operations are asynchronous, a race condition occurs when back-to-back
operations happen. Therefore, moving LED switch node operations from
LED trigger framework callback to work thread to eliminate race condition.
Change-Id: Ia962f3aebda9162e3a35773ef3ee27a4434e6d0c
Signed-off-by: Chun Zhang <chunz@codeaurora.org>
The system secure heap now uses page pooling. As a result, free
operations are fast, since hyp_unassign is not necessary.
Change-Id: I8da8f5adb32c089d5dcac0e560e305401d69fdc9
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
Clients may wish to implement custom functions on a particular
heap ID. That function assumes that the heap ID has a specific heap
type. Make that requirement explicit by only calling the custom
function if both the ID and type match.
Change-Id: Ie746362a19a22dceb6e47148d67901d483778a85
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
ion_page_pool_alloc, the only API available to allocate pages from the
pool will request pages from the system if the pool is empty.
For some pools, we need to allocate pages only from the Pool and this patch
provides that functionality.
Change-Id: Ibe4ffe1e8b352f1c9e9a6ad7cc5d31792abc5a66
Signed-off-by: Rohit Vaswani <rvaswani@codeaurora.org>
The __pm_stay_awake/relax() calls were moved to runtime callbacks as a
means to fix data loss due to race conditions between incoming userspace
commands and executing PM related callbacks.
However calling the __pm_relax (to notify wakeup event processing)
as part of the runtime suspend callback could be race prone between
the system suspend and the runtime framework. If the system suspend
gets to run before the runtime callback, the wakeup event will block
system suspend.
Remove the use of the wakeup source altogether, instead do these:
1. Block system suspend based on the current clk request count and the
RPM state of the device (to detect potential inbound userspace
requests).
2. If the driver is in the process of executing the system suspend
callback, ignore any userspace requests.
3. If the client calls a shutdown without an unvote ioctl, zero out
the client_count vote forcefully to allow suspend.
CRs-Fixed: 977421
Change-Id: I17de85f29b555c1a4563dd59bec3ba3084c3604f
Signed-off-by: Girish Mahadevan <girishm@codeaurora.org>
Add VMEM slave nodes and associated mmss maxi and axi clocks.
CRs-Fixed: 988418
Change-Id: I36ed4051615f781ff5316c033ba2ff8de96e891e
Signed-off-by: David Dai <daidavid1@codeaurora.org>
Subsystem ramdump collection as of now happen segmentwise, but sometime
there are hole in between segment where dynamic image is loaded and
which need to be captured during subsystem ramdump collection.
This change will dump complete subsystem memory rather than only segments
based on the configuration of subsystem who desire it.
Change-Id: I5075a90817d1a4d00d69ad39d892dbbc40b0b0dc
Signed-off-by: Avaneesh Kumar Dwivedi <akdwived@codeaurora.org>
Currently, whenever new dci client registers, diag
allocates memory from kernel and free it during
de-initialization. For one of the buffer, it is not
freeing the memory which will lead to memory leak.
This patch takes care of possible memory leak.
Change-Id: Ie50b4a549c249375f93962a5b6b20d614943f1aa
Signed-off-by: Mohit Aggarwal <maggarwa@codeaurora.org>
We've exhausted all of the 64 dynamic minor numbers in misc
devices. Ideally, we shouldn't be using so many misc devices. We
should be using cdev directly instead. Increase the number for
now so that kernel drivers don't fail to probe.
Change-Id: I514f4acc7d27b68005ec7f0a8d4ab3c0906b36ff
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
kgsl_mem_entry_attach_process() adds new entry to the mem_idr list
without really having a valid GPU address.
This new entry can be used by other thread with GPUADDR_IN_MEMDESC()
and destroy it.
Get GPU address first and then add it to the mem_idr list.
Change-Id: I4d66cec754ca5315df3c9fe09644f55596c3c33c
Signed-off-by: Rajesh Kemisetti <rajeshk@codeaurora.org>
ETM parser expects ETM trace ids starting from 0x1.
This change fixes the start of ETM trace id to make it compatible with
ETM parser.
Change-Id: Icc5c6de317468b845448dae22a447e8b9a82ea54
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Add code to support ETM initialization when CPU comes online for
the first time.
Change-Id: I4a7c02cb71c3bd0ffa01586bed28950067e1f604
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Some TPDMs require to program MSR registers after enabling the DSB
subunit.
This change adds support for such TPDMs.
Change-Id: Iff5c1d73f752c8f9ff483e37cf65f9fe8e2901ca
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Update device tree binding information for STM, CTIs, TPDA and TPDM
devices.
Change-Id: I441086199c80d2952ae418cdeafc7b05df650b4f
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Add support to configure mux select registers for all subunits.
These registers can be used to select different trace events supported
by a subunit.
Change-Id: I5d5236e4c0cb94e401dfe82eeb91e8fe7e3c566b
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Add TPDM and TPDA devices for msmcobalt target. These devices can be
used to trace various hardware components.
Change-Id: I1f9316636a11794d89ea81cf99a0fba7d77c9c96
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Add TPDM and TPDA drivers in upstream implementation of Coresight driver.
This change copies coresight-tpdm.c and coresight-tpda.c files from
drivers/coresight (commit : a8371783eed42f9e1ce9cecc1e3d5fba94f05014)
to driver/hwtracing/coresight directory.
Change-Id: I8a518de3f0ab0e4b0880c5ca00d90a012234a91c
Signed-off-by: Shashank Mittal <mittals@codeaurora.org>
Certain configurations may require nested translation, but may
want to avoid software performance limitation on map/unmap
operations.
Change-Id: I69bed6cc9d801709849ebc91b76d2a9d6649865a
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
This reverts commit 5642406b6c3e
("iommu/arm-smmu: add DT option to avoid enabling translations on attach")
This device tree option is obsolete. Remove it.
Change-Id: I6fc2e3127295b9b597acc21ef5d6b1f78519de68
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
The MMSS GDSC should only be disabled during the XO
shutdown path on MSMCOBALT. There is no need to
explicitly support it in linux since it should be
left enabled by RPM.
Change-Id: I0e2cdf1e6026553a53f176dc10810b10b596e67e
CRs-Fixed: 988307
Signed-off-by: Deepak Katragadda <dkatraga@codeaurora.org>
Add tert tdm sleep and active pinc ctrl calls for
msm8996 Agave. BE dai that uses tert tdm will enable
the required gpios associated to tert mi2s.
CRs-fixed: 988459
Change-Id: I079da664cd331ec87b3a4e488fc4f9e8c58a9439
Signed-off-by: Derek Chen <chenche@codeaurora.org>
This reverts commit 022c1f3696f2 ("debug-pagealloc:
Panic on pagealloc corruption"). Kernel panic is seen
on MSM8937 with 32 bit mode, revert this patch till
root cause is identified.
Change-Id: I66f1bab7f8c836b8b7167ec05141656f34c3702c
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
Kernel throws a warning when space is used in memory cache name.
Make changes to use _ instead of space when creating
memory cache. Also make change to handle -ENODEV from IPCRTR
during SSR.
Change-Id: Ia34a5fb16bb4a5e95cc042b7fd5b152119520787
Acked-by: Chaitanya Pratapa <cpratapa@qti.qualcomm.com>
Signed-off-by: Ravinder Konka <rkonka@codeaurora.org>
Initialize PinCtrl Framework for SDIO platforms to support antenna
sharing.
The antenna sharing is enabled only for platform which has PCIe QCA
and SDIO QCA chipsets.
CRs-Fixed: 990796
Change-Id: Ib3da0ce52ef46deae2ba49e4f39808effe18457d
Signed-off-by: Komal Kumar <kseelam@codeaurora.org>
Track number of active context and pass it to governor along
with busy stats. This allows GPU DCVS to make decision based
on context count and busy stats, which helps in handling sudden
workloads.
Change-Id: I9b40e4917b30ee3f15f2c8e99669e090578f1289
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
Signed-off-by: Divya Ponnusamy <pdivya@codeaurora.org>
Add support to use context aware dcvs, if it is supported
by TZ. Context aware dcvs helps in handling sudden workload
scenarios.
Change-Id: I5e6e6003a5c61eacb4f5af91910994919a5a7684
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
Signed-off-by: Divya Ponnusamy <pdivya@codeaurora.org>
Cipher was sometimes not treated properly, causing valid
requests belonging to eCryptfs to be treated as regular.
Change-Id: Iabfb93cc4c9e9e167901043482eb99613ed70343
Signed-off-by: Andrey Markovytch <andreym@codeaurora.org>
Signed-off-by: Gilad Broner <gbroner@codeaurora.org>
Make sure there are no stale tlb entries when
dma_unremap returns, thus preventing speculative
fetches.
Change-Id: I22070de282f25fe5ea20177e67a6d629123e29a4
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
Signed-off-by: Ramesh Gupta Guntha <rgguntha@codeaurora.org>
A few clocks like gpu_ahb_clk may be available late on some platforms
like on boards that use an I2C-controlled off-SoC power regulator.
Defer SMMU probe if clock-tree is not ready.
CRs-fixed: 971957
Change-Id: I3f13b36affa0a904bda7175d0dacff298794a906
Signed-off-by: Mathew Joseph Karimpanal <mkarim@codeaurora.org>
Update the VDD_APC0 and VDD_APC1 CPR supported corners along
with their ceiling and floor voltages. In addition, increase
the APM threshold voltage to 852 mV in agreement with the
latest hardware guidelines.
Change-Id: I62cb18f79ecfd6b3270eabeebb5eedddf59e6174
CRs-Fixed: 988269
Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
Stream based lock needed in all vb2 ops to avoid any
invalid access in vb2 queue when hal triggers ioctl in
multiple thread context.
CRs-Fixed: 986029
Change-Id: Idcbef3db5c2bd04005b0832049b5dee00c4cf96b
Signed-off-by: Hariram Purushothaman <hariramp@codeaurora.org>
Stream based locks used in qbuf, dqbuf, reqbus.
Old session based locks are removed.
CRs-Fixed: 986029
Change-Id: I30788f9248bea67e560d1a602e8feadfde6c2691
Signed-off-by: Ramesh V <ramev@codeaurora.org>
Signed-off-by: Hariram Purushothaman <hariramp@codeaurora.org>
Add new fields to MHI channel scratch according to MHI spec.
CRs-Fixed: 990237
Change-Id: I36476b8a24b2a1b3bc55fa5832404bb106d810ec
Acked-by: Ady Abraham <adya@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
Remove the usage of ul_dl_sync field in IPA MHI driver as this
is no longer in use.
CRs-Fixed: 990233
Change-Id: I7295da05664e72aa1b9120f7bc475f92addc095b
Acked-by: Ady Abraham <adya@qti.qualcomm.com>
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
Patch to check the parameters before usage.
CRs-Fixed: 981826
Change-Id: Ib27076507477f3949063963db503f734c49ab591
Signed-off-by: Azam Sadiq Pasha Kapatrala Syed <akapatra@codeaurora.org>
For MSMs, the IPA FWs (GSI FW/MCS, HPS and DPS) will be
loaded via a secure PIL process.
Change-Id: Ie3c3c46d52921e558e926ec2be57a885e04c924d
CRs-Fixed: 970340
Acked-by: David Arinzon <darinzon@qti.qualcomm.com>
Signed-off-by: Sivan Reinstein <sivanr@codeaurora.org>
Define the OSM and XO clock rates necessary for performance
estimation using the OSM cycle counter. These parameters vary
based upon the platform.
Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
CRs-Fixed: 987865
Change-Id: I721dc3488484b66e3f88cbebf626e88176f08a44
Remove 1.4976 GHz and 1.0944 GHz as supported DCVS set points
for the power and performance clusters, respectively.
Change-Id: I4c59825521a6f3f8738623363eec6c4bc8b5d8cc
CRs-Fixed: 990552
Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
Add common api support of subsystem restart and bus
bandwidth for dual wifi. This feature redirect the cnss
export api according to the bus type SDIO/PCI.
CRs-Fixed: 986275
Change-Id: Iaf13d6c6d68ef62b7e4f6581899ec8325c5e9696
Signed-off-by: Sarada Prasanna Garnayak <sgarna@codeaurora.org>
vmstat events currently count pgpgout, but that includes
only the writebacks, and not the reclaim of clean
pages. Add an event to count clean page evictions. This is
helpful to evaluate page thrashing cases.
Change-Id: Icfb797877a544a58c289074bdc290dfbc1384514
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
When vfe is halted, an overflow signal could be generated that
has side effects. Turn off this signal when halting vfe. Also,
disable interrupts when halting the vfe due prevent other side
effects.
CRs-Fixed: 953865
Change-Id: I706d796c500db4a201149196d7ed15965c0b1bb7
Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
This patch rate limit few of the error logs to avoid flooding
of kernel logs.
Change-Id: I11843becf1d3ae97d5e433198ae27afd0237ed82
Signed-off-by: Katish Paran <kparan@codeaurora.org>
Allocate guard page when the first buffer is
mapped into the IOMMU. This also ensures that
the guard page gets allocated if the guard page
mmu feature is enabled.
CRs-Fixed: 988093
Change-Id: Id97492707463a1f15a4bf1c67b9c0f03214e6283
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
Earlier video driver maintains list of fds and compare
each ETB fd with these values. If the fd is found then
mapping is retained. But in some usecases, buffer address
and fd association may not be unique. This resuts in
usage of stale buffers. This is also not the true dynamic
buffer mode. With this change, driver treats every buffer
as new buffer and map and unmap each time.
CRs-Fixed: 989007
Change-Id: Ice90c745d4920b64c48c3f4dafca789f2551b327
Signed-off-by: Praneeth Paladugu <ppaladug@codeaurora.org>
Current fbdev rotator interface lacks support for mult-context
use cases. This new interface adopts V4L2 M2M framework to
support multiple concurrent sessions/contexts efficiently.
CRs-Fixed: 972831
Change-Id: I89593a57ba44e91c95d73154a7830539e5aab6e3
Signed-off-by: Alan Kwong <akwong@codeaurora.org>
It's sometimes useful to know the physical address which
has beencorrupted, especially in systems with multiple
bus masters and DMA engines the capability of writing
to memory. It's may also be useful for identifying the
location of failures of memory cells in cases of
device-specific corruption. So print the physical
start address of the page to help in these scenarios.
Change-Id: I081edd8b1c06913c0057a6cb9dda18077cfbdc30
Signed-off-by: Matt Wagantall <mattw@codeaurora.org>
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
To support new v4l2 rotator driver, rotator smmu domains in
MDSS driver will be enabled based on device tree boolean setting.
This allows smmu to be associated with MDSS driver or external
rotator driver for MDS block, such as 3.0.0 onward, with a
separate rotator block, or for MDSS block, pre 2.0.0, with
built-in writeback rotator.
CRs-Fixed: 973961
Change-Id: I68ac7b1b89485d1ce46bdb1c1739c3306a7d7d89
Signed-off-by: Alan Kwong <akwong@codeaurora.org>
[dkeitel@codeaurora.org: fixed minor whitspace conflict.]
Signed-off-by: David Keitel <dkeitel@codeaurora.org>