drivers/staging: Configurable android log buffer sizes

Purpose is reduce the buffer size accordingly and observe savings
in the total kernel static size, which is useful for
memory constrained devices.

Change-Id: I926ab85213c82924ec483327d5aa248372efc604
Signed-off-by: Bhargav Upperla <bhargavuln@codeaurora.org>
[zwliew: Configure for kernel console logcat too]
Signed-off-by: Zhao Wei Liew <zhaoweiliew@gmail.com>

Conflicts:
	drivers/staging/android/logger.c
ASoC:wcd9304:Modified code to acquire codec_resource_lock only once.

POP noise is heard as DAC is enabled during fast insertion/removal of
headset, due to wrong handling of codec_resource_lock. There is no need
to acquire the lock separately for HPHL and HPHR channel, hence modified
such that lock is acquired only once for both HPHL and HPHR PA's.

Change-Id: Ibceced072a9b19f0ecd0b156057973520f241a4f
CRs-Fixed: 580366
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
 ASoC: Fix for incorrect removal detection of headphone

 - Resume of FM playback takes about 5 seconds after end
  of voice call.Since the mic voltage is greater than
  the max headset voltage, a removal interrupt is triggered.
 - Increased the max voltage to fix this issue.

CRs-Fixed: 583301

Change-Id: Ic2381baecf48c9942b6c952bae60dfaa10c03425
Signed-off-by: Shreyas Nagasandra Chandrasekhar <snagas@codeaurora.org>
ASoc: msm: qdsp6v2: Fix for NULL check

- Required check added for NULL pointer

Change-Id: I204dddb37048ba410381e46c0e906d0390951dd9
CRs-fixed: 583939
Signed-off-by: Mohammad Johny Shaik <mjshai@codeaurora.org>
ASoC: msm: Null dereference check added

In asm_read function we should check buffer pointer
before it is dererferenced.

CRs-Fixed: 612682
Change-Id: I1968c038e1d35381bf174000287d542441e41092
Signed-off-by: Anish Kumar <kanish@codeaurora.org>
ASoC: msm: qdsp6v2: check proxy port is open when closing

The current logic opens the afe proxy port only if the
proxy instance virtual port is opened. If only
pcm instance virtual port is opened and a close of the
afe proxy port is attempted, this causes the device to
crash due to a wait event timeout as the driver tries
to close an unopened afe port.
The change ensures that only if both the virtual ports
are opened, which in effect starts the proxy port,
the afe close commands for the proxy port is sent to DSP,
else return immediately.

Change-Id: I9450001c608208f3d8da22b2881a88db1c21d950
Signed-off-by: Aravind Kumar <akumark@codeaurora.org>