linux: include: add YAMATO format flag

Proper YAMATO support comes from this commit:
27a9eeda9d61f76d38f51f7ad4d8bc38a7f44291, however the msm8660 does not make
use of it, so just add header support for it to match userspace.
Revert "msm_fb: display: fix incorrect MDP formats components unpack pattern"

This reverts commit b04abc58027bace22115f14807c8503fd3bf2649.
msm_fb: display: YUV 444 format support

Signed-off-by: Zhang Chang Ken <kenz@codeaurora.org>
(cherry picked from commit b11c3b46619d3eaee600223859041a51fa0af218)

Change-Id: Ia57a4dd092811f1430367ba7285f15b4e37e6247
Signed-off-by: Shruthi Krishna <skrish@codeaurora.org>
msm_fb: display: fix incorrect MDP formats components unpack pattern

Many of MDP input formats don't have correct unpack pattern, so image
displayed on screen is not in the actual format set.

CRs-fixed: 339114,337040
Signed-off-by: Adrian Salido-Moreno <adrianm@codeaurora.org>
(cherry picked from commit c5638f898324df37e40e402d208b0e97337d536b)

Change-Id: I66a404db039502d0511cd3d7dc34e81c0eca1d61
Signed-off-by: Gopal G Goberu <ggober@codeaurora.org>
Signed-off-by: Adrian Salido-Moreno <adrianm@codeaurora.org>
msm_fb: display: fix underrun seen with big src coordinates

MDP underrun happens if combination of x + w or y + h exceeds 2048.
To handle such use cases add an offset to the source address instead.

Signed-off-by: Adrian Salido-Moreno <adrianm@codeaurora.org>
(cherry picked from commit fa559f6cb6c9a75beb48b594f952ccfe213c4234)

Conflicts:

	drivers/video/msm/mdp4_overlay.c

Change-Id: I41390def2f2d9a647707da86a3aee7362a127f8b
Signed-off-by: Zhoulu Luo <zluo@codeaurora.org>

Conflicts:

	drivers/video/msm/mdp4_overlay.c
mm_video: vidc: SPS PPS enable for IDR and zero stuff bytes

This change includes the driver support for the
latest firmware updates - SPS PPS generation for
every IDR frame encode and MPEG-2 zero stuff
bytes consumption.

Change-Id: I78b63c0b992277e04fea69e33e2cf1180597b0f2
Signed-off-by: Arun Menon <menon@codeaurora.org>
vidc: Memset only for non secure session.

The buffers are memset only if its a non secure
session.

Change-Id: I9b374d4a46ffdd37147e4888fe81c9a7ff7c59aa
Signed-off-by: Deepak Kotur <dkotur@codeaurora.org>
msm: vidc: Remove vcd restriction of duplicate input buffer queue

VCD previously had a limitation of not allowing two consecutive
encode_frame calls with the same buffer. This was primarily due to the
handling of buffer_entry elements in the buffer pool.  This commit
removes this restriction by maintaining an internal buffer_entry element
that VCD keep track of.

Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
(cherry picked from commit 794a9dd1b5c22492ef2ad76e49073c0bc0a2b8f9)

Change-Id: Iadbcae197f4627218440bdf300e43e04e888eaaf
Signed-off-by: Ramakrishna Prasad N <crpn@codeaurora.org>
msm: vidc: Remove memcpy of sequence header

In secure sessions, we aren't allowed write into secure buffers.  In
these cases, do not copy the sequence header from the internal buffer
into the output buffer. The firmware will prepend the sequence header to
the first I-frame in these cases.

Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
(cherry picked from commit e39bcd97987388e7e1877efcc895e21c16f27255)

Change-Id: Iafffd9222ed6f96e87f770a280cd84512cd308ed
Signed-off-by: Ramakrishna Prasad N <crpn@codeaurora.org>
msm: vidc: Handling secure/non-secure concurrency.

Change-Id: Ief0e56615872b109b9d56fc55d2dc28707c90862
Signed-off-by: Vinay Kalia <vkalia@codeaurora.org>

Signed-off-by: Vinay Kalia <vkalia@codeaurora.org>

Conflicts:

	drivers/media/video/msm/wfd/enc-subdev.c
	drivers/media/video/msm/wfd/enc-subdev.h
	drivers/media/video/msm/wfd/wfd-ioctl.c
msm: vidc: Fixes bug in secure enc/dec concurrency

Fixes bug while closing the session when both
secure encoder and secure decoder are running.

Change-Id: I61f72bf13282bed1547fbdad0a3e3aa515e9951c
Signed-off-by: Vinay Kalia <vkalia@codeaurora.org>
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
msm:vidc: update default output buffer requirement

Updated the default output buffer requirement to
match worst case requirements. With this change
reconfig will trigger only if the actual buffer
requirement is less than the estimated requirement.

CRs-fixed: 343812
Signed-off-by: Mohan Kumar Gubbihalli Lachma Naik <mgubbi@codeaurora.org>
(cherry picked from commit 50f02e2345b8a7503c85696b35c2490b3fc53fb0)

Change-Id: I291333003ff441e7734923b188be89a7944c3482
Signed-off-by: Ram Kumar Chakravarthy Chebathini <rcheba@codeaurora.org>
msm: vidc: Fixes a bug in firmware download.

Fixes a bug in firmware download for secure
playback.

Change-Id: Ie93361c508f350363ec01f1c807859b6feec0618
Signed-off-by: Vinay Kalia <vkalia@codeaurora.org>