Commit graph

2,045 commits

Author SHA1 Message Date
Linux Build Service Account
8f85eaf84e Merge 5599d64b44 on remote branch
Change-Id: Icc89e8281e8e227fb019faabe38b8241d7d81fe4
2021-10-22 03:12:27 -07:00
Linux Build Service Account
ed7bba7989 Merge 5d29dc4215 on remote branch
Change-Id: I2812971fbc63453c0071dd04e9d9b5c562234837
2021-10-07 02:44:49 -07:00
osaisruj
5599d64b44 disp: msm: dsi: add support for ultra low power state
During lp2 state the load on the panel and
controller regulators can be reduced. Configure ldos
in optimum mode during this state.

Change-Id: I75c180f28f636ebb23ecbe9679ba89c00977fe0f
Signed-off-by: osaisruj <osaisruj@codeaurora.org>
2021-10-01 11:20:21 +05:30
Linux Build Service Account
c6c2e81fe3 Merge f6c68cc1dc on remote branch
Change-Id: I0498fc40a65f732d689a447a553acf15784bf289
2021-09-25 01:06:53 -07:00
qctecmdr
5d29dc4215 Merge "disp: msm: sde: add checks to avoid null pointer dereference" 2021-09-24 05:41:33 -07:00
qctecmdr
46726a0d62 Merge "disp: msm: sde: switch rsc state before CTL_PREPARE in dual display" 2021-09-24 05:41:33 -07:00
Mahadevan
ae98505aae disp: msm: sde: switch rsc state before CTL_PREPARE in dual display
In dual display usecase when both displays comes out of
idle following scenario will cause wr_ptr timeout.

 1. Both displays goes to idle and RSCC enters Mode-2.
 2. Primary display exit idle upon DRM commit N RSC
    enters Solver State.
 3. Secondary display exits idle upon DRM commit M and
    waits on input fence after CTL_1_PREPARE is set.
    RSC is still in CMD state.
 4. Primary Commit N frame transfer got successful and
    commit N+1 is queued in primary display when RSC
    in solver state which leads to timeout in primary.

This is because RSCC will not generate a wakeup in sync with
primary timelines leading to timeout. This is because RSCC
still sees idle low thinking frame transfer is taking long
time. This change will switch the rsc state to AMC mode
before CTL_PREPARE is set which resolves such issue.

Change-Id: Ic32e48b4febbbcc54d94876194d38fe6ef3d0981
Signed-off-by: Mahadevan <mahap@codeaurora.org>
2021-09-22 10:03:27 +05:30
Andhavarapu Karthik
92359a8a2e disp: msm: sde: add checks to avoid null pointer dereference
This change adds required checks to avoid accessing null pointer
where debug bus is not initialised and dumping the debug bus points.

Change-Id: Ia46a4b95706f05e37be660f006c04b1e2e9f6848
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
2021-09-21 14:53:39 +05:30
Ritesh Kumar
d57c2eee47 drm: msm: dsi: Update DSI parser util to skip disabled child nodes
Currently, disabled timing child nodes or power supply nodes are
not skipped because of which status = "disabled" entry does not
work for child nodes. Use of_get_next_available_child to skip
disabled child nodes.

Change-Id: Ib6e4b655f83dd0ee3ffddd496976c34030fa3dc0
Signed-off-by: Ritesh Kumar <riteshk@codeaurora.org>
2021-09-21 02:26:57 +05:30
qctecmdr
f6c68cc1dc Merge "disp: msm: dsi: Fix deadlock issue in debugfs_esd_trigger_check function" 2021-09-17 01:16:52 -07:00
qctecmdr
3e3f681b8a Merge "disp: msm: qpic: fix kw issues in QPIC display driver" 2021-09-17 01:16:52 -07:00
Lei Chen
ad3b81ed30 disp: msm: qpic: fix kw issues in QPIC display driver
This change is updated to address use after free and null checks
in QPIC display driver.

Change-Id: I97f1d941de69aad3d49cbf0c9782022b8f7db840
Signed-off-by: Lei Chen <chenlei@codeaurora.org>
2021-09-13 09:14:57 +08:00
Linux Build Service Account
8a70e5e5b8 Merge 862239a2f3 on remote branch
Change-Id: I3818f310ff14bc4d559a34bd4e639758ff046631
2021-09-11 12:31:01 -07:00
qctecmdr
45aa3e5a37 Merge "disp: msm: sde: clear partial update mask during last close" 2021-09-09 09:42:38 -07:00
qctecmdr
f2a33e5cfe Merge "msm: sde: disp: Set merge_mode after vlut and hist enable" 2021-09-09 09:42:38 -07:00
Srihitha Tangudu
f6d96209a5 disp: msm: dsi: Fix deadlock issue in debugfs_esd_trigger_check function
In debugfs_esd_trigger_check, display mutex is not unlocked in error 
scenario which may lead to deadlock. This change adds fix to handle this.

Change-Id: I44d78959630a49bd1e9dcf871cfc108ac43232db
Signed-off-by: Srihitha Tangudu <tangudu@codeaurora.org>
2021-09-08 15:21:00 +05:30
Anjaneya Prasad Musunuri
1e1c1a4a1c disp: msm: sde: clear partial update mask during last close
Clear partial update mask during last close to avoid
rounded corner to be programmed without valid mask during
shell stop/start operations.

Change-Id: I378adc62b5bc5913abfc32fa3528c8e28ea273d4
Signed-off-by: Anjaneya Prasad Musunuri <aprasad@codeaurora.org>
2021-09-08 01:24:30 -07:00
Ping Li
a83f22243d msm: sde: disp: Set merge_mode after vlut and hist enable
To ensure that set merge_mode after vlut and hist enable, move merge_mode
enable from ltm_init to ltm_vlut.
Redefine the OP_MASK of LTM_INIT_ENABLE and LTM_VLUT_ENABLE, in order to
write the merge_mode bits correctly.

Change-Id: I5258e7f545e265b114098e46d31986274127e962
Signed-off-by: Ping Li <pingli@codeaurora.org>
Signed-off-by: Yuchao Ma <yuchaom@codeaurora.org>
2021-09-08 14:19:46 +08:00
qctecmdr
6c7d4ccc36 Merge "disp: msm: sde: use fixed prefill lines in rscc static wakeup calculation" 2021-09-03 02:17:28 -07:00
qctecmdr
862239a2f3 Merge "disp: msm: fix dsi debugbus in-mem logging" 2021-08-31 21:32:04 -07:00
Jayaprakash Madisetty
b45b583f53 disp: msm: sde: use fixed prefill lines in rscc static wakeup calculation
In dual display during bootup, panel prefill lines may be used in
configuring rscc static wakeup due to ongoing autorefresh in secondary
display. Due to this, there can be a case when transfer time for the
commit is greater than the static wakeup calculated when panel has
large prefill lines(vbp + vpw + vfp) causing janks on primary when
secondary display enters idle and primary display is running. Add changes
to use default_prefill_lines for configuring static wakeup during bootup
when rsc is in clk state. For vid state only, panel prefill
lines will be taken into account for rsc static wakeup calculation.

Change-Id: I3c0ceec984b24b81e3e4d0341f25cdd28f178925
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
2021-08-31 17:48:19 +05:30
qctecmdr
433e1f67b4 Merge "disp: msm: sde: add checks to avoid null pointer dereference" 2021-08-31 01:42:54 -07:00
Yashwanth
9021984e14 disp: msm: sde: add checks to avoid null pointer dereference
This change adds required checks to avoid accessing the
null pointer in case where memory allocation fails while
dumping the registers in memory.

Change-Id: Ic087a1bd041d193820289672d325a78795c48c14
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>
2021-08-30 12:01:14 +05:30
Linux Build Service Account
6906c450b8 Merge a85df97b3a on remote branch
Change-Id: I549b0ad5206a9ce448e5a8ae5877182f583a9a65
2021-08-23 03:01:16 -07:00
qctecmdr
8c8660fcda Merge "disp: msm: assign aspace to gem object for mmap buffer" 2021-08-19 23:46:20 -07:00
qctecmdr
16b3d11221 Merge "disp: msm: sde: remove idle time from Qsync threshold calculation" 2021-08-19 23:46:19 -07:00
Yashwanth
d7d8a487ca disp: msm: assign aspace to gem object for mmap buffer
During gem fault, if aspace value is found to be NULL
pages map request will be failed. This change assigns
nonsecure aspace to gem object before mapping the pages
in such cases.

Change-Id: Ia838fd8a446e21771742ec9d51e30fe08c989e6e
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>
2021-08-19 10:45:46 +05:30
qctecmdr
a85df97b3a Merge "disp: pll: Fix cfg1 value when pclk_src_mux parent is updated" 2021-08-17 01:43:27 -07:00
qctecmdr
b7747c3d23 Merge "disp: msm: sde: hold vmlock only during transition in check phase" 2021-08-13 05:10:34 -07:00
Ritesh Kumar
272f660e76 disp: pll: Fix cfg1 value when pclk_src_mux parent is updated
Currently, PLL_CFG1(1:0) register is updated with cached values
in dsi_pll_enable. This can create issue when UEFI and kernel
cfg1 programming is not same. To fix it, return cached value
of cfg1 when its read in pclk_mux_read, so that pclk_mux_write
is called and cached value is updated. This fix is for 10nm pll.

Change-Id: I8465cb9027a1639f3cdeb02274513ac680f84632
Signed-off-by: Ritesh Kumar <riteshk@codeaurora.org>
2021-08-12 04:08:13 -07:00
Steve Cohen
77d385f62d disp: msm: sde: remove idle time from Qsync threshold calculation
Remove idle time from the Qsync calculation, round down to
the nearest multiple of 4 and remove a couple of extra lines
to compensate for possible latencies. This helps to reduce
the possibility of causing tearing due to the driver calculation
mismatching with the DDIC's expected timeout value.

Change-Id: I8a53a989e26cbd7f0e2b94caa8df8f5bee3ad26c
Signed-off-by: Steve Cohen <cohens@codeaurora.org>
2021-08-11 22:38:04 -07:00
Veera Sundaram Sankaran
2a15e531a3 disp: msm: fix dsi debugbus in-mem logging
Update the dump_mem pointer offset while storing the debugbus
data for the second DSI to avoid overwriting to same memory.
As part of the change, register the DSI ctrl with sde_dbg from
ctrl_init directly, instead of debugfs_init to avoid code replication.

Change-Id: I4089f3038ffa89136eaea956d27270f638a99043
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
2021-08-10 16:02:55 +05:30
Veera Sundaram Sankaran
b8a5bf949a disp: msm: add capability to dump limited debugbus info in logs
Add a flag SDE_DBG_DUMP_IN_LOG_LIMITED based on which the debug bus
registers dumped in log can be limited. In memory logging will continue
to dump the full range of configured registers if that flag is set.
Currently the in-log limited support is enabled  only for the sde/vbif
debugbus and both IN_LOG & IN_LOG_LIMITED will be treated the same way
for other blocks.

Change-Id: Ie85d3d16955cfa507bb3e02954d9b313851eef78
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
2021-08-10 15:37:16 +05:30
Andhavarapu Karthik
75fa44a8ab disp: msm: format register/debugbus dumping in logs
Add macros for logging the registers/debugbus, so all blocks
can use the same macros to keep the log format consistent.

Change-Id: Ie28ce83a742f24f3091bedab66c8cf1454bbb943
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
2021-08-10 15:28:46 +05:30
Andhavarapu Karthik
afafffe4ac disp: msm: refactor debugbus to use same helpers
Refactor the debugbus read/logging for sde/dsi/vbif/lutdma to use the
same helpers. Use function pointers to read/write specific hw block
operations. Remove the DBGBUS_FLAGS_DSPP and related checks  as it is
not used. Increase the debugbus block/test-point ranges for all the
blocks to log all the test-points used by hardware.

Change-Id: I07b23d21f9c556eb7575b892f87ab94adfe41116
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
Signed-off-by: Veera Sundaram Sankaran <veeras@codeaurora.org>
2021-08-10 15:10:06 +05:30
Yashwanth
d7ae274eeb disp: msm: sde: hold vmlock only during transition in check phase
In the current code, vmlock is always acquired in check
phase even if there is no transition between vm's. This
might result in janks if vmlock is held concurrently by
other processes such as backlight update. This change
ensures that vmlock is held only if there is a valid
transition request between vm's in check phase.

Change-Id: I022f04c19ba04fdd5494580cc1436747620b9354
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>
2021-08-10 10:24:59 +05:30
Linux Build Service Account
941705eb28 Merge 043cd065b3 on remote branch
Change-Id: I2b47cac1d65edec01a3df66c64360c397affb34d
2021-08-08 07:33:49 -07:00
qctecmdr
043cd065b3 Merge "disp: msm: sde: increase max size of KMS_INFO" 2021-07-29 21:32:35 -07:00
qctecmdr
75c310ae3e Merge "disp: msm: sde: skip RM reserve for primary in cwb on/off usecase" 2021-07-29 21:32:35 -07:00
qctecmdr
2ffb1dcad6 Merge "disp: msm: sde: add frame trigger count to detect frame count in TE period" 2021-07-29 21:32:34 -07:00
Yashwanth
3f82428a39 disp: msm: sde: add frame trigger count to detect frame count in TE period
When qsync is enabled, if there is a large start threshold
window, there might be a case where two frame transfers
could happen in single TE period if second frame trigger
start is issued within the window and could cause tearing
on the screen. This change adds a atomic variable to detect
multiple frame count and adds vsync wait in such cases to
fix this issue. This variable will be set whenever
wr_ptr_irq arrives and will be reset during rd_ptr_irq.

Change-Id: Ice77b8a717a18d39d70dc08647e15b761ad1c126
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>
2021-07-29 14:44:14 +05:30
Jayaprakash Madisetty
90e249a796 disp: msm: sde: update fence offset during cwb usecase in cmd mode
Add changes to avoid clone_mode encoder for detection of panel mode.
This allows cmd mode display to signal the release_fence right after
pp-done/wb-done interrupt and unblocks any input buffers waiting
on release_fence.

Change-Id: Id87e54f29c960e301d42d49d4763220e6e4cc6f5
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
2021-07-29 10:44:29 +05:30
Jayaprakash Madisetty
4e9b8dc601 disp: msm: sde: clear cwb_enc_mask post in_clone_mode is set
Add changes to clear the cwb_enc_mask in sde_crtc_state post
phys_enc->in_clone_mode is set. This is required to avoid
race issues seen when cwb gets enabled in alternate commits.

Change-Id: I555cc0401b3200f7e8bcc6be8884d04cb3ce69fb
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
2021-07-29 10:40:06 +05:30
Mahadevan
2517261d34 disp: msm: sde: increase max size of KMS_INFO
This change increases the size of KMS_INFO which helps
to accommodate large number of timing nodes for exposure
to userspace.

Change-Id: I32b1f47a32dba8ba62731e522fabd406b023ed69
Signed-off-by: Mahadevan <mahap@codeaurora.org>
2021-07-28 12:38:10 +05:30
Jayaprakash Madisetty
ee9b8ca504 disp: msm: sde: skip RM reserve for primary in cwb on/off usecase
Add changes to skip RM allocation during atomic_check for dsi connectors
which can have a seamless transition during CWB usecase. When CWB gets
enabled in alternate commits N, N+2 on dsi connectors there is back to
back connectors_changed modeset and poll gets enabled for the consecutive
commit N+1, N+3 on rsvp_nxt to get cleared. This rsvp_nxt will be cleared
on drm_atomic_state_put of commit N, N+2, hence atomic_check of commit N+1,
N+3 is blocked until this time causing commit failures.

Change-Id: I06f7a8d9dadb42b6d69201afeff099d554edd98e
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
2021-07-26 14:25:07 +05:30
Linux Build Service Account
871d54c3df Merge a3f4a6ec1a on remote branch
Change-Id: I6fb6c32252a31aef2f6d868e7090f955156a736a
2021-07-23 00:54:02 -07:00
qctecmdr
ad61b3f235 Merge "disp: msm: sde: update rsvp_cur when poll is enabled for rsvp_nxt" 2021-07-22 23:50:57 -07:00
qctecmdr
a3f4a6ec1a Merge "disp: msm: sde: enable merge_3d_active in ctl when mode_3d is set" 2021-07-20 04:26:34 -07:00
Krishna Manikandan
909d927f88 disp: msm: sde: add dim layer check during secure transition
If no planes are staged during non-secure to secure transition,
dim layer should be staged at the highest blend stage. Add
check to fail those commits where dim layer is not staged
in such scenarios.

Change-Id: Ifd49b00a8ff64547ea12751f6c765fd12e55629e
Signed-off-by: Krishna Manikandan <mkrishn@codeaurora.org>
2021-07-15 16:49:33 +05:30
Linux Build Service Account
c2542f71ed Merge 53322c29af on remote branch
Change-Id: I75589ab7483782f28780a15427aa14242e029ff4
2021-07-09 22:16:48 -07:00