This reverts commit 260b8bb97f.
Reason for revert: it cause b/158957349
Change-Id: I219cf4f41629c22df1f092324e9c4b44495ff683
Signed-off-by: Jason Chiu <jasoncschiu@google.com>
Kernel Panics with error "mapping sg segment longer than device claims
to support". The device can actually accomodate larger sg segments than
its default segment size. This patch correctly sets max dma segment size
for the device.
Test: Checked KP logs and timing before and after patch change.
Bug: 154829554
Signed-off-by: kdevika <kdevika@google.com>
Change-Id: Ida3130c7d96b3f9a479e09e2558d692f155b8f9c
If kgsl memstore limit is reached, new kgsl context creation fails. This
leads to app crashes in userspace. This patch enhances debug information
in such cases and dumps the details of the process that captured each
active context.
Bug: 152403810
Test: Forced printing the logs.
[ 46.665957] kgsl kgsl-3d0: |kgsl_dump_active_contexts| process droid.launcher3 pid 2397 created 3 contexts
[ 46.665954] kgsl kgsl-3d0: |kgsl_dump_active_contexts| process ndroid.systemui pid 1962 created 3 contexts
[ 46.665939] kgsl kgsl-3d0: |kgsl_dump_active_contexts| process android.hardwar pid 844 created 3 contexts
Signed-off-by: kdevika <kdevika@google.com>
Change-Id: I06b3751f339c041ab2f7a1aa290e6ab4878b8236
This reverts commit 4fb16fdecb3c7773c10e4f51d1c025f45c9fc070.
Bug: 157703508
Reason for revert: cannot boot to home with KP
Change-Id: I2769aff6e977c50a82b93fce8f2f38b0380d818c
Signed-off-by: lucaswei <lucaswei@google.com>
Use NR_KERNEL_MISC_RECLAIMABLE instead of
NR_INDIRECTLY_RECLAIMABLE_BYTES for kgsl allocations and in sysstats.
Bug: 150808082
Test: build
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Ice5167bd9b380bb4c4b4d810aa685d211bcf2f80
This is to enable modularization of CONFIG_ION
Bug: 147914088
Test: build, boot, all devices still probe.
Change-Id: Ic3ca076802ff3071c5a87addcd6552b38d3f9d8a
Signed-off-by: Hridya Valsaraju <hridya@google.com>
This reverts commit 0277cfc229
as it causes display issues on some lito devices.
Bug: 141888346
Test: build, boot, all devices still probe.
Change-Id: I907fb706f58f77042bbd93ecca2f1f145a44b9d1
Signed-off-by: Hridya Valsaraju <hridya@google.com>
Our GKI hack to probe gmu and kgsl-smmu has lead to an issue with
blocking suspend and resume. To fix this, let's quietly return from the
suspend/resume routines for these devices since the actual
suspend/resume is handled by the main kgsl device.
Signed-off-by: Will McVicker <willmcvicker@google.com>
Bug: 145884479
Test: verify suspend/resume isn't blocked by gmu and/or kgsl-smmu
Change-Id: I8c68845e98aac7dc1a6559aa703fb51ee672c797
SideEffect: must export kern_addr_valid to build, followup patch fixes.
Bug: None
Test: compile tested on bramble and kona, runtime test on kona
Change-Id: I629358f2d61ac04787b1c82b1167ae7935e24acb
Add a check to allow only cached buffers to be marked iocoherent.
We can't enable io-coherency for uncached buffers because of
situations where hardware might snoop the cpu caches which can
have stale data. This happens primarily due to the limitations
of dma caching APIs available on arm64.
Change-Id: Iafad086d38559139cb45f6a290071ec6d58ad3a3
Signed-off-by: Urvashi Agrawal <urvaagra@codeaurora.org>
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
Capture the debugbus registers of the block A6XX_DBGBUS_SPTP_0,
which are required to get more information on SP. Also capture
the registers of A6XX_DBGBUS_COM_1 to get MHUB related
information.
Change-Id: Ic68e7bbdd878e88cf4b9aa079544b09ea81038ec
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
Existing api returns failure when requested frequency
is larger than fmax supported. This creates problem to
clients as they consider this as error case. This
can be improved if api returns success when requested
frequency is larger than fmax supported because requested
limit frequency is larger than fmax device will never
go beyond that at all and clients can execute normally.
Change-Id: Id1077ca03019a61d7fd6fef8eccd605131b9c150
Signed-off-by: Pranav Patel <pranavp@codeaurora.org>
Do not set FAULT_SKIP_SNAPSHOT in case of not collecting inline
snapshot.
Change-Id: I5f3de5881768ab07de989010096a58bea749c680
Signed-off-by: Pankaj Gupta <gpankaj@codeaurora.org>
GMU FW version v1.10 is released for A619 GPU. Update
expected GMU firmware version to make sure correct
GMU firmware is used for this GPU.
Change-Id: I3d93f8e022515b8ad853efe37f7812785fac9962
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
Print always on counters before collecting gmu core snapshot. This will
help to sync and analyze gmu traces with dmesg.
Change-Id: Icd2223662cce503f8d464592eb4f2307b519f015
Signed-off-by: Pankaj Gupta <gpankaj@codeaurora.org>
Set the bit ADRENO_PREEMPTION in adreno core features
to enable preemption for A702.
Change-Id: If750b2bf607576615a93e85c23d8173891b8018f
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
In preemption fault handler, check only the STOP bit of
ADRENO_REG_CP_PREEMPT register to see if the preemption is complete.
Change-Id: Id1f2d0947412e996d6028558124c3e528527cec6
Signed-off-by: Akhil P Oommen <akhilpo@codeaurora.org>
Signed-off-by: Sebanti Das <sebadas@codeaurora.org>
The two always happen together. So set the gmu_fault
inside the gmu_snapshot function. Also, if we have
already recorded a gmu fault, then do not send nmi
or try to snapshot a gmu which is already in nmi.
Change-Id: I403a9c2c3cb7a1330a7931c41a23b4b4a2b66998
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
A stuck CP means that we will not be able to enter
slumber because gmu to cp interaction is impacted.
Therefore, take a gmu snapshot which also sets gmu
fault. The gmu fault will indicate the clean up
code to force a gmu_suspend() so as to set the
stage for the next submission to start afresh.
Change-Id: Ia90e6c447e9c1c87e04cf9ca3ed87eed5c17b07c
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
GMU can fail to turn on GX or it can fail the
START HFI. So take snapshot and put GMU in NMI.
When this happens, kgsl will call gmu_stop()
and as GMU is already in fault aka NMI, reset
the GMU and GPU.
Change-Id: Iafc9b34063a7ff2415d3462dd289b52e425fbf3b
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
Send NMI to gmu so that we don't lose critical gmu state.
We do not want to trigger dispatcher because we don't know
whether the gpu was active or not. The best course of action
is to wait for the next kgsl -> GMU interaction to timeout
thus triggering GMU snapshot and appropriate recovery steps
based on whether gpu was active or not.
Change-Id: I17b4245f4e0113bfc902d7dae46bb24d0bc2b65d
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>