msm:video: Enable LUT update on DSI command mode panel

CRs-Fixed: 462625

Change-Id: Ieb670abbed0ad06a9c758fb044bf71b6fc2c71b0
Signed-off-by: Ping Li <quicpingli@codeaurora.org>
msm_fb: display: add mutex to video_off

It is possible  that pipe_commit still be issued by
frame work after suspend had been started. Therefore
mutex lock within video_off is necessary to prevent
race condition from happening between these two threads.

Change-Id: I57f51744c1654d6def8664c492035631a5b7081e
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>

Conflicts:
	drivers/video/msm/mdp4_overlay_dsi_cmd.c
msm_fb: display: Wait for DMAE for external interface (DTV)

When calling FBIOPAN_DISPLAY for external, there is no wait
which results in irregular fps when tested with fbtest.
Enable DMAE wait to wait until DMAE is over thereby fixing
irregular fps shown in fbtest results.

Crs-fixed: 438078
Change-Id: Iff528ccc17a1e4078c8825b35d4778a7d9e40e7f
Signed-off-by: Mayank Chopra <makchopra@codeaurora.org>
msm: display: fix iommu page faults for devices with lcdc panel.

Fetch was happening from non-iommu buffer because of wrong mixer
configuration for lcdc panels.

Change-Id: Ie313ce71ff269108271437f758c0dc37884a240c
Signed-off-by: Sangani Suryanarayana Raju <csuryan@codeaurora.org>
msm_fb: display: add wfd clk ctrl in pipe_commit

mdp_clk_ctrl on is not called when commit is from overlay commit path
which can cause mdp hang. mdp_clk_ctrl off should be after mdp
overlay2 is done, so schedule a work in overlay2 done isr.

Change-Id: I94fd08da27cfda114f5cc0056a5103f0a9b772f6
Signed-off-by: Huaibin Yang <huaibiny@codeaurora.org>
msm_fb: display: release mdp clk in mdp4_overlay_writeback_on()

mdp clk is not released in mdp4_overlay_writeback_on()

CRs-fixed: 433986

Change-Id: Ida121e03b0f08ca312c60fb8d945fe2011df853f
Signed-off-by: Mayank Goyal <goyalm@codeaurora.org>
msm_fb: Remove the extra MDP clock enable in writeback_commit

There is an extra MDP clock enable call in writeback commit
which causes the MDP clock to be enabled always once a WFD
session is setup. Remove this additional clock vote to make
sure the clock enable/disable calls are balanced.

Change-Id: I8b101f3eb76fe00ecf6d3967d0bf113146447db3
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
msm_fb: display: add mdp new update method

Enable new mdp update method which requires flush bit
to be set before updating mixer cfg register for both
smart and dump panel

Change-Id: I97b9d221da574a96707748ec83dd1acff6dcb654
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>
msm_fb: display: Do clock control within mdp4_hw_init

Since mdp4_hw_init() access mdp registers, mdp clock control
within mdp4_hw_init() is necessary.

CRs-fixed: 455506
Change-Id: I768f468314fc920029b4c88e49ef6a74f6b74f58
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>
msm_fb: Calibration config API

Add definition for struct to be used in post processing calibration API.
Needed by OEM calibration tool to provide better support of post processing
features.

Change-Id: I40760a85bb58730bfe64469ecf3e2ab3b6e7609e
Signed-off-by: Carl Vanderlip <carlv@codeaurora.org>
(cherry picked from commit e8ed5ec0bd9fd5b298464b7f08b5807afa3291a8)
video: msm: Calibration config implementation

Allow software to selectively read/write MDP color calibration registers.
This is needed to allow calibration tool to individually configure
registers.

Change-Id: I5db2dcbca0b3433c7fedf9033ceff0cf6a5e0e1f
Signed-off-by: Carl Vanderlip <carlv@codeaurora.org>
(cherry picked from commit afc6fbf054d079761d5c2ee85242e56d640ee409)
Signed-off-by: Pravin Tamkhane <pravint@codeaurora.org>

Conflicts:
	drivers/video/msm/mdp4.h
video: msm: Add revision check to calibration API

Add ability to check MDP revision to the calibration config API. Allows
calibration tool to check specific MDP revision for proper tuning.

Change-Id: I926ed21704507cb390c283e5c4383dcf7fbf8030
Signed-off-by: Carl Vanderlip <carlv@codeaurora.org>
msm: display: Proper handling of NULL pointer access for MDDI sysfs node.

All A-family chips which don't include MDDI interface module
observe NULL pointer access error while trying to access MDDI
debugfs nodes. This change fixes the issue with proper handling
of NULL pointer access.

Change-Id: Ie5be96bb2b9c28b256ab3999079c2c7cd9bc54a8
Signed-off-by: Sangani Suryanarayana Raju <csuryan@codeaurora.org>
msm_fb: display: add early_off during panel off

Some panels need to send display_off command before
dsi controller turned off. This patch add early_off
feature for this purpose.

Change-Id: Id377120e9d6972c5f773760369ec056be37e93ff
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>
msm_fb: display: Avoid dsi clock warnings during boot

Correctly set up the dsi_clk_rate in
cont_splash_clk_ctrl before enabling them.

Crs-fixed: 389531
Change-Id: Iee13e6d871ca1fdb7f3f45a5e3b36784145abd86
Signed-off-by: Mayank Goyal <goyalm@codeaurora.org>