hal: Add stubs for new functions on 8960

Change-Id: Iaff2460426937355c62eb3ae7d75b3f5943bb523
Squashed bring up of post processing effects

post_proc: Support effects in DSP for tunnel mode playback

Add interface to support configuring equlaizer, bass boost,
virtualizer and reverb effects in DSP for tunnel mode of
playback.

Change-Id: I9a93ad6136c4de06df5136967908b4e888dae44f

Conflicts:
	Android.mk

hal: Compilation fixes

 * Properly include path to kernel headers for postproc effects
 * Don't try to build SSR or Listen if QC_PROP_ROOT isn't set

Change-Id: I8f2a874bbbec09cea8eae423a82e6cc59d03f422

Conflicts:
	hal/Android.mk

post_proc: Enable effects param in DSP to start effect

-During switch to tunnel playback, offload effects-flags remain
disabled. This stops effects being applied on tunnel playback.
-Send effects enable params to DSP to start effects during switch.

Change-Id: Ibe1e50b41ca25b51537e4a0ad80dbd5184379133
CRs-Fixed: 593509

post_proc: disable adsp reverb when preset is 'None'

Audio HAL set corresponding preset id into adsp, but doesn't disabe
reverb explicitly when 'None' preset is chosen. However, preset=0
means custom preset in adsp, so adsp won't stop reverb processing.

Change-Id: I0c42dd13c09579a6bd3bef2141b857477ec65f2e
CRs-Fixed: 604982

post_proc: send ENABLE_FLAG directly to offload effect driver

Enable flag should be sent directly through offload effect driver to
adsp whenever bundle receives EFFECT_CMD_ENABLE. Otherwise enablement
will only take effect in adsp after subsequent parameters being set, and
that's not expected.

Change-Id: I5a8f936095b5667f0e04b9109b67eaa0faec3a69

post_proc: Enable reverb in DSP to start effect

During switch to tunnel playback, reverb enable command is not sent to
DSP and causes reverb effect not applied continuously.

Send reverb enable params to DSP to start effects during switch.

Change-Id: I6e8bbdf4c1e5933be9a37413a4c4f1b7106fe6ba
CRs-Fixed: 637016

post_proc: reverb preset id is not mapped correctly

Array index is not correct and causes uninitialized value being used
when 'Plate' is chosen. Correct index to retrieve the right preset id.

Change-Id: I2ad058bc7dc5d9b74882da2f5d4c0e3570f9e952
CRs-Fixed: 630429

post_proc: disable Bassboost and Virtualizer for certain devices

WFD, Hdmi and usb audio are not intended to be applied with
SA+ bassboost and virtualizer, so add into invalid device list.

Change-Id: Ifcf9cdffb6657cf82bf903d16d4a3ae8471590f0
CRs-Fixed: 630408

post_proc: disable effect immediately when routed to invalid devices

Offload effect is still perceived when invalid output device is
connected. We should send disable command immediately once phone is
routed to unexpected device and forbid effect enablement during
temporary disabled state.

Change-Id: I26d4ccfd77037a879622b0437ae3916ff0071a69
CRs-Fixed: 630408

postproc: Add exceptions for USB digital out

Change-Id: Idc7f926d31e855ea67dedfb579a9757316e3f526

post_proc: improve logging

Make logs more meaningful and remove
ones not necessary.

Change-Id: I9562cf34a5dee406b1c0347a9004db08de9cd5df

post_proc: disable Bassboost and Virtualizer for USB_ACCESSORY

USB_ACCESSORY is not intended to be applied with SA+ bassboost
and virtualizer, so add into invalid devices list.

CRs-Fixed: 659191
Change-Id: If1f3421f9935ce624dc21895d9244d36d195b2bd

post_proc: fix post and pre process KW issues

KW issue fix includes:
- handle memory allocation failure
- array index boundary check

Change-Id: I083952ba58d348a5b650601a83e6f492b0d686bb

post_proc: Fix improper datatype of EQ preset band level value

unsigned int causes negative band level turn out to be extreme large
value, which results in EQ works abnormally due to unexpected parameter
sent.

Change-Id: I81120c604f4e9f23b25d5a45a7b0294fea63d207
CRs-Fixed: 696825

post_proc: Fix bassboost/virtualizer not disabled on speaker

When output is unintended device, there's no need to query enable_flag
before setting effect to disabled state. There's possiblity that
enable_flag is 0 as initialized value, which hinder effects from being
disabled.

Change-Id: Ib90c0ad0982dc8274129bb1bed7861e11670fbdb