vidc: 1080p: Override profile to ASP for XVid/Divx456

Always set profile to ASP for XVid/Divx456 apart from
MPEG-4. Core will ignore the profile information from
the sequence header and continue to decode with profile
set by driver.

CRs-fixed: 319168
Signed-off-by: Rajeshwar Kurapaty <rkurapat@codeaurora.org>
(cherry picked from commit b7523cde9399347fa357f0a5d43ccdfeaa30a04a)

Change-Id: I3672f172460ec56afc4d22c435af59612b6669bc
Signed-off-by: Swetha Basineni <sbasin@codeaurora.org>
msm: vidc: Fix handling EOS with bitstream error.

If the EOS frame has codec config flag set and decoder
return status is bitstream error, then driver was
handling EOS done before the core returned with EOS done.

Fixed by adding a check in the driver to not handle EOS done
until the core returns with EOS done.

CRs-Fixed: 320107

Signed-off-by: Deepika Pepakayala <deepikap@codeaurora.org>
(cherry picked from commit a86367e34880ba37cabc0a6041300c0e3ae2424b)

Change-Id: I67d891d38cf746245fb26600b15d05f38c679b02
Signed-off-by: Swetha Basineni <sbasin@codeaurora.org>
msm_fb: display: prefill two writeback frames for lcdc.

Pre-fill two writeback frames before enable writeback mode
to avoid flickering for lcdc.

CRs-fixed: 325327
Signed-off-by: Mayank Chopra <makchopra@codeaurora.org>
(cherry picked from commit 3a895fd04105cb1a1db3ae51d051ea6b6d9ef980)

Conflicts:

	drivers/video/msm/mdp4_overlay_lcdc.c

Change-Id: Ic8a2d59163c807c24ffa54a5b72d5bdd70712301
Signed-off-by: Swetha Basineni <sbasin@codeaurora.org>
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.

Signed-off-by: kuogee hsieh <khsieh@codeaurora.org>
(cherry picked from commit 81be67988ef149f601064a9e8e5d91705e636ff5)

Change-Id: Ia0552b3b645389efeaf2b8d3986f5ba10c4d9142
Signed-off-by: Sunil Joseph <sunilj@codeaurora.org>
vidc: 1080p: Increase context memory size of the H.264 encoder.

Increasing the context memory size of H264 encoder
to 20KB as it is a requirement from 11302011 firmware.

CRs-Fixed: 317041
Signed-off-by: Rajeshwar Kurapaty <rkurapat@codeaurora.org>
(cherry picked from commit 6fb6e94208d7eacebf159127b558515ac77ea164)

Change-Id: I1ac38b430261bae5fe13a94523457568e9b8d1d9
Signed-off-by: Swetha Basineni <sbasin@codeaurora.org>
msm: camera: Free buffers from frame queue at open

Free all pending frames in frame queue before cam_frame
thread opens frame device to avoid duplication of buffer
free

CRs-Fixed: 318202
Change-Id: I25d1718a37a94fa83563c4b6e99a1b7560917a7f
Signed-off-by: Suresh Vankadara <svankada@codeaurora.org>
(cherry picked from commit 5dcbcb9f04a94aa6740718a1b6d39ce4548d869c)
msm_fb: HDMI-CEC: Line latch patch

The CEC hardware latches upon reading a corrupt bit
in bit 7 of any bytes due various timing issues. If
the driver detects this latch up then we call CEC reset
to release the lacthed up line.

CRs-Fixed: 329507
Signed-off-by: Manoj Rao <manojraj@codeaurora.org>
(cherry picked from commit 1573599adbb42c606d8b91854c76461b3f212c3e)

Change-Id: I60a2fb051add9973d98c177b58c33445260cb359
Signed-off-by: Swetha Basineni <sbasin@codeaurora.org>
msm_fb: display: clean dsi fifo during dsi_off

During suspend, wait until dsi controller's fifo is
cleaned before disabling dsi controller. This will
prevent pixels that were left over in the fifo from
being displayed during next resume.

CRs-fixed: 336049
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>
(cherry picked from commit 9d76704c8dac8f9e0794834cc4d62c17fd9cdf63)

Conflicts:

	drivers/video/msm/mipi_dsi.c

Change-Id: If7adff01a7fd50177761f015227986a3f93d1e49
Signed-off-by: Swetha Basineni <sbasin@codeaurora.org>
arm: mm: Exclude additional mem_map entries from free

A previous patch addressed the issue of move_freepages_block()
trampling on erronously freed mem_map entries for the bank end
pfn. We also need to restrict the start pfn in a
complementary manner.

Also make macro usage consistent by adopting the use of
round_down and round_up.

Signed-off-by: Michael Bohan <mbohan@codeaurora.org>
(cherry picked from commit 3a99a03af19781dcf1074e70461505e2d773bba1)

Change-Id: Iae5ef3c745d46fcc92766f05ce2c1ca7e27abe7c
Signed-off-by: Swetha Basineni <sbasin@codeaurora.org>
msm_fb: hdmi: 3D configurations in HDMI

3D configurations using Generic0 packets need to be done
after enabling HDMI Control to take these configurations
into effect.

CRs-fixed: 349578
Signed-off-by: Ajay Singh Parmar <aparmar@codeaurora.org>
(cherry picked from commit 514b1c651a33b7b73fb6f654d04355eac5ecb146)

Change-Id: I15ae4a26a1d1f964b41bb6174e5ea31bc4da8a59
Signed-off-by: Swetha Basineni <sbasin@codeaurora.org>
msm_fb: display: Use spinlock instead of mutex in vsync timer handler

Use spinlock instead of mutex in vsync timer handler to avoid sleeping
from timer context through mutex locks

Change-Id: I302e2d966c9167c5fc1b0c7586b8047e8cb700cb
Signed-off-by: Ravishangar Kalyanam <rkalya@codeaurora.org>
video: msm: Block histogram requests with powered down panel

This causes MSMFB_HISTOGRAM ioctls to return an error when they are called
after the panel has entered a powered down state.

CRs-Fixed: 310429
Change-Id: I39c768c62a37ca83df2db2309230971cb6492bab
Signed-off-by: Carl Vanderlip <carlv@codeaurora.org>