Revert "ion: ion mini upgrade"

This reverts commit 88891d02458d6fa2dce999494e21cac20fef9681.
Revert "ion: ion mini upgrade"

This reverts commit 611aa2966d9ee9d3354a6c1fdc32650264f40bc5.
Revert "msm: kgsl: Hold the pm_qos vote at all times when
 ACTIVE"

This reverts commit 66ad4c0ed14ecbe0fbbd24b5bdcd5ca984ea7386.

Change-Id: I1c70a8d5a76544abe89484576917f2dd8142342a
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: Gopal Goberu <ggober@codeaurora.org>
(cherry picked from commit f4537cf8dd50a78d78ab1664d623c9b6ecf3f240)

Conflicts:

	drivers/gpu/msm/adreno_ringbuffer.c

Change-Id: Ie08148847d33cd3e526e9bf23bf357a55b048e1b
Signed-off-by: Srivalli Oguri <oguri@codeaurora.org>
msm: kgsl: Reduce the number of RBBM register reads.

Check if WPTR and RPTR are equal before checking the
RBBM register status. This will decrease the excessive
register reads.

Change-Id: I108764138315670a83a1ab423ff29310c98f5a81
Signed-off-by: Vikram Orre <vorre@codeaurora.org>
msm: kgsl: Log retired timestamps on device wake

Knowing the retired timestamp on wake-up is useful to debug hangs that
are caused due to clock instability. When we request for clock ON, the
clock may/may-not be turned ON, but we go ahead assuming it is ON. This
can be caught by printing the timestamp on wake. The timestamp we print,
can be compared against the timestamp in postmortem dump (assuming a
hang happens).

If there is a difference, we can say that GPU has run for sometime after
wake. So, we needn't suspect clocks.

If there is no difference, we can say that GPU has hung immediately after
wake. So, we can positively suspect the clocks.

Change-Id: Iedf49977adbb0e61a9b71bbe23acc81f2a75162d
Signed-off-by: Ranjhith Kalisamy <ranjhith@codeaurora.org>
msm: kgsl: Restore the value of RB_BC_CONTROL on context
 switch

On 8x25Q, when GPU footswitch is turned off during TCXO shutdown, the
RB_BC_CONTROL register value is lost which causes GPU hang after coming
out of TCXO shutdown. Now the value of RB_BC_CONTROL is preserved properly
during context save and restore.

Change-Id: I20fe3cb2565e306a589765460339990ec149fd01
CRs-fixed: 441134
Signed-off-by: Vinay Roy <vroy@codeaurora.org>

Conflicts:
	drivers/gpu/msm/a2xx_reg.h
msm: kgsl: Calculate busy interval considering GPU freq as float

GPU freq could be non-integral value and treating it as an integer
to calculate GPU busy insterval leads to higher busy interval
and more often we see negative idle stats. This change caculates
busy interval by treating gpu freq to the correct precision.

Change-Id: Ic54130803d7a0436b4ba31b09915eb7165d16590
CRs-fixed: 454972
Signed-off-by: Vinay Roy <vroy@codeaurora.org>
Revert "msm: kgsl: Update pagetable on context destruction
 for A20x"

This reverts commit f0d1c9b79e05972816b92bd43b29e98f764826ea.

Reverting this change since it corrupts Bin Base Offset between
two draws of a Binning pass, resulting in GPU hang.

Change-Id: I4a3fdc9d3180b96ba617753855c7d789f2c0f5e3
Signed-off-by: Rajesh Kemisetti <rajeshk@codeaurora.org>
msm: kgsl: Don't hold process list global mutex in process private create

Don't hold process list global mutex for long. Instead make
use of process specific spin_lock() to serialize access
to process private structure while creating it. Holding
process list global mutex could lead to deadlocks as other
functions depend on it.

Change-Id: I4f60737393efa2001597f0222aa6fe19fb6a07c5
Signed-off-by: Harsh Vardhan Dwivedi <hdwivedi@codeaurora.org>
Signed-off-by: Ananta Kishore K <akollipa@codeaurora.org>
msm: msm_fb: remove mmio access through mmap

Disable access to mm io and add
appropriate range checks to ensure valid accesses
through framebuffer mmap. This prevents illegal
access into memory.

CRs-Fixed: 474706
Change-Id: If25166f2732433ef967e99c716440030b567aae9
Signed-off-by: Manoj Rao <manojraj@codeaurora.org>
qdsp5: audio: Add support for adsp dump mechanism

Whenever timeout happens at apps while waiting for response
from ADSP services, dsp or audmgr apps initiates command to
collect cache coherent dumps to modem ADSP services to collect
dump. This will help in debugging the timeout issue.

Signed-off-by: Chaithanya Krishna Bacharaju <chaithan@codeaurora.org>
(cherry picked from commit b5c4e9843eeb08bf4f234877778863dca05ca887)

Change-Id: Iabb4a5117bc5f9ec6e5bf689dd4732168dcfcc14
Signed-off-by: Gopal Goberu <ggober@codeaurora.org>
msm: audio: qdsp5: Add support for MIDI method

Currenly CAD driver only supports VOICE method when setting volume.
For applying dynamic PMIC gain MIDI method is used. Changes are made
to support MIDI method also.

Change-Id: I6fc66f5683e81266f234b3bfb49b5d3d8167acaa
Signed-off-by: Chaithanya Krishna Bacharaju <chaithan@codeaurora.org>