Gráfico de commits

89 Commits

Autor SHA1 Mensagem Data
Satya Rama Aditya Pinapala
c3c683472d disp: msm: dsi: remove custom upstream MSM DSI flags
Change removes the use of custom MSM DSI flags that will not be
available as part of GKI.2.0

Change-Id: I2337a54b1d6346ebdc18e9e6c3c8e7a07f421bdd
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2021-01-15 17:55:19 -08:00
Lei Chen
8cdb80455f disp: msm: dsi: update panel commands for panel operating mode switch
Update panel commands to support panel operating mode switch in
one timing node.

Change-Id: Ieb8303cebe78c699dfd5f274830418e87655ff56
Signed-off-by: Lei Chen <chenlei@codeaurora.org>
2021-01-13 07:43:52 -08:00
Lei Chen
ab3f86f918 disp: msm: use connector properties to expose and set panel mode
Expose panel mode from kernel to SDM with SDE connector property
CONNECTOR_PROP_MODE_INFO and set panel mode from SDM to kernel
with SDE connector property CONNECTOR_PROP_SET_PANEL_MODE for
avoiding private change in upstream code in QGKI kernel.

Change-Id: I0629dad9399967cc1118ac02ce30597076ca367d
Signed-off-by: Lei Chen <chenlei@codeaurora.org>
2021-01-13 23:40:22 +08:00
Samantha Tran
262099e94a disp: msm: replace kzfree with kfree
This change replaces kzfree with kfree as kzfree has been
renamed.

While moving to the latest 5.10 tip, additional small changes
were required to resolve compilation issues:

set_dma_ops has moved from dma-mapping to dma-map-ops header.
This change includes the new header file required.

drm_panel_add returns void, this change removes the expected
return value check.

drm_prime_pages_to_sg takes an additional parameter. This change
passes in the drm_device pointer the function is looking for.

Remove an unused variable in sde_crtc vblank function.

Change-Id: I47c085c0cb64432873c2e750ae64cbdc2b5340da
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
2020-12-22 10:42:18 -08:00
Samantha Tran
da5f5ff1ae disp: msm: fix always true/false conditionals
Remove unnecessary error conditionals that are
always true or false.

Change-Id: Ied1041b3165647364b741d3d95edca85039491c2
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 09:58:38 -05:00
Samantha Tran
df3f51f9c4 disp: msm: replace PTR_RET with PTR_ERR_OR_ZERO
Commit fad7c9020948 ("err.h: remove deprecated PTR_RET for good")
deprecated PTR_RET. This change updates the msm driver by
replacing it with PTR_ERR_OR_ZERO.

Change-Id: Ibe8cefd7b9ce27dc63886eb3861aab5fc8ba268a
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 09:58:38 -05:00
Samantha Tran
d2aea44026 disp: msm: dsi: drm_panel_init parameter change
Commit 6dbe0c4b0fc0 ("drm/panel: Initialise panel dev and funcs
through drm_panel_init()") and commit ba2fad4c9648 ("drm/panel:
Add and fill drm_panel type field") modify input parameters for
drm_panel_init. This change updates the relevant changes to the
dsi driver by passing in the device and panel type.

Change-Id: I76a271fea08190bd8633831442ca48882f8a97e6
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-16 17:25:54 -08:00
Veera Sundaram Sankaran
c99f3fd6ae disp: msm: dsi: enable ESD trigger through debugfs in trsuted-vm
Add support to trigger ESD through debugfs by directly
modifying the reset GPIOs TLMM register in trusted-vm as GPIO
driver support is not enabled.

Change-Id: I859affe69c13dbe115a48b0a63a600a57027db58
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
2020-11-12 23:34:22 -08:00
Veera Sundaram Sankaran
6dd2c3cd87 disp: msm: dsi: parse & store gpio registers used by the host & panel
Parse all the GPIO pins used by the DSI host and the display panel
along with its register ranges and store it in panel struct. This
avoids parsing the device-tree everytime during transitions between
trusted and primary vm.

Change-Id: Ibbb646358c0409703afda1c4f758f044fc8c0001
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
2020-11-12 22:27:10 -08:00
Satya Rama Aditya Pinapala
bbe18a1689 disp: msm: dsi: batching multiple DSI commands using debugfs node
The change batches DSI commands sent using the debugfs node, in a
separate buffer from the TX command buffer to ensure that they are not
triggered before the last command bit is set. Once the last command
bit is set the buffer is then copied to the DSI TX buffer and triggered.

Change-Id: I9ba624e4e19341696a974994817603315c6c8a45
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-10-21 15:25:48 -07:00
Raviteja Tamatam
e5ff0b8f30 disp: msm: sde: add support for qsync min fps list
In current implementation qsync min fps is single value.
It is same for all the list of supported dfps list.
Added support for new dt entry dsi-supported-qsync-min-fps-list
corresponding to the fps supported in the dfps list
dsi-supported-dfps-list.

Change-Id: Ifd5309c2f51865a3c0d9fadb65cbcd291b6ef42b
Signed-off-by: Raviteja Tamatam <travitej@codeaurora.org>
2020-10-15 12:32:25 +05:30
Rajeev Nandan
19a54c5650 disp: msm: dsi: enable xlog in critical paths
Enable xlog in critical paths to increase debug coverage.

Change-Id: I177acd3f2c2ab349f533bb9fbd8a8122539d524b
Signed-off-by: Rajeev Nandan <rajeevny@codeaurora.org>
2020-09-16 13:00:11 +05:30
qctecmdr
20db960f01 Merge "disp: msm: dsi: do not enable PWM when setting bl to 0" 2020-09-09 18:55:26 -07:00
Zhao, Yuan
8050179062 disp: msm: dsi: do not enable PWM when setting bl to 0
Check backlight value, if it's 0, do not enable PWM.

Change-Id: I6fccb42555731bf3faa88a93cbf1a36a417ff49d
Signed-off-by: Zhao, Yuan <yzhao@codeaurora.org>
2020-09-08 19:02:14 -07:00
Ritesh Kumar
269ead80c7 disp: msm: dsi: Add support to keep display reset pin high
This change adds support to keep display reset pin high during
suspend state.

Change-Id: I8fab43d8f7b30fce72cc95277d016b72b914aa99
Signed-off-by: Ritesh Kumar <riteshk@codeaurora.org>
Signed-off-by: Steve Cohen <cohens@codeaurora.org>
2020-08-25 19:14:56 -04: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
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
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
Satya Rama Aditya Pinapala
ec6f97fd9d disp: msm: dsi: update min prefill lines for lahaina
Change updates minimum prefill lines for lahaina target.

Change-Id: Ic3c4f498eb2b73ddfc4445d94850c72dd242d575
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-08-06 17:26:26 -07:00
Satya Rama Aditya Pinapala
50af1eb43b disp: msm: dsi: add support for DMA CMD scheduling for CMD mode panels
The change allows for configuring a command DMA window during which
the command is triggered. The DMA window must not intersect with the
MDP tear check window. Once the command transfer is successful, the
trigger control needs to reset to the default DMA trigger specified
by the panel.

Change-Id: I5485ca1f8e141ed92dc8c77c2daf579634271022
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-08-05 20:31:24 -07:00
qctecmdr
da06015241 Merge "disp: msm: dsi: update MDP/DSI transfer time calculation" 2020-07-24 14:10:39 -07:00
Yuan Zhao
b54107cfa3 disp: msm: dsi: add a new PWM pinctrl configure
The default PWM gpio pin mode was not right for PWM backlight
control. If needs to use PWM backlight, must config the
gpio pinctrl.

Change-Id: I5fd6b947d379b53ef4c358be1b935a2ad4970f99
Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
2020-07-23 19:54:02 -07:00
Satya Rama Aditya Pinapala
ab5d2638de disp: msm: dsi: update MDP/DSI transfer time calculation
This change ensure that in cases panel transfer time is specified,
the final transfer time is calculated in accordance with the minimum
threshold time allowed.

Change-Id: I3442d4d3e8a27ec30d93725cb96b229bb94f2ce2
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-07-23 18:55:40 -07:00
Satya Rama Aditya Pinapala
19c01f38bc disp: msm: dsi: drive backlight enable gpio low during power off
Change drives the LCD panel backlight enable GPIO low during panel
power off sequence.

Change-Id: Icfd22cf8d5216fcff857bbeab9c183dfb02b83bd
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-07-19 23:14:20 -07:00
Jeykumar Sankaran
4b27380f07 disp: msm: dsi: reuse continuous splash path for trusted vm
Display in trusted VM works in a handover mode i.e, all
display components need to be initialized by the primary VM
before switching to trusted VM on the usecase boundary.
That makes it a hard requirement for the trusted VM not to
re-program any of the display configuration registers before
it could hand the HW back to the primary VM.

Also, most of the linux framework drivers including pintrl, clocks
are not enabled in the trusted VM.

In order to address the above two limitations and to control the
probe/commit sequences, this change adapts the same path as that
of continuous splash to bypass some of the critical functions
which are identified to be HW intrusive. Based on the DT property
read from SDE handle, dsi drivers will choose to bypass
enable/disable HW state updates when executing in the vm environment.

Change-Id: Ica71c924d189ab65fe3be5b0ac870633e3b749e1
Signed-off-by: Jeykumar Sankaran <jsanka@codeaurora.org>
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
2020-07-12 15:00:09 -07:00
Dhaval Patel
83860f0642 disp: msm: pass free dsc and lm availability info to dp
Primary and secondary dsi displays are built-in displays
and they are supported during all concurrency usecases
without resource allocation failure. DP mode filter
logic should provide supported mode information based
on free mdp resources after dsi resource assignment.

Change-Id: I3a9637a91ea1ffcc31997e25caff7f13605283ac
Signed-off-by: Dhaval Patel <pdhaval@codeaurora.org>
2020-06-07 22:57:26 -07:00
Satya Rama Aditya Pinapala
2c4a439950 disp: msm: dsi: update threshold time for high refresh rate
Use lower frame threshold time for high refresh rates. For resfreh rates
greater than 120 FPS the threshold time is 500us.

Change-Id: Ie5a37c0eec6c2c2cbf90e039eb6b15bc7edd2492
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-05-28 10:06:11 -07:00
Yuan Zhao
f2819c58d2 disp: msm: dsi: fix the error log print level
Since some property of panel dtsi were not a must.
Do not report errors for panel bindings that are
not mandatory.

Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
Change-Id: Ie899081e2ca93740ceb854457b61e5fc5d2083fa
2020-05-20 21:26:02 -07:00
Yuan Zhao
5139cad2d4 disp: msm: dsi: update PHY configuration to support cphy
Add support to read cphy boolean flag from panel dtsi
and configure DSI PHY registers accordingly. Update the
bit/byte clock calculation according to cphy specifications.
Update clock parents so that the relevant divider blocks
are configured to support cphy.

Change-Id: Iaca61eec01a488657b086f59910c52f8c79e26a4
Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
2020-05-14 21:00:07 -07:00
Satya Rama Aditya Pinapala
43069ad44a disp: msm: dsi: use panel's force_clk_lane_hs instead of phy's
In order to make dsi panel and dsi2hdmi panel compatible,
delete "qcom,panel-force-clock-lane-hs" property in phy and
use display panel's force_clk_lane_hs property.

Change-Id: I490e08b2ee859797c2b3aeddf109a3a4286fb922
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-05-14 21:00:02 -07:00
Wenjun Zhang
b55a29b194 disp: msm: add inverted display brightness value property
In general the brightness value, the first parameter is low byte and
the second is high byte, but some DDIC invert, so add inverted display
brightness value property.

Change-Id: I8bf5631bb66096bd28529c53643e358afffce18e
Signed-off-by: Wenjun Zhang <wjzhan@codeaurora.org>
2020-05-07 05:37:52 -07:00
qctecmdr
a2a04712a9 Merge "disp: msm: update VDC-m hardware version in display driver" 2020-05-04 23:32:46 -07:00
qctecmdr
6a5956b36e Merge "disp: msm: make msm_drm as module for GKI" 2020-04-28 23:51:44 -07:00
Chandan Uddaraju
fa8f623802 disp: msm: dsi: move panel regulator votes from bind to probe
Add vote for panel regulators in dsi probe to make sure
panel regulators are ON until dsi bind is completed
for cont-splash enabled usecase. Remove this panel regulator
vote when dsi component bind is done.

Change-Id: I0b1d43fa1b16385712abc1d8aaa0e778f31ba634
Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
2020-04-28 12:08:21 -07:00
qctecmdr
9794834cc5 Merge "disp: msm: dsi: avoid seamless request for cwb transitions" 2020-04-23 09:09:01 -07:00
Abhinav Kumar
b55251f17f disp: msm: update VDC-m hardware version in display driver
Update the VDC-m hardware version in the display driver as per
the latest programming guidelines.

Change-Id: I0073cb7b713599de43f2a675202390df3b4a1d58
Signed-off-by: Abhinav Kumar <abhinavk@codeaurora.org>
2020-04-21 18:37:57 -07:00
Lipsa Rout
e009f7f81f disp: msm: dsi: Update mode population logic for POMS feature
This change adds support to populate one command mode for
video mode panels supporting panel operating mode switch
feature.

Change-Id: I850b889ebfa8c2ee1406ad946061b96143537b09
Signed-off-by: Lipsa Rout <lrout@codeaurora.org>
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-04-20 09:59:22 -07:00
Lipsa Rout
9cf9c8e99b disp: msm: dsi: Fix the total number of modes calculation
This change updates the parsing of timing nodes to check
the mode of operation as video or command. In command mode,
for each timing node, num of supported dfps rate is always
one. Accordingly, update the num_dfps_rate to 1 for
command mode.

Change-Id: I5098c7e0d4d2320609d6e10031eaef78c1d8b3c1
Signed-off-by: Lipsa Rout <lrout@codeaurora.org>
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-04-20 09:59:14 -07:00
Nilaan Gunabalachandran
a5cae7c0f3 disp: msm: dsi: make panel commands async for vid to cmd switch
Optimize pre mode switch panel command by transferring async. This
removes the time waited until subsequent dma_done irq.

Change-Id: I2e2516fdd641e85d1f1b221a6ea7999c868edf00
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-04-19 14:13:13 -07:00
qctecmdr
25062d1965 Merge "disp: msm: dsi: add return code to probe deferral error logs" 2020-04-10 09:39:57 -07:00
Rajkumar Subbiah
56e041919c disp: msm: dsi: add widebus support for DSI
From Lahaina onwards, for compressed DSI output, widebus should be enabled.
In widebus mode, 6 bytes of data are transmitted per pclk.
For uncompressed output, widebus must be disabled to transmit 3 bytes
of uncompressed data per pclk.

Change-Id: I7fc0bdb2e1678152d57b4cbb8295063a2ba8ae73
Signed-off-by: Rajkumar Subbiah <rsubbia@codeaurora.org>
2020-04-09 14:15:13 -04:00
Satya Rama Aditya Pinapala
f93224bc4b disp: msm: dsi: add return code to probe deferral error logs
This change adds return code -EPROBE_DEFER to DSI error logs during
a probe deferral.

Change-Id: I59971ebc319e90d65f64e73149e34ba691441741
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-04-09 10:39:20 -07:00
qctecmdr
34b32d77f8 Merge "disp: msm: dsi: disallow backlight update during panel mode switch" 2020-03-20 20:33:23 -07:00
Lei Chen
8fbd145c74 disp: msm: dsi: update panel mode parsing message for POMS
It should not be an error that panel mode isn't specified
in timing node, so add this change to lower the log level
from error to info.

Change-Id: I49bd1fec1c09697d9829a8e0767dfa3cf2cff512
Signed-off-by: Lei Chen <chenlei@codeaurora.org>
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-03-17 19:31:12 -07:00
Lipsa Rout
5e09ea2aed disp: msm: dsi: Add support for clk switch with constant FPS
There is lag or lead in the FPS during dynamic clock change,
along with the increment or decrement in clock. So, HFP or
VFP are adjusted to ensure a constant FPS.

Change-Id: I87ba7a185104a0f5f1d13734a7e487e728d6b2c0
Signed-off-by: Lipsa Rout <lrout@codeaurora.org>
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2020-03-17 19:30:26 -07:00
Prabhanjan Kandula
45af4566d9 disp: msm: dsi: add support for spr enable from panel config
This change parses SPR enable entry from panel device tree and
populates SPR specific information in panel data structure.
Valid entry of SPR pack type is treated as panel requirement
to enable SPR for specified pack type from source end. This change
also populate connector capabilities blob with SPR pack type.

Change-Id: I9d9ab8a990476fba281e12890bf3f7b17a174d79
Signed-off-by: Prabhanjan Kandula <pkandula@codeaurora.org>
2020-03-16 22:04:40 -07:00
Narendra Muppalla
cd1e996b44 disp: msm: defer panel TE disable with poms switch
DSI host vsync is expected to align with panel internal vsync
during transition from command mode to video mode operation.
In order to facilitate this, keep panel TE enabled in video mode
operation until it is aligned with vysnc.

Change-Id: I3fc59b01336b30cd436be332af6953c5a01be7fd
Signed-off-by: Narendra Muppalla <NarendraM@codeaurora.org>
2020-03-10 16:37:21 -07:00
Abhinav Kumar
64ee2c4d72 disp: msm: dsi: add generic API for calculating horizontal timings
Add a generic API which calculates the horizontal timings based
on the compression type in case compression is enabled and even
for non-compression cases.

Replace the usage of the DSC macros with this generic API.

Change-Id: Ie9174c20adc51a0be7c9127529d41faa4b473b55
Signed-off-by: Abhinav Kumar <abhinavk@codeaurora.org>
2020-01-29 13:46:33 -08:00
Abhinav Kumar
3e0f65f882 disp: msm: program DSI compression registers for VDC-m
Add the support to program DSI compression registers
for VDC-m. These are calculated based on the VDC parameters
and mode information.

Change-Id: I09b163a496842331d5f2a78371f380180b3a15b8
Signed-off-by: Abhinav Kumar <abhinavk@codeaurora.org>
2020-01-29 13:44:32 -08:00