提交图

1912 次代码提交

作者 SHA1 备注 提交日期
GG Hou
5f4735e2ce disp: msm: sde: fence error handling for wb and cwb retire fence
Fence error handling for wb and cwb retire fence.
Signal the retire fence for the fence error frame.

Change-Id: I0f73195c50edab4b8aefb58cea342214be87584c
Signed-off-by: GG Hou <quic_renjhou@quicinc.com>
2023-05-14 23:57:59 -07:00
GG Hou
85015a84cb disp: msm: sde: reset lutdma when fence error occurs
Reset lut dma when fence error is seen to reset the already
submitted queue.

Change-Id: Iba9ab33a2e80bdaba6b1d4ccff086e3a46f8374d
Signed-off-by: GG Hou <quic_renjhou@quicinc.com>
2023-05-14 23:57:22 -07:00
GG Hou
d2812ee4e7 disp: msm: add support for display clients to register for fence error
Add framework for display submodules like PP, DSI, DP to register
for fence error and call the client callback funtion when fence
error occurs.

Change-Id: I70cc6b01907177e6c4238c4398fe2c085a000322
Signed-off-by: GG Hou <quic_renjhou@quicinc.com>
2023-05-14 23:55:51 -07:00
GG Hou
54209fb4d0 disp: msm: sde: sw fence error handling
Sw fence error handling addresses following:
a. out of order handling
  - For cmd panel, signal the release fence and retire fence once
    sw fence error detected.
  - For vid panel, signal the fence error frame release fence and
    retire fence once sw fence error detected, hold the release
    fence of last good frame till next good frame.
b. avoid BW decrease vote
c. lut dma reset
d. cancel kickoff

Change-Id: Ic496c532a26d80e0ef0074624ef6ace01c4ab2f0
Signed-off-by: GG Hou <quic_renjhou@quicinc.com>
2023-05-15 14:54:03 +08:00
GG Hou
a658fb17b7 disp: msm: sde: dma fence out of order handling in fence error case
Handle out of order dma fence signalling and propagation of fence
error. Out of order fence signaling is required only in Video mode.
For example, in case of N, N+1, N+2 frames where N, N+2 are good
frames and N+1 is frame with fence error. The release fence signal
sequence in video mode would be N+1, N, N+2.

Change-Id: I8b6f88cfeee945e28571b765f24ffea22fad23b8
Signed-off-by: GG Hou <quic_renjhou@quicinc.com>
2023-05-14 20:15:49 -07:00
GG Hou
725c7a0f3d disp: msm: sde: add support for hw fence error handling
Register callback function to hw fence driver and implement the
callback funtion.

As part of fence error handling, address out of ordering of HW
fences, SW override for release fence signal and handle BW voting
in both cmd and video mode.

Change-Id: I22902762b4cc09a5f5a20cf0dd01fc336a0f0cb4
Signed-off-by: GG Hou <quic_renjhou@quicinc.com>
2023-05-14 20:13:58 -07:00
GG Hou
97b1afdda8 disp: msm: add property to handle fence error in driver
Add a new property CRTC_PROP_HANDLE_FENCE_ERROR for userspace
to enable or disable fence error handling.

Change-Id: I72370f405c5299c603b0d673720c28a68c00807a
Signed-off-by: GG Hou <quic_renjhou@quicinc.com>
2023-05-14 20:12:02 -07:00
qctecmdr
ed49f6e356 Merge "disp: msm: sde: fix update of current perf bandwidth values" 2023-05-11 03:45:46 -07:00
Prabhanjan Kandula
200f6c09dd disp: msm: sde: avoid incorrect register writes in blend stage clear
While clearing all blend stages, avoid writing blend config
registers for invalid dummy layer mixers introduced for dcwb.
These dummy mixers are SW only representation, these mixers
do not have respective blend config register space defined in HW.
Currently blend stage clear logic clears other undefined and
some valid registers like CTL_x_SW_RESET_OVERRIDE which is not
intended. This change limits accessing blend config registers
based on actual HW layer mixer count by ignoring dummy mixers.

Change-Id: I3a61fb6d5522b041fd6f10305b84dae449b4f2c7
Signed-off-by: Prabhanjan Kandula <quic_pkandula@quicinc.com>
2023-05-10 12:56:35 -07:00
Prabhanjan Kandula
d994b9e580 disp: msm: sde: fix update of current perf bandwidth values
In Current SDE driver, perf update check avoids bw update
in RSC state transitioning from CLOCK to SOLVER and updating
cached cur_perf bw values with out actual update to bus causes
bw update miss until usecase change trigger a new bw values
from client.

Below is the sequence of events in issue scenario.
-> wakeup frame from suspend, start with max bw voting and
	framedone successful
-> RSC state updates to CLOCK state because of delay in next
	incoming frame
-> Next frame perf update with paramschange, bw update is
	skipped as new bw  < cur bw and RSC is in CLOCK state
-> RSC updates SOLVER state after above step and commit is flushed
-> Bw update after frame is also avoided because RSC is in SOLVER
	but cur_perf is updated with new bw value.
-> from next frame if bw is same as perevious frame, voting is skipped.
	until change in bw values, vote of max bw in first frame is left.

This change fixes updating cur_perf values only when actual
bus update is intended.

Change-Id: If3ea4f178b94e9e59cd8ca563fa3510dffcc15a5
Signed-off-by: Prabhanjan Kandula <quic_pkandula@quicinc.com>
2023-05-10 12:56:25 -07:00
Shamika Joshi
42d9137a04 disp: msm: sde: fix min fps in EPT calculations
In non-qsync panels when min FPS is not published in DT,
the default min fps is set to 10 FPS. This change handles mode
switch cases, when panel FPS drops below 10 FPS by updating
min FPS to panel FPS for Expected Present Time calculations.
As part of the change, reduce 2ms from EPT to account for
scheduling delays after schedule_timeout.

Change-Id: Idc206f39adfb3517b4ea2cfa303fe53182a8e63e
Signed-off-by: Shamika Joshi <quic_shamjosh@quicinc.com>
2023-05-09 10:27:03 -07:00
qctecmdr
b02c68b75c Merge "disp: msm: sde: avoid concurrency while calculating max mode width" 2023-05-08 15:24:22 -07:00
qctecmdr
ea39f24f67 Merge "disp: msm: sde: fix out of bounds memory access" 2023-05-08 15:24:22 -07:00
qctecmdr
a0eb3b7090 Merge "disp: msm: sde: propagate the error code in dual display TUI cases" 2023-05-07 22:46:00 -07:00
Saurabh Yadav
8f73dc7e9d disp: msm: sde: fix out of bounds memory access
Change-Id: I74324fc1032086ac4362a059a9f76a6dcdc19193
Signed-off-by: Saurabh Yadav <quic_sauyad@quicinc.com>
2023-05-05 00:09:17 -07:00
qctecmdr
f993f4d8e0 Merge "disp: msm: sde: program INTF VSYNC src_en bits for vsync TS" 2023-04-28 00:59:51 -07:00
Raviteja Tamatam
26c011089e disp: msm: sde: propagate the error code in dual display TUI cases
Propagate error in case the number of active displays is greater
than 1, in dual display scenario to fail the validate.

Change-Id: I04250af8d7a6b0c290132abbaed2ed8e5e311a4f
Signed-off-by: Raviteja Tamatam <quic_travitej@quicinc.com>
2023-04-26 12:01:53 -07:00
Veera Sundaram Sankaran
a599814880 disp: msm: sde: program INTF VSYNC src_en bits for vsync TS
From MSSS 10.x, the src_en bits needs to be set appropriately for
vid/cmd mode for getting the vsync timestamp. Program it based
on the new feature flag SDE_INTF_VSYNC_TS_SRC_EN.

Change-Id: Ia9c59d66afb436f082c7ebe6bf28e3953fde27a5
Signed-off-by: Veera Sundaram Sankaran <quic_veeras@quicinc.com>
2023-04-25 11:51:02 -07:00
Nilaan Gunabalachandran
c6bdb5db3a disp: msm: sde: avoid concurrency while calculating max mode width
With DP plug-ins, it is possible for the connector fill modes API
to be called to update available modes on the connector and at the
same time have the commit thread calculate the max mode width
on the available modes. As a result, it is possible to access
pruned modes from the modelist.

This change moves the calculation into the fill modes call-flow,
so that the max mode width is determined once, and stored to be
used during virt enable.

Change-Id: I6c332c57e6e98ed98444a303add97d163a2031bf
Signed-off-by: Nilaan Gunabalachandran <quic_ngunabal@quicinc.com>
2023-04-25 12:39:05 -04:00
Grace An
612cf09d0f disp: msm: sde: add hw-fence QOS priority config
This change updates the hw-fence QOS priority level.

Change-Id: I61e832f15d060cd563986dbd7135c00fce9dd5c9
Signed-off-by: Christina Oliveira <quic_coliveir@quicinc.com>
Signed-off-by: Grace An <quic_gracan@quicinc.com>
2023-04-25 09:18:22 -07:00
Nilaan Gunabalachandran
825dd16313 disp: msm: sde: correct llcc_slice_getd/putd usage
The llcc_slice_getd/putd APIs were previously used to get/put the
slice descriptor reference, for every time the driver needed the
descriptor. However, the APIs should be used to get the reference
once, and only put after completing usage of the slice
(ie. if the slice is still active, the descriptor cannot be putd).

This change corrects the usage of the llcc_slice_getd/putd APIs by
storing the descriptor after initialization.

Change-Id: I33e6448290ff7a4d8bfa72e1e6bc8ca133283e12
Signed-off-by: Nilaan Gunabalachandran <quic_ngunabal@quicinc.com>
2023-04-24 16:46:38 -04:00
Veera Sundaram Sankaran
336212e10a Revert "disp: msm: sde: enable EPT_FPS feature for cmd mode in pineapple target"
This reverts commit ae24e846e1.
Enable the feature only when user-mode support is added. With this
feature enabled in driver, it expects EPT_FPS to be set for qsync
enabled cmd-mode panels and will not honor EPT(expected present time).
With the EPT_FPS feature disabled, all panels cmd/video with/without
qsync can use EPT.

Change-Id: Ib8b1625bb1927ece3ec435e4b9a724da0555e518
Signed-off-by: Veera Sundaram Sankaran <quic_veeras@quicinc.com>
2023-04-19 22:08:50 -07:00
qctecmdr
a5b7dc6eb9 Merge "disp: msm: sde: reset dsc 4hs merge enable" 2023-04-19 14:34:14 -07:00
qctecmdr
a5dd993196 Merge "disp: msm: sde: remove EPT & QSYNC dependency" 2023-04-17 17:42:31 -07:00
qctecmdr
a0c954eea2 Merge "disp: msm: sde: add debugfs node to get current uidle status" 2023-04-14 13:12:08 -07:00
qctecmdr
2ccae39402 Merge "disp: msm: sde: program both rc config and ram through lut dma" 2023-04-14 13:12:08 -07:00
qctecmdr
1d9d243a82 Merge "disp: msm: sde: flush pp event work queue before vm release" 2023-04-14 13:12:08 -07:00
Nilaan Gunabalachandran
6962242207 disp: msm: sde: reset dsc 4hs merge enable
If DSC 4hs merge is enabled and disabled on n+1 commit, possible
due to resolution switch, driver does not currently clear the
previous programming.

This change cleares dsc 4hs merge enable if it is not enabled.

Change-Id: I4024073362257b7efabcff22603bcb28a0bc4c5a
Signed-off-by: Nilaan Gunabalachandran <quic_ngunabal@quicinc.com>
Signed-off-by: Nisarg Bhavsar <quic_bhavsar@quicinc.com>
2023-04-14 12:02:19 -07:00
Lei Chen
8ed479026a disp: msm: sde: add debugfs node to get current uidle status
Add a read only debugfs node to get current uidle status.
Usage:
      cat /sys/kernel/debug/dri/0/debug/core_perf/uidle_status
       N: indicate uidle is disabled.
       Y: indicate uidle is enabled.

Change-Id: I7f28b406588c19decc4efc9012f5bac63925618a
Signed-off-by: Lei Chen <quic_chenlei@quicinc.com>
2023-04-14 09:49:37 -07:00
Saurabh Yadav
c27d7c56ce disp: msm: sde: program both rc config and ram through lut dma
Currently, only rc ram is programmed through lut dma and
rc config is programmed through ahb.
This change programs both rc config and rc ram through lut dma.

Change-Id: I50a6e87dfbadb9c4a93cebdaa1e813f5be9ba5f5
Signed-off-by: Saurabh Yadav <quic_sauyad@quicinc.com>
2023-04-14 09:48:43 -07:00
qctecmdr
90ba54e04b Merge "disp: msm: sde: defer S2-only and tvm dma_buf_map_attachment" 2023-04-14 04:33:12 -07:00
qctecmdr
dc5a69d265 Merge "disp: msm: sde: check for hardware ownership before histogram read" 2023-04-13 23:29:59 -07:00
Veera Sundaram Sankaran
62b643a4d6 disp: msm: sde: remove EPT & QSYNC dependency
Expose Expected Present Time property to usermode immaterial of the
panel qsync support. EPT can be used to delay the frame with/without
qsync support.

Change-Id: If4e628dda64181995ba9ba0b008d15d3d9a9cfd4
Signed-off-by: Veera Sundaram Sankaran <quic_veeras@quicinc.com>
2023-04-12 18:28:51 -07:00
qctecmdr
302a160bae Merge "disp: msm: add feature-enabled check for output hw-fence sw-override" 2023-04-10 15:38:33 -07:00
Veera Sundaram Sankaran
d867d748ab disp: msm: sde: defer S2-only and tvm dma_buf_map_attachment
For usecase with S2-only or TVM buffers, the mapping needs to be done
after the SCM call. This is required to ensure the mapping is done to
the correct SID. Previously with S2-only usecase, the map was returning
the PA which would remain the same, so there were no issues even though
the map sequence was incorrect. But this sequence will cause issues with
CSF-2.5 as it uses 2-stage with TVM, and requires the mapping to be done
after the scm-call. Fix the sequence for legacy secure-camera preview,
legacy secure-display and CSF 2.5 solution.

Change-Id: Id663d30fdbf8725f43f61e67d2d7ce72aa9f9506
Signed-off-by: Veera Sundaram Sankaran <quic_veeras@quicinc.com>
2023-04-10 10:04:26 -07:00
Saurabh Yadav
ac9d215e9e disp: msm: sde: flush pp event work queue before vm release
In some vm transitions, pp work might get executed on event thread
after handoff is completed on commit thread leading to crash.
This change flushes the pp event thread queue during vm pre-release
before lending the io resources to the other vm.

Change-Id: I53b76e48bc15084aa5519409fae0e692f49e7558
Signed-off-by: Saurabh Yadav <quic_sauyad@quicinc.com>
Signed-off-by: Lakshmi Narayana Kalavala <quic_lkalaval@quicinc.com>
2023-04-07 10:48:19 -07:00
Lakshmi Narayana Kalavala
02fcd809d2 disp: msm: sde: check for hardware ownership before histogram read
This change adds the check for hardware ownership before
reading the histogram statistics.

Change-Id: I0f811cef327c1dea9fb132d5fffd8da445e9d73f
Signed-off-by: Lakshmi Narayana Kalavala <quic_lkalaval@quicinc.com>
2023-04-06 13:18:24 -07:00
Prabhanjan Kandula
ba7b5c08cc disp: msm: sde: avoid skipping of encoder reset in cwb disable
During cwb disable, encoder reset should be invoked to clean up
and release hw resources. This encoder reset should happen even
if cwb encoder TX_DONE is not successful to avoid rm rsvp leak.

Change-Id: I81353f19b69cb68d71f7d5b6477e37b6dab3ae00
Signed-off-by: Prabhanjan Kandula <quic_pkandula@quicinc.com>
2023-04-05 19:10:10 -07:00
Christina Oliveira
85b87f5573 disp: msm: add feature-enabled check for output hw-fence sw-override
In the case that the hw-fence feature is enabled in the display driver dt
but disabled during initialization by the display driver when hw-fence
driver dependency is disabled, the existing check to determine
if the function pointer is available is not sufficient to determine
if the feature is enabled. This change adds an additional check to ensure
we do not set the output-fences sw-override unless hw-fencing is enabled.

Change-Id: I7f5000037e7b2a142224ef9c45b383e5c701350a
Signed-off-by: Christina Oliveira <quic_coliveir@quicinc.com>
2023-04-05 11:06:13 -07:00
qctecmdr
827af70599 Merge "disp: msm: sde: reset crop registers in PU cases" 2023-04-04 22:25:51 -07:00
Linux Build Service Account
65afd67e14 Merge "disp: msm: sde: Rename Gunyah RM APIs" into display-kernel.lnx.1.0 2023-04-04 22:11:39 -07:00
Shamika Joshi
eb2cae7569 disp: msm: sde: reset crop registers in PU cases
In back to back partial update cases with CWB the CROP
registers are not reset causing WB timeout in the
following sequence-
1) Nth commit WB_roi != LM_PU_roi, WB CROP registers
are programmed.
2) N+1th commit WB_roi == LM_PU_roi, WB CROP registers
are not cleared retaining old values.
Clear the WB CROP registers in the second case to fix
the issue.

Change-Id: If09a697f48ecaf5ee08d6313be444748d048b20d
Signed-off-by: Shamika Joshi <quic_shamjosh@quicinc.com>
2023-04-04 13:48:33 -07:00
Lakshmi Narayana Kalavala
2751ec018d drm: msm: skip re-marking color processing features as dirty
Current implementation we apply the color properties when atomic begin
is called and mark features as dirty if crtc is not enabled.
For some of the non double buffered features in video mode we will
see a corruption. Change removes marking color properties as dirty
based on crtc on/off.

Change-Id: I4d93b14627d2bc06fcbca3ea9538a4baedb00e56
Signed-off-by: Lakshmi Narayana Kalavala <quic_lkalaval@quicinc.com>
2023-03-28 18:09:49 -07:00
Prakruthi Deepak Heragu
09421907d8 disp: msm: sde: Rename Gunyah RM APIs
As we are merging upstream patches, resolve conflicts of namespaces in
downstream modules.

Change-Id: Id3af0de7102ddd92e312cb3cca10db9968974bcd
Signed-off-by: Prakruthi Deepak Heragu <quic_pheragu@quicinc.com>
Signed-off-by: Raviteja Tamatam<quic_travitej@quicinc.com>
2023-03-27 15:54:11 -07:00
qctecmdr
8c1b88916f Merge "disp: msm: sde: update hw-fence txq wr_ptr from hardware" 2023-03-16 19:58:44 -07:00
qctecmdr
81e8aa8d56 Merge "disp: msm: sde: remove avr state check early return" 2023-03-16 10:55:17 -07:00
Christina Oliveira
b5cbfa8358 disp: msm: sde: update hw-fence txq wr_ptr from hardware
This change adds hardware programming that will update the
txq wr_ptr upon output fence firing.

Change-Id: I79ff0ea5fb2b7f73a48bd70e3c8e71ea69fead95
Signed-off-by: Christina Oliveira <quic_coliveir@quicinc.com>
2023-03-15 12:53:37 -07:00
Mahadevan
7c8a28d45f disp: msm: sde: qos vote for all cpus during vm transition
For a proxy-scheduled VCPU like the TUI VM, assignment to a
physical core is a runtime decision made by the HLOS scheduler,
and it may change frequently. pm_qos vote added by PVM for
specific CPUs won't be sufficient for addressing irq latency.
This change updates votes for all possible CPUs during TVM
entry and also removes the vote during exit.

Change-Id: Iab5cb5f57e2389ee57689ba2ab69394376f59788
Signed-off-by: Mahadevan <quic_mahap@quicinc.com>
2023-03-13 14:54:15 -07:00
Nilaan Gunabalachandran
d483cbe62a disp: msm: sde: remove avr state check early return
After introducing avr step state, the driver checks for avr
state none before returning early. In the case where avr property
is not being set, this leads to skipping qsync programming.

This change removes this state check.

Change-Id: Ie277dd04b8913358135210131a99c598cf2145ba
Signed-off-by: Nilaan Gunabalachandran <quic_ngunabal@quicinc.com>
2023-03-13 10:48:57 -07:00
qctecmdr
1ca5ff7768 Merge "disp: msm: sde: use vzalloc for large allocations" 2023-03-12 21:39:22 -07:00