Callbacks with the backing dma fences are not registered
for composite (merged) synx objects.
Hence added check to exclude dma fence removal for the
merged objects during cleanup.
Also, the check for the synx object status is moved prior
to dma fence callback removal as any attempts to re-signal
a signaled object does not attempt to remove dma fence
callback again.
Change-Id: Idbbdf1d813ed1099d35044d2e454d60017fe172a
Signed-off-by: Sumukh Hallymysore Ravindra <shallymy@codeaurora.org>
Certain GPIOs are reserved for secure world and cannot be accessed by HLOS.
Supply "reserved_gpios" to msm_pinctrl to mark these pins as invalid.
Change-Id: Ic8f45181b2210a6295bba1bdec45d24e607bede9
Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>
Update pinctrl configuration for Shima, to match the
latest released configuration.
Change-Id: I1537735755e1a0384a9c48dca6184a85b49b2237
Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>
There is a possibility of client driver's dev_wake request
as part mhi_device_get() racing with M1 state transition
event processing. This can result in a scenario where client
finds MHI state as M0 after mhi_device_get() returns only to
be changed later as M1 event processing is still pending on
different CPU core.
It causes M0 -> M2 -> M0 state transition after mhi_device_get()
has already returned. This isn't expected by client and currently
treats that as fatal error. Also, as per MHI spec host must allow
M1 -> M2 transition for device and it shouldn't abort that.
However, clients can ignore that transition as device is expected
to immediately move from M2 to M0 without entering deep sleep
state. Hence, it must be safe to access their MMIO.
To simplify this logic, introduce mhi_device_get_sync_atomic()
function that can be used by clients to achieve the same and once
it returns success they don't need to have any explicit MHI state
checks.
Change-Id: I0b4a1ad723a0444ee2402bf171fc5ffc46afcdce
Signed-off-by: Manu Gautam <mgautam@codeaurora.org>
The sleep/wake state batch requests are saved in a linked list and
flushed along with other sleep/wake request when entering system low
power modes. Caches are flushed only if the state flag is marked dirty.
A race situation could cause the batch sleep/wake requests to not be
flushed. Here is how this could happen -
- Interconnect driver (ICC) invalidates the sleep/wake requests
- RSC driver clears the TCSes (BCM, VRM, ARC sleep votes cleared)
- ICC sends an active state response-required request
- RSC driver sends the AMC request
- RPMH waits on the response, calls wait_for_completion
- Scheduler schedules idle thread
- cpuidle enters cluster idle state
- RPMH flushes cache and marks cache clean
(no BCM votes in TCS)
- RSC driver receives IRQ response
- RPMH calls complete()
- ICC worker thread resumes execution
- ICC driver calls RPMH driver with updated sleep and wake votes
- RPMH caches the request, *cache is NOT marked dirty*
- Scheduler schedules idle thread
- cpuidle enters cluster idle state
- Cache is clean and nothing to flush
- CPU enters idle
=>ICC sleep/wake votes are not sent
Fix this by dirtying the cache state even when caching batch requests.
Change-Id: I7613e665d181f8abb27915d622442e7b981f9fcc
Signed-off-by: Lina Iyer <ilina@codeaurora.org>
Add check to restrict index underflow.This is to avoid
that it does not access invalid index.
Change-Id: Ib971033c5820ca4dab38ace3b106c7b1b42529e4
Acked-by: Gururaj Chalger <gchalger@qti.qualcomm.com>
Signed-off-by: Mohammed Nayeem Ur Rahman <mohara@codeaurora.org>
Add support for the primary vm to read the vm peer name from device
tree. This information is needed to share memory to the peer vm.
Change-Id: Ied71d254975e08dcf6c1c51f49687aceced141a9
Signed-off-by: Chris Lew <clew@codeaurora.org>
Store the haven label so it can be used for other haven resources such
as attaching the label to memparcels that the qrtr haven driver
creates.
Change-Id: I78c8bea71666c35db393191131389867d39f7566
Signed-off-by: Chris Lew <clew@codeaurora.org>
Dump PA_VS_STATUS_REG1 when full reset is needed in eh, which is helpful
for error debugging.
Change-Id: Iad3c2fc09c88598428762b5da09e13b46493fc7d
Signed-off-by: Can Guo <cang@codeaurora.org>
Enable support to limit the allocations which can be made from the
Movable zone in order to help reduce the likelihood of a page in the
movable zone being pinned because that would prevent memory from
being offlined.
Change-Id: I6503c9c23ad4b54838992a72f0cf79f3f545d703
Signed-off-by: Liam Mark <lmark@codeaurora.org>
There are a lot of readahead Movable allocations.
These allocations don't appear to get 'pinned' so allow them to be
satisfied from the CMA region in order to better utilize CMA memory.
Change-Id: I87387a748e67a6963b9a526b729e6e273c1cc519
Signed-off-by: Liam Mark <lmark@codeaurora.org>
Ensure we continue to direct __GFP_CMA allocations to offlinable memory now
that __GFP_OFFLINABLE has been introduced.
Change-Id: Ibdd71e45f4e47110f3ec4d308d26ffae58beb300
Signed-off-by: Liam Mark <lmark@codeaurora.org>
Ensure that only allocations which include __GFP_OFFLINABLE can be
satisfied from zone Movable. This restriction helps reduces the
likelihood of a page in the movable zone being pinned which would prevent
memory from being offlined.
In the past we allowed all __GFP_CMA allocations to be satisfied from
Movable zone but now add support to differentiate between __GFP_CMA
allocations and __GFP_OFFLINABLE allocations so that we can target certain
allocations at CMA regions and certain allocations at the Movable zone.
Change-Id: If2a9381b6d677f825ad53af9cd64f206d41da211
Signed-off-by: Liam Mark <lmark@codeaurora.org>
Enable SDPM clock monitor driver for lahaina to monitor clocks and write
the clock rate in SDPm CSR register.
Change-Id: Ia643c5b412362518c9c6c08d47e5af17ff859f69
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
Enable Policy Engine sensor driver for lahaina to get the CX/MX
mitigation recommendation as sensor.
Change-Id: I481552649909c32d229186a62e8b9240ca2ec88b
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
Add SDPM clock notifier driver, which will register for clock rate
change notification and write the clock rate into SDPM CSR register. The
SDPM hardware will monitor the frequency changes and recommend
mitigation using policy engine.
Change-Id: I56b2941b3c3e47bdb49bf805a2fc9acd4356470f
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
Add Policy Engine(PE) sensor recommendation as a sensor with thermal
framework. PE will recommend a mitigation level based on the operating
level of CX/MX clients. Registering this recommendations as sensor enables
the user to provide thermal zone configuration to mitigate cooling devices
for different policy engine recommendations.
Change-Id: I65e1a8baad62957482daca493987d6cd51eee3ef
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
Enable UAPI_HEADER_TEST in the Lahaina GKI defconfig for UAPI sanity
checks.
Change-Id: Ic0dedbad7cd0782018c8e6f32d4337c6e211a809
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
When unmapping memory in S1, treat zero-sized sg-lists as invalid
inputs.
Change-Id: I477cd0808eea1200873c50470c8b73d9162428e4
Signed-off-by: Isaac J. Manjarres <isaacm@codeaurora.org>
Add support for KPROBE for debugging various issues on
lahaina/shima/holi.
Change-Id: Iede9d2d29f5053b1024097db4640bbec996a441d
Signed-off-by: Mukesh Ojha <mojha@codeaurora.org>
This change removes not informative prints.
Change-Id: Ic4c4e6fef752c72082b260b2e34873bd994bc62d
Signed-off-by: Konstantin Dorfman <kdorfman@codeaurora.org>
Avoid passing tail pages to isolate_lru_page. In the case
process reclaim, since only lru pages are considered, this
is just to avoid a warning from isolate_lru_page.
Change-Id: I1f54dcec15f8c2d5ba16738657e79d2793d36c77
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>