msm: audio: qdsp6v2: Update ACDB driver to use ION

Update the ACDB driver to use ION instead of PMEM
driver to allocate memory.

Change-Id: I8934ccf9c75db5921f51aac2f518c342948678cc
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
msm: audio: qdsp6v2: Replace PMEM with ION in Audio Decoder drivers

ION is replacement for PMEM which is less complex with better
reference counting. Hence ION which is a superset of PMEM is
used to allocate memory in the audio decoder drivers.

Change-Id: I0c9458b902bad169d6fcc36dfc66d538c00a6e22
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
msm: audio: qdsp6v2: Replace PMEM with ION in LPA driver

ION is replacement for PMEM which is less complex with better
reference counting. Hence ION which is a superset of PMEM is
used to allocate memory in LPA driver

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

Change-Id: I32fc2db0be0c1768ffc1b009203f739e720a7473
Signed-off-by: Srivalli Oguri <oguri@codeaurora.org>
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
msm: Asoc: audio: Migrate to ION from pmem, dma alloc

-Voice driver and RT proxy driver are using Pmem and
DMA alloc. Migrate them to use ION memory to save memory
and avoid stability issues.

CRs-Fixed: 369303
Change-Id: If58b69b9f8b7b03661a36451c1a5c27885fbf976
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
ASoc-msm: Modify ASM drivers to invoke ION APIs

Create ION client and allocate buffers based on
the client handle and free the buffers when no
more needed.

CRs-fixed: 349170
Signed-off-by: Swaminathan Sathappan <Swami@codeaurora.org>
(cherry picked from commit bdc5508dbc5e9bd624eb34e5e254b510baf4294f)

Change-Id: I7c748946e98567995f10f7aea0bc6e0b0454a802
Signed-off-by: Srivalli Oguri <oguri@codeaurora.org>
Signed-off-by: Vidyakumar Athota <vathota@codeaurora.org>
msm: board 8960 and 8064: Increase ion heap size for audio.

After migration from pmem to ion, we need to
reduce EBI1 memory for audio usecase and make a
corresponding increase the ION heap size.

Change-Id: I98ba83cff86760be078ef1d8a7e7a03b9e71db8d
Signed-off-by: Jay Wang <jaywang@codeaurora.org>
d2: Reserve memory for ION audio

Change-Id: I2a7203c94d2966a947009f46c72f22dc66aa26bf
bam_dmux: Add d2usc workaround for modem crash.

Effectively reverts "msm: bam_dmux: Add locking around platform device
calls" (3688ab952920247bc79a1dd89293bd6449fb1127) for d2usc only, as this
commit is responsible for its modem crash and boot loop.

TODO: Determine exactly why this commit is related to the modem crash, and
why other d2 devices are unaffected.

Change-Id: Iafb7092f448f31c0b5a08c20d9d1921f356014a1
msm_fb: display: remove dmae wait in spinlock

This is a merge error that caused the crash when hdmi cable is
plugged. mdp4_dtv_wait4dmae is not included in spinlock in mainline
patch.

Change-Id: I3e95d281f19aef423bbc42f7e628ea94335a0843
Signed-off-by: Huaibin Yang <huaibiny@codeaurora.org>
msm_fb: display: add mutex on overlay_play to fix iommu page fault

An iommu page fault may heppen When a pipe_commit is executed
in between of frame dropped and pipe_queue during overlay play.
An mutex is necessary to mutual exclusive between pipe_commit
and overlay_play.

Change-Id: I736e821c6c648a6ebd435303a1906a40e9b75791
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>
msm_fb: display: add wait for overlay0 done

Dcs command mode BLT involves both overlay0 done interrupt
and dmap done interrupt. A transaction is start at kickoff and
end with done interrupt.  At some cornor cases both overlay0 and
dmap transaction need to be completed before kickoff new transaction.

Change-Id: I5a3cc6e8255acf2c61fc627d35f990182d226f63
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>
(cherry picked from commit 521230e19ad81077bf0ad51ee2989e058e129837)
Linux 3.0.42
lib: genalloc: Change chunk allocation to vmalloc

Change the chunk allocation from kmalloc to vmalloc for
allocations greater than a page. This allows large
chunks to be allocated from physically non-contiguous
memory and increases the chance of the allocation
succeeding.

CRs-fixed: 387655
Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
(cherry picked from commit 0614b96dc8e4c8a0dd0db41aec5a79daa3bdf091)

Conflicts:

	lib/genalloc.c

Change-Id: Ic0dedbad9d277d0842591b1f075ce3b80c8c05de
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
Revert "cpufreq: ondemand: Add boost interface"

Switching to the CodeAurora version.

This reverts commit 981815e70915fc31f713c69d06aeedc2787ac80b.
cpufreq: Add a boostpulse interface to ondemand

For applications that require a one-shot increase in frequency,
the boostpulse interface would help to scale to max for the time
specified in boostime. This helps applications that currently
increases scaling_min_freq and resets later after a fixed duration.
Instead of changing scaling_min_freq applications can directly write
to boostpulse and governer resets during regular timer after the time
expires.

Change-Id: Ie5f490ff06b41364aa76dd468573433495da28a4
Signed-off-by: Narayanan Gopalakrishnan <nargop@codeaurora.org>
cpufreq: notify avg load for short sampling_rate

If the sampling rate is less than 50ms reporting
the actual load may lead to poor decision making
at user space. So, for sampling rates less than 50ms
report the average of load across two samples.

Change-Id: I0d1cf00801732bee8e4380158d7e892758226594
Signed-off-by: Narayanan Gopalakrishnan <nargop@codeaurora.org>
cpufreq: boost the sampling rate on touch event

For better Ux responsiveness ondemand sampling rate
needs to be 20ms. But, a 20ms sampling rate increases power
consumption. So, boost the sampling rate to 20ms on every
touch event for 2.5 ms and later reset to default rate.
Also, change sampling down factor proportional to the
sampling rate.

Change-Id: I111b1cf3b8ed133347149afc34d329d0384ecfcb
Signed-off-by: Narayanan Gopalakrishnan <nargop@codeaurora.org>
Revert "msm: pm-8x60: Check for SPM status in msm_pm_verify_cpu_pc"

This reverts commit 535c6d19e4f1b7ad1d3de6df999bc9bb1eb1ebe5.
Revert "msm: pm-8x60: Don't restore ACPU frequency for hotplug cases."

This reverts commit 215a1770a40880dbca186ea5c94c41e275034ac7.
Merge "Linux 3.0.42" into jellybean