Some panels may require that the DSI link returns to the low-power
stop state (LP11) after transmission of every line. If a panel
requires that the DSI link returns to LP11, apply the LP11
insertion between lines feature.
This change adds support to
- Disable the command mdp burst mode
- Enable mdp idle ctrl
- Program the No. of dsi pclk cycles of idle time to
insert between command mode mdp packets. The idle time
must be long enough to cover the time link takes to
switch between HS to LP11 mode.
Change-Id: Ie718d334f05ce6c1ecd1a05b379bbbe18dec6330
Signed-off-by: Ritesh Kumar <riteshk@codeaurora.org>
In ESD register read validation, a for loop is used to increment a
local variable with the length of ESD command. But this is unused
in the validation of the read data. This change removes the unused
for loop.
Change-Id: I6d1a9233061ee33a2b5390e2f922a2412af7d605
Signed-off-by: Ritesh Kumar <riteshk@codeaurora.org>
Imbalance power vote caused with below scenario:
1. Primary display running with CWB enabled.
2. Idle-PC has kicked in causing primary and cwb encoder to rc_idle state.
3. Post idle-PC with DMS switch enabled along with CWB.
Changes made are to avoid pre_modeset and post_modeset callbacks
for CWB encoder as it not required and it puts a unnecessary power
vote causing power issues in suspend usecase.
Change-Id: I95b7ba093484f50be5f575cafa63a02e8fbca441
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
This change avoids upstream drm issuing drm_atomic_commit in
drm_fb_release which is leading to artifacts on screen or
atomic_check failures due to atomically unstaging each fb
from plane_state and committing remaining planes on hardware.
a) This patch moves the state operations for setting crtc to
connector state to a helper api.
b) This patch clears any dim_layers present in the crtc_state
as part of null commit.
c) This patch removes any framebuffers attached to a drm_file
in msm_preclose whose refcount is not managed by composer kill
inadvertently and issues null flush to hardware in such cases.
d) This patch handles msm_preclose as part of msm_release
operation since legacy feature is not supported
for msm_driver.
Change-Id: Ib2068d74d4b23b73b7c84544858c9f6bb6adfa67
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
This change reverts commit ae2dceb0b6 ("disp: msm:
sde: remove all preclose logic"). This change also
modifies the force disable plane logic since
__drm_atomic_helper_disable_plane is not exposed to
drivers.
Change-Id: I89e19dead9ade724798952b1934b45b5663e1a42
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
This change enables offline rotator in holi target for
gki defconfig.
Change-Id: Ic128d46fc1cfa98b873c6edb3e1b5e10396b8954
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>
In current implementation, register dump memory is allocated
separately for each range and block. When register dumps are
added to minidump, this will generate around 32 minidump bin files.
Changes are made to allocate all the required register dump memory
once. When register dumps are added to minidump, this will generate
only one minidump file.
Change-Id: I04d4d8db559f21f862f8989d3dfcfa7d9aef6dc5
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
Define 64 bit variables as unsigned long long to ensure
8 bytes in 32 bit builds.
Change-Id: I723ae0c4ba6a0de07c92d14eeef95bde095c8e3d
Signed-off-by: Venkata Prahlad Valluru <vvalluru@codeaurora.org>
use div_u64 instead of /, for 64 bit division.
Change-Id: I791e027beb6817810d63a6a2d0a1a29f88bdb5d5
Signed-off-by: Venkata Prahlad Valluru <vvalluru@codeaurora.org>
Add changes to modify the phys_enc->in_clone_mode variable
post wb_reset_state since this is a shared variable used
during atomic_check and atomic_commit. In current issue case,
wb_atomic_check has set in_clone_mode to true in commit N,
and in commit N-1 CWB is being disabled and re-sets the
in_clone_mode variable to false causing pp_done timeouts in
primary in commit N.
Change-Id: I8159bbdb5622a351d76bdc4dba75d48df20f4365
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
Add changes to avoid primary crtc seamless transition when CWB is
enabled in bootup first commit. This ensures atomic_enable gets called
for primary crtc in splash handoff commit and software states get updated.
Change-Id: I7faab3e4839ab6a69023790ee2874250091f32f0
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
In PM resume with CWB concurrency usecase, crtc pointer in
conn->state is NULL since drm_mode_config_reset operation is
performed on pm_resume. This change relies on conn_mask in
new_crtc_state for primary connector retrieval and also adds
get_num_lm_from_mode callback to DSI for LM count retrieval
from dsi panel topology. Existing get_mode_info api cannot
retrieve the topology info because mode->priv_info is NULL.
This occurs as WB encoder is added in the drm encoder_list
before primary encoder, introduced as part of commit d28ebf05f4
("disp: msm: sde: populate WB display encoder list before dsi").
Change-Id: I55358fd88ab778bd81475cf3628be13335de1cb5
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
Remove feature from dirty list when feature validation fails.
This fixes recovery failure when feature validation fails in
atomic check operation.
Change-Id: I9a884520544c85d0f8ca6a954657f76b37856ad3
Signed-off-by: Anjaneya Prasad Musunuri <aprasad@codeaurora.org>
Following is the sequence during which issue is observed:
1) After suspend, resume commit is with doze suspend mode
(LP2) but kickoff didn't begin.
2) At the same time, runtime pm suspend is triggered which
makes idle request on pm suspend/resume thread.
3) Since the kickoff has not yet started on commit thread,
pending kickoff count is not updated and idle power
collapse sequence is started from pm suspend.
4) As part of idle, irqs are turned off from pm suspend
thread which are turned on commit thread after kickoff
before pp tx irq arrives.
In such cases, during pm suspend, commit thread workqueue
is flushed before encoder idle request to prevent irq's
from getting turned off before the transfer is complete to
avoid inconsistent state.
Change-Id: I417ece0ae7021b0fc5005e262a0d87e43ac729be
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>
Allow input fence status read only when crtc kickoff is in
progress to avoid race between status read and fence destroy.
Change-Id: I3402bfcb38940628f09f645a3cee31f821daeae9
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
Commit caused by dpms on may use extra modeset lock on
connection_mutex before msm_atomic_commit, so to avoid
deadlock, make the modeset lock within msm_atomic_commit
to be used before the waiting for pending_crtcs_event.
Change-Id: Ic43af0f775d87ccc1d145ead9cb2e1b65018c86f
Signed-off-by: Mahadevan <mahap@codeaurora.org>
This change increases the kickoff timeout in doze and
doze suspend usecases. This avoids false timeouts seen
in doze due to rscc static wakeup configured at a different
fps from actual panel TE.
Change-Id: I11c94eb40d4dbbc3d95b8268b007580599ee90fd
Signed-off-by: Jayaprakash Madisetty <jmadiset@codeaurora.org>
Changes are made to add reg log to minidump.
Change-Id: I703075ae22cfa0d987e4bb51ebc28dcdf13baa46
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
Changes are made to add sde and vbif debug bus to minidump.
Change-Id: I8fc615c57e14bf2aa0b814ebda2270cd3124c794
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
Changes are made to add wrapper function to add a minidump
partition. Also, to add evt log to minidump.
Change-Id: I1204a965bab9db72cb3d381a2817dbe8ef723c66
Signed-off-by: Andhavarapu Karthik <kartkart@codeaurora.org>
The usb controller driver does not know if DP is
supported / connected and whether it is operating in
concurrent mode. So, whenever there is a ucsi role switch
call to the usb controller driver, it will reset the usb
phy irrespective of DP connection.
The phy reset while DP driver is still processing cable
connect or disconnect will cause aux timeout or NOC errors.
This change will inform the usb controller driver about the
multi_func mode support to convey how many lanes DP will
be using.
Change-Id: I9e96ed399e879820ddd238cf0fbed7069f1de60d
Signed-off-by: Sankeerth Billakanti <sbillaka@codeaurora.org>
get unifdef explicitly when enabled with argument
Change-Id: I9f12da913c7058279f14ecceedde3bfe64be9086
Signed-off-by: Naseer Ahmed <naseer@codeaurora.org>
Signed-off-by: Abhijith Desai <abdesai@codeaurora.org>
During wait for commit done failure cases in the current
code in video mode and command mode(posted start), global
atomic state for current crtc state will be assigned NULL
during state swap which will lead to crash while using
drm_atomic_crtc_state_for_each_plane API. Also in such
timeout cases, border color staging and kickoff being
done without any vblank wait might lead to inconsistent
state because of configuration overriding from the next
commit. Since the timeout is observed at the end of commit
cycle, only soft reset should be done here and remaining
in the next commit cycle.
Change-Id: I0d42dc27035f4f79394aeec347d797c99ed76e5f
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>
Previous logic expected rsvp_nxt to always be the 2nd rsvp for
a given encoder. This does not work for releasing back-to-back
test-only reservations (with no current rsvp). If new
resources become available between the 2 test-only commits we
may end up reserving more resources than necessary. Change the
logic by adding a pending flag to the rsvp to simplify lookup
of both current and pending/next resource reservations.
Change-Id: Iefa8085f1b4c0cf49bb744dcc2deb7fb92608454
Signed-off-by: Steve Cohen <cohens@codeaurora.org>
In some cases while transitioning between vm, vblank
work might be get executed on event thread after handoff is
completed on commit thread leading to crash. This change
flush the event thread queue during vm pre-release before
lending the io resources to the other vm.
Change-Id: I6a504fc2cec1c4985f7674bbca7fc5869bd8ad07
Signed-off-by: Yashwanth <yvulapu@codeaurora.org>