msm: kgsl: Add CP_WAIT_FOR_IDLE packet before updating timestamp

HW workaround to resolve MMU pagefault caused by memory
freeing early before GPU completes it.

This is race condition where timestamp is getting updated
and the event handler runs before the GPU actually got done
with the timestamp, hence freeing the buffer early while GPU
still not completed with it.

Signed-off-by: Anshuman Dani <adani@codeaurora.org>

Conflicts:

	drivers/gpu/msm/adreno_ringbuffer.c
Change-Id: I6d338d7dca680f57f2c39ed5a14381b261bf8bce

Signed-off-by: Vikram Orre <vorre@codeaurora.org>
(cherry picked from commit b72223c1830272e5d9bdcc10975ed8c4d90f9018)

Conflicts:

	drivers/gpu/msm/adreno_ringbuffer.c

Signed-off-by: Satish Kamuju <skamuj@codeaurora.org>
msm: kgsl: Add cache flush for A20x

Adding extra cache flush command to make sure that CP block
gets event from RB all the time to avoid race conditions because of
clock switches. this is to improve stability on 8x25 target.

Signed-off-by: Rajesh Kemisetti <rajeshk@codeaurora.org>

Conflicts:

	drivers/gpu/msm/adreno_ringbuffer.c
Change-Id: Ie411be46fa166864073d35c50085a8f2506d0eb8

Signed-off-by: Vikram Orre <vorre@codeaurora.org>
(cherry picked from commit 4ab5849a194b31b58a397a28cd1a38751a06b360)

Signed-off-by: Satish Kamuju <skamuj@codeaurora.org>
msm: qdsp5v2: Increase buffersize of hostPCM interface.

The default audio sample rate of audioflinger is increased
from 44.1k to 48k.Increase the buffersize to take
advantage of that.

Change-Id: I7ffc6c697cb32b6983c9bb5cc6ea73a7a55b5006
Signed-off-by: Sidipotu Ashok <sashok@codeaurora.org>
video: msm: Call complete_all if vsync times out for LCDC

 * If vsync times out, we need to call complete_all otherwise the wait
   count goes to zero and we are stuck forever.
 * Should hopefully fix the hangs and crashes.

Change-Id: Ia6673b3307251ab3ca1750d65e8c721c5c2dce5f