msm: Port 7x27a vreg.c consumers to regulator API

Convert all consumers of vreg.c on 7x27a to use the regulator API.
vreg.c should be considered DEPRECATED on 7x27a.

Signed-off-by: Justin Paupore <jpaupore@codeaurora.org>
Signed-off-by: Pankaj Kumar <pakuma@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
board: msm7x27a: Add machine types for 7625A SURF and FFA

7625A SURF and FFA has some differences like display
resolution (single lane DSI), different tuning parameters
for touchscreen, camera resolution. Some of these
tuning parameters results in lesser PMEM size requirements.

PMEM size allocation is done very early during the linux boot
process and at that time we can't provide a hack to detect
the 7625a using the socinfo, because these are really a
machine differences sometime induced by soc limitation and
new tuning parameters required due to it.

7625AA is also classified under 7625a_surf and 7625a_ffa
macros only.

Signed-off-by: Trilok Soni <tsoni@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: 7x27a support for panel auto detection.

Adding support for LCDC and MIPI panels auto detection
using boot params. If no boot params are given, default
MIPI CMD FWVGA Renesas gets picked up.

Signed-off-by: Ajay Singh Parmar <aparmar@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: Add Chimei MIPI-DSI WXGA panel driver.

Add Chimei MIPI-DSI WXGA (1366x768) panel driver.

Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: add dcs read parser

Parser byte stream responsed back from dcs client base on
the dcs command type.

CRs-fixed: 306936
Change-Id: I0e3776c7ca86f7c4a0f0d090da108599753b9997
Signed-off-by: kuogee hsieh <khsieh@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: Fix dsi read packet size for LiQUID

The toshiba DSI-to-LVDS bridge supports only packet size of 4
for reading its registers.
The DSI host should avoid changing the bridge packet size.

Change-Id: I08a4cb5921c90e9fa07db62e0310fcdb6155f131
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: Fix DSI WSVGA Toshiba panel PLL control settings

Fix DSI WSVGA Toshiba panel PLL control settings to avoid
over-write on reset values from phy table

Change-Id: Ia4b3a4a409a4601a3a2c9132ff66c164f1f8c9fd
Signed-off-by: Ravishangar Kalyanam <rkalya@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: Change the backlight PWM freq to 66 KHZ for LiQUID

Change the backlight PWM to 66 KHZ,
according to the backlight driver HW spec.

Change-Id: I67bc02b7863d7e8721841edfb4cfe3a4414a1bab
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: CSC Matrix update support is added

CSC Matrix update support is added for MDP4 VG pipes
to convert  Ycbcr -> RGB format

CRs-fixed: 313601
Change-Id: Ib6fb8f2eab4b1e871a406a3a2d7274fcfdcdd9d1
Signed-off-by: Nagamalleswararao Ganji <nganji@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: enable hw cursor for dsi video panel

fix hw cursor updates not coming for dsi video panel defining callback
during driver setup.

CRs-Fixed: 309515
Change-Id: I12586e813c19ff4dbe1e3877eaf14b5a396b273a
Signed-off-by: Adrian Salido-Moreno <adrianm@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: Add boot param LCDC/MIPI panel detection support

Add boot param LCDC/MIPI panel detection support for automatically
loading selected panels through fastboot command

Signed-off-by: Ravishangar Kalyanam <rkalya@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: Display: Enable novatek sharp panel for 8960 target.

Add code to provide DSI PHY settings from board file. Remove
chipset dependent changes in panel file. Add fpga register
access support for 8960 chipset to enable 3D barrier

Signed-off-by: Chandan Uddaraju <chandanu@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: Fix compilation error for 7x27a target

Fix compilation error when CONFIG_FB_MSM_MIPI_PANEL_DETECT
is enabled. This is required for auto detections of the
mipi dsi panel.

Signed-off-by: Jeevan Shriram <jshriram@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: Fix display driver init calls for auto-detection

Fix display driver init calls for auto-detection logic to
avoid initialization of panel drivers that are not selected for
loading through fastboot

Signed-off-by: Ravishangar Kalyanam <rkalya@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: add no_max_pkt_size flag

Add no_max_pkt_size flag to allow toshiba dcs to lvds bridege chip
work.

Change-Id: Icaed4bc749dec96f12e3e0e78c098294658a2c46
Signed-off-by: kuogee hsieh <khsieh@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: update busy flag before check blt_addr

dma_busy flag is set to TRUE on every vsycn push and set it
to FALSE at overlay0_done ISR. When blt disable, dma_busy need
to be set to FALSE before return due to blt_addr == NULL at
overlay0_done ISR.

Change-Id: If2622631a7cd03276ae7fbd8326155d0e9c7b66b
Signed-off-by: kuogee hsieh <khsieh@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: add mutex to dsi_on

During resume, backlight dcs commands to client may be issued
before dsi_on completed. Add mutex to dsi_on and check dsi state
to make sure dsi_on is completed before sending backlight command
to panel to avoid conflict on dsi link. Otherwise screen will
stay blank if confliction happened.

Change-Id: Icfba079b228f02aeb89949befb10cca29bf6d744
Signed-off-by: kuogee hsieh <khsieh@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: Use clk_set_rate() to vote on ebi_clk rates

clk_set_rate() and clk_set_min_rate() share a common implementation
for ebi_clk, but the clk_set_min_rate() API will soon be eliminated.
Remove its use in preparation for this.

Change-Id: I5a4a4a2f5e2e0ba4989bc7c1f9423653bec0af0f
Signed-off-by: Matt Wagantall <mattw@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: enable mdp chip select controller

Enable mdp chip select controller so that CS signal is
asserted or de-asserted by MDP according to activities
of memory access on both read and write to save power.

Change-Id: Ic0acc1c8cbe06c5f3cf25627af209abadeb1350c
Signed-off-by: kuogee hsieh <khsieh@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>
msm_fb: display: commit BLT to mdp register during video kickoff

BLT (writeback mode) need to be committed to mdp register
before kickoff. Normally, UI kickoff will follow immediatly
after BLT enabled/disabled. However sometimes video overlay
play happen before UI's pan display after BLT enabled/disabled.
In this case, video kickoff need to commit BLT to mdp register too.

Change-Id: I7b085f516f869009e7fc4b443f7858a61fce5ba3
Signed-off-by: kuogee hsieh <khsieh@codeaurora.org>
Signed-off-by: Ronny Schmatzler <schmatzler@googlemail.com>