Graphe des révisions

1756 Révisions

Auteur SHA1 Message Date
Satya Rama Aditya Pinapala
0a93edbae6 disp: msm: dsi: rework DSI PLL to be configured within PHY
Change avoids clock framework APIs to configure the DSI PHY
PLL. It follows HW recommendation to set the byte and pclk
dividers.

Change-Id: I8c110f3997e4ec4c2eaa28778b70091855725ab8
Signed-off-by: Satya Rama Aditya Pinapala <psraditya30@codeaurora.org>
2021-01-12 23:49:11 -08:00
Linux Build Service Account
819630e6b0 Merge "drm: msm: remove YUV format setting" into display-kernel.lnx.5.10 2021-01-12 22:09:13 -08:00
Linux Build Service Account
999a97304c Merge "disp: msm: dp: change the ext display include file" into display-kernel.lnx.5.10 2021-01-12 22:08:13 -08:00
Yuan Zhao
9a7a0965e6 disp: msm: dp: change the ext display include file
msm_ext_display.h was moved to include/linux/soc/qcom,
change the include file to the right place.

Change-Id: Ib4c668cda1057c44f11105dc14aa0a6f23ec6381
Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
2021-01-13 12:24:11 +08:00
Yuan Zhao
ca8ef48d33 drm: msm: remove YUV format setting
Remove the YUV format setting, will use the upstream code
for YUV mode check.

Change-Id: I24f059ff7cd4cf64f41d7f77bfa6517df0cccfde
Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
2021-01-13 12:20:26 +08:00
Yuan Zhao
73cb7a36c5 disp: msm: sde: remove drm panel callback
For GKI2.0, the old drm_panel_notifier function could not
be used anymore, so removed it.

Change-Id: I858f90d7c39816dc95ab59f88c8988237319eadc
Signed-off-by: Yuan Zhao <yzhao@codeaurora.org>
2021-01-13 12:09:40 +08:00
Ingrid Gallardo
a005a785fe disp: msm: add support to request mdp core clk through mmrm
For Waipio onwards, mdp core clock rate needs to be requested
through the mmrm driver, which will make sure the requested
rate can be sustained by the its power rail, which is shared
by multiple clients.
Current change adds the support to request the mdp core clk rate
through mmrm driver as well as returns the corresponding failures
to user space during when a rate cannot be supported by the
system.

Change-Id: Icc0e8ab5b71e8c99baf7913bdbd96d9504cc11ae
Signed-off-by: Ingrid Gallardo <ingridg@codeaurora.org>
2021-01-12 14:07:00 -08:00
Nilaan Gunabalachandran
e37d7dd1b6 disp: msm: sde: store drm panel in sde connector
Drm panel pointer is no longer available in the drm connector.
This change stores the drm panel in the sde connector.

Change-Id: Ia7ed35d1f0914c45e34f15b02c8a3d8c32292ee6
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2021-01-11 12:12:08 -05:00
Nilaan Gunabalachandran
53cc166889 disp: msm: sde: increase wb max width/height
This change adds support to enable maximum output line width of
5120 for wb connector.

Change-Id: I25d34e804cbf16af9eb9f78cd4146fa2023ff935
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2021-01-05 09:33:01 -08:00
orion brody
d00d481360 disp: msm: move from drm_mode to msm_mode
Move away from the private and private_flags fields from drm_mode,
as it is being deprecated in latest kernel version. Instead, Add
msm_display_mode as a wrapper to be used in downstream to store these
parameters. Also, store msm_mode in connector_state to be accessed
in commit path.

Change-Id: Ia5bdebe75f00aa15fb7db4dc3a0d50c30894a95c
Signed-off-by: Orion Brody <obrody@codeaurora.org>
2021-01-04 13:18:36 -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
orion brody
dee5134f1e disp: msm: add private mode_seamless flag
This change adds DRM_MODE_SEAMLESS to private flags downstream,
as it was deprecated from drm UAPI. Additionally, this will
update the is_mode_seamless function to access the seamless
flag from private flags.

Change-Id: Idea0b4ac8e71063c000f582d3228bc0a50a6a8e6
Signed-off-by: orion brody <obrody@codeaurora.org>
2020-12-17 12:10:48 -08:00
Nilaan Gunabalachandran
fa4d168b27 disp: msm: sde: add Waipio version checks
Add version checks for Waipio (MDSS v8.1.0) and enable
all lahaina features.

Change-Id: I9b19af98878cf3c6abbe06a74f88f4fd99ff4959
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 12:48:58 -05:00
Samantha Tran
ee58486c84 disp: msm: move vblank enable and disable to crtc hooks
Upstream now prefers to utilize vblank enable and disable
through crtc hooks rather than drm driver. Remove
calls from kms vblank enable/disbale.

Change-Id: Ic6911838f14f93a0d277b7bdc2c1968270ec25a2
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 10:25:06 -05:00
Samantha Tran
c53a07ee48 disp: msm: dp: Move required drm_dp_link functions to downstream
On the latest kernel, several drm_dp_link functions were removed.
This change moves the functions needed downstream.

Change-Id: I0a76c52edff450d8bd33edffb9da41c1933b9681
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 10:06:32 -05:00
Nilaan Gunabalachandran
edc49ec57e disp: msm: dp: add parameter to pass PBN divider
Commit 1c6c1cb5afc7 ("drm/dp_mst: Manually overwrite
PBN divider for calculating timeslots") adds a parameter
enabling PBN divider to be overriden. This change updates
the dp driver to set this to 0, which will not override
by default.

Change-Id: I902acc29508f4d32abd34d616b4024e51ee71fd7
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 10:06:32 -05:00
Samantha Tran
af5aee268a disp: msm: dp: dp detect port
Commit 3f9b3f02dda5 ("drm/dp_mst: Protect drm_dp_mst_port
members with locking") adds locking while detecting mst ports.
This change updates the dp driver to pass in the ctx which
is acquired at that time.

Change-Id: I8e5ba9648494f9b4f8fa3d1654ec22dd2502e0b0
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 10:06:32 -05:00
Samantha Tran
f01cd2c0e1 disp: msm: dp: dp mst cb remove register and destroy connector
Commit 72dc0f515913 ("drm/dp_mst: Remove
drm_dp_mst_topology_cbs.destroy_connector and
commit a5c4dc165957 ("drm/dp_mst: Remove register_connector callback")
deprecate certain call back APIs in DP MST. This changes updates the
DP driver to remove the APIs and register the connector through
drm_register_connector.

Change-Id: Id553a95b930479c216be1744cce00a943575571e
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 10:06:32 -05:00
Samantha Tran
5de10845c6 disp: msm: dp: dp connector mutex lock renamed
Commit 7cb12d48314e ("drm/dp_mst: Destroy MSTBs asynchronously")
renames the connector destroy lock. This changes updates the
dp driver to use the updated lock.

Change-Id: I23b3d2c5a661b894c97468490c1afee70daac0bf
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 10:06:32 -05:00
Samantha Tran
2616e57a0a disp: msm: encoder_ids replaced in drm_connector
Commit 62afb4ad425a ("drm/connector: Allow max possible encoders
to attach to a connector") enables additional encoders per
connector through use of a mask rather than encoder ids.
This change updates the driver when looking for an encoder
for the connector to look through the list of all possible encoders.

Change-Id: I69cc7c38cd0a9842ed2f15712feeb3c6b88daadf
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
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
e199ecbfb8 disp: msm: remove debugfs_create_u32 return value
Commit 2b07021a940c ("debugfs: remove return value
of debugfs_create_u32()") removes the return value
from debugfs_create_u32. This change updates the msm
driver to remove cehcks on this return and corrects
for unnecessary line wraps.

Change-Id: I8d50dd7168921edfb2d5edad13941f91117d3c30
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
c5d2fba4e7 disp: msm: use drm_debug_enabled for printing
Commit 959b077f26a1 ("drm/print: move drm_debug
variable to drm_print.[ch]") moves drm_debug variable used
for debug pring messages. This change updates the msm driver
to leverage drm_debug_enabled for printing logs.

Change-Id: If7ba8e10c2890ef1353097338b15ad391c0d2336
Signed-off-by: Samantha Tran <samtran@codeaurora.org>y
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 09:58:38 -05:00
Samantha Tran
790eda032e disp: msm: drmP.h removed, add new headers
Commit ("drm: delete drmP.h + drm_os_linux.h") removes the
drmP header file. This changes updates the msm driver
by adding the individually required header files.

Change-Id: I360aa028c2ce75317d33da988b36164041177014
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 09:50:47 -05:00
Samantha Tran
bb6569b1ab disp: msm: gem_free_object removed from drm
Commit 1a9458aeb8eb ("drm: remove drm_driver::gem_free_object")
deprecates gem_free_object. This changes updates the msm driver
to call msm_gem_free_object from gem_free_object_unlocked.

Change-Id: If6bd6252232045975357e1bdfbeae6017b0f2ed5
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 09:49:19 -05:00
Samantha Tran
57c40f17c2 disp: msm: remove usage of DRM_DEBUG_DRIVER_RATELIMITED
Commit 7ff6ea0fd384 ("drm/print: Delete a few unused
shouting macros") removes the usage of
DRM_DEBUG_DRIVER_RATELIMITED. This changes updates
the relevant changes to the msm driver, printing through
DRM_DEBUG instead.

Change-Id: I910f0fe72d045e69dda966249437dcd004790f29
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 09:49:19 -05:00
Samantha Tran
b5784e4724 disp: msm: dp: renaming DP_TEST_PHY_PATTERN
Commit 4342f839ae7e ("drm/dp: get/set phy compliance pattern")
swaps TEST_PHY with PHY_TEST in drm_dp_helper header file. This
changes updates the relevant changes in the dp driver.

Change-Id: I5c24a100022277388af530c526f169a03c6df889
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
Signed-off-by: Rajkumar Subbiah <rsubbia@codeaurora.org>
2020-12-17 09:49:19 -05:00
Samantha Tran
6fa94ff382 disp: msm: rename drm_gem_object_put functions
Commit b5d250744ccc ("drm/gem: fold drm_gem_object_put_unlocked
and __drm_gem_object_put()"), commit eecd7fd8bf58 (drm/gem: add
_locked suffix to drm_gem_object_put", commit be6ee102341b ("drm:
remove _unlocked suffix in drm_object_put_unlocked") updates
the drm_gem_object_put call APIs. This change updates the relevant
changes to the msm driver.

Change-Id: I006b51b5f3d1f8b2e88ed7b4c73b5a98afcaf455
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-17 09:49:19 -05:00
Samantha Tran
640ada10b5 disp: msm: updates to msm_drv
Commit c368ec194dd0 ("drm/client: Rename _force to _locked"),
commit 4bdc0d676a64 ("remove ioremap_nocache and devm_ioremap_nocache") and
commit 595abbaff5db ("y2038: remove ktime to/from timespec/timeval
conversion") renames modeset_commit_force, renames devm_ioremap_nocache and
removes the usage of timespec. This changes updates the msm driver with
the relevant changes.

Change-Id: Ib7372b8b4e51cdf75771e5069be189be76c32ed4
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-16 17:28:03 -08:00
Samantha Tran
0c08cb1fb5 disp: msm: update parameters for drm_bridge_attach
Commit a25b988ff83f ("drm/bridge: Extend bridge API to
disable connector creation") and commit ee68c743f8d0 ("drm: Stop
including drm_bridge.h from drm_crtc.h) add additional input flags.
This change adds fixes to the drm bridge attach API and includes
relevant drm_bridge header files.

Change-Id: I85e84eaff7df2995243896108a217fae81716b63
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-16 17:27:46 -08:00
Samantha Tran
e68e102598 disp: msm: replace rpmh_flush with rpmh_write_sleep_and_wake
Commit d5e205079c34 ("drivers: qcom: rpmh: remove rpmh_flush export")
deprecates the rpmh_flush API. This change replaces the API with
rpmh_write_sleep_and_wake.

Change-Id: I1fb708b265d8abd981b099eb65b50d6cc73cc64d
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-16 17:26:04 -08: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
Samantha Tran
3d1a54ed8d disp: msm: dp: drm_dp_calc_pbn_mode includes dsc enable/disable bool
Commit dc48529fb14e ("drm/dp_mst: Add PBN calculation for DSC modes")
adds support for handling fractional bpp values for dsc usecases.
This change sets this to false since the driver uses unadjusted bpp.

Change-Id: I10b4a74fd512c5ffb333f8664effb5efb8ea6c4e
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-16 17:25:38 -08:00
Samantha Tran
16cc165833 disp: msm: obtain bridge from bridge chain
Commit 05193dc38197 ("drm/bridge: Make the bridge chain
a double-linked list") creates a bridge chain linked
list. This change updates the relevant changes to msm
driver to use the list to find the bridge associated to
the encoder.

Change-Id: I59eb2910be96f4fff7bdbeb040d6ad204c41d747
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-16 17:24:59 -08:00
Samantha Tran
4b150347fc disp: msm: dp: use full_pbn instead of available_pbn
Commit fcf463807596 ("drm/dp_mst: Use full_pbn instead of
available_pbn for bandwidth checks") changes bandwidth checks
to look at the Full PBN bandwidth rather than the available PBN.
This change updates the relevant changes to the dp driver.

Change-Id: I2a713a9b6fd10314bd768331dcea00950b6edf7f
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-16 17:20:53 -08:00
Samantha Tran
6d65c2b613 disp: msm: dsi: pass drm_display_info to mode_valid
Commit 12c683e12cd8 ("drm: bridge: Pass drm_display_info to
drm_bridge_funcs .mode_valid()") passes the drm_display_info to
mode valid. This change updates relevant changes to dsi display,
that will make it available during bridge validation.

Change-Id: I2772e9e3920de940f22341be5019213d562352ff
Signed-off-by: Samantha Tran <samtran@codeaurora.org>
Signed-off-by: Nilaan Gunabalachandran <ngunabal@codeaurora.org>
2020-12-16 17:20:28 -08:00
qctecmdr
554a3b8b06 Merge "disp: msm: dp: validate edid before dereferencing" 2020-12-14 09:56:07 -08:00
qctecmdr
e0695d4236 Merge "disp: msm: sde: cleanup ctl/intf registers on cmd encoder disable" 2020-12-12 22:39:19 -08:00
qctecmdr
93331df7d7 Merge "disp: msm: dsi: enable DMA cmd scheduling for video mode panels" 2020-12-11 09:49:33 -08:00
Rajeev Nandan
e60959b052 disp: msm: dsi: move backlight operations to post kickoff
This change moves the backlight update operation from
drm bridge enable to connector post kickoff.

When timing engine is enabled with programmable fetch
enabled, the timing engine will start counting from
the prog_fetch_start point (which is somewhere in VFP).
It’s a grey area from that point to the actual panel
vsync and SW should not trigger DMA command during that
time.

During display resume, sometimes the INTF timing engine
do not get enabled completely at the first vblank irq.
The backlight update cmd transfer trigger as part of the
drm bridge enable can also take place at the same time,
that may cause DSI cmd transfer failure.

Change-Id: I2722d3c23012ef0e7bcc7f728ec5658318ce4e60
Signed-off-by: Rajeev Nandan <rajeevny@codeaurora.org>
2020-12-11 12:14:54 +05:30
Veera Sundaram Sankaran
030e3f15a7 disp: msm: sde: cleanup ctl/intf registers on cmd encoder disable
The SDE RM determines the number of displays enabled in cont-splash by
checking the INTF_ACTIVE bits in the ctl. The trusted-vm relies on the
same cont-splash path during transitions and the stale ctl INTF_ACTIVE
on dual display usecases leads to wrong status check. Currently, only
video/wb encoders use the phys_encoder disable helper during encoder
disable to clear out few ctl/intf registers. Extend it for cmd encoder
as well to remove the stale entries.

Change-Id: I7f21ef46178ce3943ee85abdf29f7cdef93d7c52
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
2020-12-10 18:37:34 -08:00
Rajeev Nandan
37b2f80ad4 disp: msm: dsi: enable DMA cmd scheduling for video mode panels
This change enables the DMA CMD scheduling as default for
video mode panels.

In video mode panel, if the DMA is triggered very close to
the beginning of the active window and the DMA transfer
happens in the last line of VBP, then the HW state will
stay in ‘wait’ and return to ‘idle’ in the first line of VFP.
But somewhere in the middle of the active window, if SW
disables DSI command mode engine while the HW is still
waiting and re-enable after timing engine is OFF. So the
HW never ‘sees’ another vblank line and hence it gets
stuck in the ‘wait’ state.
Scheduling the DMA cmd to the first line in VFP fixes
this issue.

Change-Id: If9e5bd1923c012f10dee50c791a2b2b001d97553
Signed-off-by: Rajeev Nandan <rajeevny@codeaurora.org>
2020-12-10 04:19:33 -08:00
qctecmdr
5caf284ecc Merge "disp: msm: dp: handle link maintenance failures" 2020-12-08 04:44:42 -08:00
qctecmdr
a493aaf3a2 Merge "disp: msm: sde: flush all event thread work during CRTC disable" 2020-12-08 04:44:42 -08:00
qctecmdr
874ebfeeae Merge "disp: msm: dp: fix page fault from hdcp buffer access" 2020-12-08 04:44:42 -08:00
qctecmdr
285589db6a Merge "disp: msm: sde: update encoder atomic check during qsync usecase" 2020-12-07 23:37:28 -08:00
qctecmdr
59a266aa8e Merge "disp: msm: dsi: Add support for 5nm C-PHY shadow clock" 2020-12-07 17:09:16 -08:00
qctecmdr
ef242b391f Merge "disp: msm: dsi: trigger broadcast commands using DMA start window" 2020-12-07 17:09:16 -08:00
Sudarsan Ramesh
c6b636fe0b disp: msm: dp: validate edid before dereferencing
Currently, when using custom edid from debugfs, the
extensions data inside the edid block is not validated
before dereferencing the extension block.

The fix adds a edid validation function to validate
any custom edids before accessing any members in the
edid block.

Change-Id: I8a2cc45477416a8f8c4cff882bd53d14012e29f4
Signed-off-by: Sudarsan Ramesh <sudarame@codeaurora.org>
2020-12-07 10:02:42 -08:00