提交線圖

1582 次程式碼提交

作者 SHA1 備註 日期
Steve Cohen
43076f3a77 disp: msm: sde: fix check for uneven split with dest-scaler
Fix the check for uneven split across LMs when destination
scaler is used and reject the use-case since this is not
supported by the driver. This can happen if an odd-value
for the horizontal width is being split across 2 mixers.

The existing check was broken since it uses pass-by-value
with a zero initialized value that callee tries to update
while iterating over the DS configurations. Use pass-by-
reference with the previous DS configuration, if available,
instead of just 0 values so the proper comparisons can take
place.

Change-Id: I529faf57e43fb471b28b4d222260ea4d37217d4d
Signed-off-by: Steve Cohen <cohens@codeaurora.org>
2020-08-23 22:17:27 -04:00
Steve Cohen
d66ea6fc29 disp: msm: sde: use the correct get_status op for all INTFs
A new status register was added in DPU 5.x to INTFs to allow for
confirmation when the timing engine is disabled. This
functionality was controlled via an overloaded feature flag
which is used to enable INTF tear-check ops (also added in DPU
5.x). External displays support INTF_STATUS but have no use for
any tear-check functions. Separate these features so they can be
enabled individually on the interfaces which support them.

Change-Id: Ib8548619cb58bf19b7c02211ead7f33f52ffeae4
Signed-off-by: Steve Cohen <cohens@codeaurora.org>
2020-08-23 21:23:18 -04:00
qctecmdr
d827191e2a Merge "disp: msm: sde: wait for done in system cache read mode update" 2020-08-21 15:12:34 -07:00
qctecmdr
ead6a35953 Merge "disp: msm: dsi: add parsing logic for panel gpio pins/address" 2020-08-21 12:36:22 -07:00
qctecmdr
86d25d0c03 Merge "disp: msm: dsi: update min prefill lines for lahaina" 2020-08-21 12:36:22 -07:00
Prabhanjan Kandula
f112e7aa61 disp: msm: sde: wait for done in system cache read mode update
In current driver, during system cache read mode update control flush
is invoked and there after commit thread is allowed to pick up next
commit. This can lead to improper frame flush and cause hangs or
underrun. This change add a wait till frame done after system cache
update to frame read mode.

Change-Id: Ic88e0bdbaaa1f45f825d40ecde4de9e8dea2efef
Signed-off-by: Prabhanjan Kandula <pkandula@codeaurora.org>
2020-08-21 10:46:54 -07:00
Yashwanth
38372059b3 disp: msm: sde: update rotator sid value in continuous splash case
This change programs rotator sid value irrespective of
continuous splash since it is not configured from
bootloader. It also handles trusted vm support
to prevent accessing mdss hw register.

Change-Id: I80e286364286457545dfa236d629447241d98f95
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>
2020-08-21 19:52:35 +05:30
qctecmdr
57807a5d97 Merge "disp: msm: dp: use base connector properties for mst connectors" 2020-08-20 23:40:52 -07:00
qctecmdr
f7d7f56c53 Merge "disp: msm: dp: init and deinit the lock in dp_mst_connector_list" 2020-08-20 23:40:52 -07:00
Linux Build Service Account
c29e22f272 Merge "disp: msm: sde: fix reset of mixer swapping" into display-kernel.lnx.5.4 2020-08-20 21:52:53 -07:00
Linux Build Service Account
0af93447c5 Merge "disp: msm: dsi: enable dfps trigger at mdp intf flush" into display-kernel.lnx.5.4 2020-08-20 21:52:52 -07:00
qctecmdr
fc83bddf26 Merge "disp: msm: sde: Update UIDLE and QoS LUT when DRM mode is changed" 2020-08-20 14:24:30 -07:00
Rajkumar Subbiah
1a9437a816 disp: msm: dp: fix simulated hpd_irq handling for real monitors
A mode switch on a real monitor can be triggered by forcing the new
mode using debugfs and initiating an hpd_irq. Due to a missing
check for simulator state, the current driver calls the hpd_irq
callback for simulator even for a real monitor. This change adds
this check.

Change-Id: I13480eccd27eac2f9df3dd766d0445c0a5ea9b2c
Signed-off-by: Rajkumar Subbiah <rsubbia@codeaurora.org>
2020-08-20 17:23:31 -04:00
Christopher Braga
46d5d3ada2 disp: msm: sde: Add event logs for lutdma kickoff programming
Introduce event logs for lutdma kickoff operations to make
LUTDMA usage more apparent in crash dumps. This will aid in
debugging and triaging LUTDMA issues.

Change-Id: I81b570dfc21b03627cdaf5d9693b786839716571
Signed-off-by: Christopher Braga <cbraga@codeaurora.org>
2020-08-20 16:07:11 -04:00
Christopher Braga
4a4e450b2c disp: msm: sde: Add debug bus dump support for LUTDMA
Add hooks to dump LUTDUMA debug bus status during dumping
of system debug status. LUTDMA debug bus can be accessed
from userspace via the "recovery_lutdma_dbgbus" debugfs node.
Output control of the LUTDMA_dbbus is managed by the
"reg_dma_dbgbus" node.

Change-Id: Iea011279dd3806f0f594102ce7a5dc018a8d2b7c
Signed-off-by: Christopher Braga <cbraga@codeaurora.org>
2020-08-20 16:07:07 -04:00
Vara Reddy
c9cb9f51f3 disp: msm: dsi: enable dfps trigger at mdp intf flush
This change allows dynamic refresh trigger to sw trigger
and mdp intf flush. With this we can make sure that DSI
timing/clock update and mdp intf timings are updated in
one vsync.

Change-Id: Ic807f498e2e47be6dd0f1e11ff1fc0896a8ec758
Signed-off-by: Vara Reddy <varar@codeaurora.org>
2020-08-20 12:48:32 -07:00
qctecmdr
992439c83e Merge "disp: msm: sde: report intf interrupt status during underrun" 2020-08-20 11:47:26 -07:00
Rajkumar Subbiah
b240ae79e4 disp: msm: dp: avoid use of mst_lock in hpd callbacks
DP MST driver registers bridge callback functions with the DRM framework.
mst_lock is used for synchronization of the mst bridge functions. These
functions call into dp_display where a session lock is obtained for
the display. HPD callbacks, on the other hand, are first handled by
dp_display. During these callbacks, dp_display takes a session lock
first before calling into DP MST driver layer. Currently, the DP MST
layer waits on mst_lock which can result in a deadlock.

This change removes the usage of mst_lock inside hpd callback functions
and just uses the session lock for synchronization.

Change-Id: I7ec338004eef43ac0f1e1f092463e9915cd60684
Signed-off-by: Rajkumar Subbiah <rsubbia@codeaurora.org>
2020-08-19 14:21:05 -04:00
Abhijit Kulkarni
6a46828a29 disp: msm: sde: fix reset of mixer swapping
This change resets the mixer swapping flag in crtc on a
seamless mode switch. In case of switching from command
mode to video mode it is a seamless mode on crtc, but we
disable connector and encoder. Due to this crtc fails to
reset the mixer swap since it is tied to dsc merge topology
on master connector. In transient state master connector
is not set and is set only after enabling the new mode on
connector.

Change-Id: Idebdabd642625b894100f62aeb62f11a9c101b03
Signed-off-by: Abhijit Kulkarni <kabhijit@codeaurora.org>
2020-08-19 10:51:55 -07:00
Rajkumar Subbiah
741ff9062f disp: msm: dp: init and deinit the lock in dp_mst_connector_list
The lock used by the dp debug driver to synchronize the maintenance
and usage of the list of mst connectors is not initialized. This
change adds the missing initialization and deinitialization calls.

Change-Id: I4c24600b47c0b90c256caff45edaea07d082908d
Signed-off-by: Rajkumar Subbiah <rsubbia@codeaurora.org>
2020-08-19 12:31:37 -04:00
Linux Build Service Account
c7464588de Merge "disp: msm: sde: expand dsc range_bpg_offset to support 10bpc" into display-kernel.lnx.5.4 2020-08-19 01:54:41 -07:00
Linux Build Service Account
2bdc128bfc Merge "disp: msm: sde: fix dsc hrd delays register bitmask" into display-kernel.lnx.5.4 2020-08-19 01:54:39 -07:00
Linux Build Service Account
b18fe5bc7e Merge "disp: msm: dp: enable INTF to DP drain rate matching" into display-kernel.lnx.5.4 2020-08-19 01:43:14 -07:00
Linux Build Service Account
e3092c8b9f Merge "disp: msm: sde: only program LM size when needed" into display-kernel.lnx.5.4 2020-08-19 01:43:13 -07:00
Linux Build Service Account
3ee8c55695 Merge "disp: msm: dp: fix DP controller bpc configuration when DSC is enabled" into display-kernel.lnx.5.4 2020-08-19 01:42:13 -07:00
Linux Build Service Account
b9e87e5e7a Merge "disp: msm: dp: fix mst port state reporting on hpd unplug" into display-kernel.lnx.5.4 2020-08-19 01:42:12 -07:00
qctecmdr
d567ca0876 Merge "disp: msm: sde: expose helper api at VM layer" 2020-08-18 20:10:47 -07:00
Sudarsan Ramesh
7b798deb9b disp: msm: dp: fix mst port state reporting on hpd unplug
The simulation case uses dp_mst_sim_detect_port which
calls the drm detect port function after checking
the mst state. The non simulation case calls the drm
function directly.

This leads to cases in the disconnect path where
connectors are detected while being unregistered.
This solution merges the simulation and non simulation
cases by using the same detect port function, where a
check for mst state is performed before calling the
drm function.

Change-Id: I4a93001131beda54f8146bd50edc036924c94ab1
Signed-off-by: Sudarsan Ramesh <sudarame@codeaurora.org>
2020-08-18 18:11:43 -04:00
Amine Najahi
4eaa6dd39e disp: msm: sde: fix index variable used in CP pu check phase
Currently driver uses wrong index to retrieve partial update
ROI during check phase. This can lead to ROI being 0 for some
of the CP properties.

Change-Id: I885132e8d29eaf1353ed079eb283f7ca3a3d63a6
Signed-off-by: Amine Najahi <anajahi@codeaurora.org>
2020-08-18 07:30:12 -04:00
Lei Chen
fb4edab2b3 disp: msm: sde: Update UIDLE and QoS LUT when DRM mode is changed
UIDLE and QoS LUT configurationis might be different between
different frame rates.
Add this change to update UIDLE and QoS LUT according to frame
rate when DRM mode is changed.

Change-Id: Ia16a963e185b911b7dd11e81a26cab732c2b185c
Signed-off-by: Lei Chen <chenlei@codeaurora.org>
2020-08-18 09:56:43 +08:00
Rajkumar Subbiah
9522cd1382 disp: msm: dp: use base connector properties for mst connectors
When DRM property objects are created, the DRM framework attaches a
dellocator which can eventually free the object when the last reference
is removed from it. The framework can only do this before the driver is
registered. If a property is created after the registration then the
framework is unable to attach a deallocator causing a memory leak during
tear down.

The current DP driver creates a new colorspace property whenever a
new dp connector is initialized. It creates a base connector at probe
time prior to registration. But then it also creates new connectors,
post registration, whenever a new MST dongle is attached to the
topology, causing memory leaks.

This change limits the property creation to the base connector and
attaches the same object to MST connectors to avoid memory leak.

Change-Id: Ib97dc7aac260b4f3f96c1097f58bd276c68501f8
Signed-off-by: Rajkumar Subbiah <rsubbia@codeaurora.org>
2020-08-17 21:20:04 -04:00
Chandan Uddaraju
35b60f6208 disp: msm: add connector API to disable cont_splash resource votes
The panel regulator votes are added by default during
dsi probe to make sure sync state driver doesn't disable
these regulators for cont_splash use case. These regulator
votes need to be removed when cont_splash feature is
disabled. Add a new connector API to handle this.

CRs-Fixed: 2734419
Change-Id: Ie54c8f246877a042afacddaeae8b90440652116f
Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
2020-08-17 16:18:01 -07:00
Amine Najahi
ecc12cd5d2 disp: msm: dp: enable INTF to DP drain rate matching
Enable DP controller hardware feature to modulates the
data drain rate between DP and INTF to reduce chances
of MDP Underflow or DP Overflow.

Change-Id: I7214a2fff957ae35b31c660bafa1d0141eb50680
Signed-off-by: Amine Najahi <anajahi@codeaurora.org>
2020-08-17 13:14:17 -07:00
Veera Sundaram Sankaran
30757e8c8a disp: msm: dsi: add parsing logic for panel gpio pins/address
Add parsing code for getting the TLMM base address and size
of each GPIO pin register space along with the GPIO pins
used for the specific panel. This list is used to lend
these IO ranges to trusted vm during the trusted UI usecase.

Change-Id: I10429cfa14265d52e898815c6cf94be27daa5677
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
2020-08-17 09:47:49 -07:00
Veera Sundaram Sankaran
f7fece8238 disp: msm: parse SPMI registers and append to IO lend list
Parse the display peripheral related SPMI SID/Peripheral
mask from device-tree and get the dynamic register range
of these peripherals using the SPMI API. These registers
are appended to the list of display IO ranges that is
lent from HLOS to trusted VM during trusted UI. This would
help in adding restrictions for SPMI registers on HLOS during
the trusted UI use case along with validation of the register
ranges in trusted VM.

Change-Id: I7077dac7962466e845d061e9ccd205f1bc0ce3ea
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
2020-08-17 09:47:28 -07:00
Steve Cohen
b385a84e0d disp: msm: sde: only program LM size when needed
LM size does not need to be reprogrammed on every frame. Add
a check to only reprogram it when the size changes (or coming
out of power collapse). Some color processing features require
an update when this happens as well (i.e. resolution switch,
partial update, or dest scaler reconfigure). This patch allows
for notifying CP of the updated dimensions when a change occurs.

Change-Id: Ia7f794e53e1f03302c83e442e2a1288611c7c50b
Signed-off-by: Steve Cohen <cohens@codeaurora.org>
2020-08-14 20:24:58 -04:00
Jeykumar Sankaran
a962ce3f02 disp: msm: sde: expose helper api at VM layer
Add helper API's at VM layer to avoid repeated
VM structure dereferencing in rest of SDE files.

Change-Id: I31ee506adbd12c5452bef15da7c468c87b2c9f96
Signed-off-by: Jeykumar Sankaran <jsanka@codeaurora.org>
2020-08-14 16:21:14 -07:00
qctecmdr
20ed4f0785 Merge "disp: msm: sde: disable border color on empty blendstage" 2020-08-13 16:50:24 -07:00
Jeykumar Sankaran
7b50ca2b1e disp: sde: hold an extra PM refcount in trusted VM
pm runtime suspend/resume is not supported in trusted vm since
the power domain is controlled by the primary VM. Hold an
extra refcount on the drm device in trusted vm to avoid pm
runtime calls.

Change-Id: I57c22887eb8b11f8ce318479ca36b84cda385d60
Signed-off-by: Jeykumar Sankaran <jsanka@codeaurora.org>
2020-08-13 16:40:57 -07:00
Amine Najahi
c50713a509 disp: msm: dp: fix DP controller bpc configuration when DSC is enabled
When DSC is enabled, dp controller uses the 8bpc data format to
transfer the data irrespective of the actual input bpc to DSC.

Change-Id: I817093e9726d013f0402bfdddfbccec59a900acc
Signed-off-by: Amine Najahi <anajahi@codeaurora.org>
2020-08-13 19:03:10 -04:00
Amine Najahi
5f59fead53 disp: msm: sde: expand dsc range_bpg_offset to support 10bpc
DSC driver is applying the range_bpg_offset values for 8 bpc/8bpp
to all compression ratios. This results in invalid DSC configuration
in 10bpc mode and sink is not able to decode this image resulting in
black screen.

This change adds a table of range_bpg_offset values to capture the
configuration for different bpc/bpp combinations.

Change-Id: I27e8edcbded8a8e512315599d768750ba473bd60
Signed-off-by: Amine Najahi <anajahi@codeaurora.org>
2020-08-13 17:23:05 -04:00
Amine Najahi
788a4482d0 disp: msm: sde: fix dsc hrd delays register bitmask
Fix bitmask used when programming dsc hrd delays register
to allow 16 bits value.

Change-Id: I0044dcd4bdc4608b40a544b1856dfaa19e1717a3
Signed-off-by: Amine Najahi <anajahi@codeaurora.org>
2020-08-13 10:19:17 -04:00
Yuan Zhao
c810238fb4 disp: msm: dsi: support LP mode for DCS brightness setting
DCS brightness settng can only use HS mode. Add a new
DT property for LP mode choose for DCS brightness setting.

Change-Id: Ibe5867fe344776871eb3a410a8d79d347775f3d4
Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
2020-08-12 23:08:06 -07:00
Lei Chen
f11da41a6e disp: msm: sde: add a property to control display input touch event
Display input touch event is replaced with IOCTL in performance HAL
to early wake up DSI clock.
Add a property to enable/disable display input touch event for backward
compatibility.

Change-Id: Ib6b9123d726e79a2927b05d1ef77c343f01d0c5e
Signed-off-by: Lei Chen <chenlei@codeaurora.org>
2020-08-12 17:32:20 -07:00
qctecmdr
9804031438 Merge "disp: msm: sde: reset ICH on partial update" 2020-08-11 23:12:09 -07:00
qctecmdr
2531751979 Merge "disp: msm: sde: use proper API to retrieve connector state in check phase" 2020-08-11 18:38:29 -07:00
qctecmdr
995409478a Merge "disp: msm: sde: mark LTM as dirty when dest-scaler is updated" 2020-08-11 15:08:55 -07:00
Abhijit Kulkarni
9c9159afdb disp: msm: sde: disable border color on empty blendstage
This change disables the border color on the layer mixer,
based on the caller's request. This is required to totally
disconnect the layer mixer hardware when it is not
participating in blending the pixels. Having empty blendstage
but border color enabled, allows Layer mixer hw to produce
border pixels even when blend stage is empty.

Change-Id: I8e84aeedffbd42ad793a167a6cc5a3a653864c1a
Signed-off-by: Abhijit Kulkarni <kabhijit@codeaurora.org>
2020-08-10 18:29:04 -07:00
Amine Najahi
e7cf04beae disp: msm: sde: use proper API to retrieve connector state in check phase
Use sde_connector_state_get_topology API instead of
drm_atomic_get_connector_state since the latter can
return a blank connector state if not found in
global atomic state.

Change-Id: Ib5b58c6cab438a367a885308341d6bccc624f777
Signed-off-by: Amine Najahi <anajahi@codeaurora.org>
2020-08-10 13:57:14 -04:00
qctecmdr
faf4a8b1c8 Merge "disp: msm: dsi: add debug ability to read TE read pointer line count" 2020-08-06 22:45:51 -07:00