media: dvb: Fix SDMX process size when crossing limit in TSIF

When playing live from TSIF, TS packet is always 192 bytes long.
The SDMX process limit size was not calculated correctly taking
this case into account.

Change-Id: Id80da8b648cabb222a179c1d49cacdb138f94316
Signed-off-by: Hamad Kadmany <hkadmany@codeaurora.org>
ASoC: msm: Add support to have FM playback through ASM loopback mode

- Add support to provide PP on FM playback.
- Add PCM platform driver which enables ASM loopback mode
Define MultiMedia6 front-end dai

Change-Id: Ibf9d2645e706f9a3027dd356223a2135224a0337
Signed-off-by: Damir Didjusto <damird@codeaurora.org>
ASoC: msm: Add msm-pcm-loopback device

Add msm-pcm-loopback platform device for FM loopback

Change-Id: Ic86f9d92d75bd7c19e3f2d827a4114f6828a7ce8
Signed-off-by: Damir Didjusto <damird@codeaurora.org>
ASoC: msm: Add MultiMedia6 dai link

Add MultiMedia6 dai link for FM loopback.

Change-Id: I08118c9c5add4dba2aaf4af620058dbc9160696d
Signed-off-by: Damir Didjusto <damird@codeaurora.org>
ASoC: msm: flush if prior and current backends rate not matching

It is found that during device switch from one backend
with one sample rate to another backend with another sample rate,
the command to QDSP6 ADM which maps audio stream session to a
particular backend would not get carried out until pending
data of audio stream session from previous backend is either
read out or flushed. This scenario occurs when application
stops providing more buffers to retrieve captured data.
Remedy is to flush upon detection of rate mismatching

Change-Id: I2c01c036d9bb71f938a6795337f08948bd986553
CRs-fixed: 422205
Signed-off-by: Patrick Lai <plai@codeaurora.org>
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
ASoC: msm: Handle data loss at device switch for FM

- When device switch happens there are underflow errors
in LPASS. And there is some break in audio observed for
around 2 sec.
- To handle this, ASM run command needs to be sent again
to DSP at device switch.

Change-Id: I26135ad9267ec5c018708b780b86b7cb4998aa0a
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
board: 8930: Configure LDO L17 as always_on for 8930 SGLTE

LDO L17 is the power source for a set of MSM gpios on
8930 SGLTE. For these GPIOs to be operational L17 should
be turned on by default. Hence, set the always_on,
system_uA and peak_uA properties to the required values.

Change-Id: Id8dc79778091864a61a1c3fb90af328eb26e4d22
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>
hrtimer: Don't reinitialize a cpu_base's lock on CPU_UP

The current code makes the assumption that a cpu_base lock cannot
be held if a CPU is offline, which is tragically wrong.

If a hrtimer is not queued, then it will not be migrated by
migrate_hrtimers() when a CPU is offlined. Therefore, the
hrtimer's cpu_base may still point to a CPU which has
subsequently gone offline if the timer wasn't enqueued at the
time the CPU went down.

Normally this wouldn't be a problem, but a cpu_base's lock is
blindly reinitialized each time a CPU is brought up. If a CPU is
brought online during the period that another thread is
performing a hrtimer operation on a stale hrtimer, then the lock
will be reinitialized under its feet, and a SPIN_BUG() like the
following will be observed:

 [  448.212369] BUG: spinlock already unlocked on CPU#3,
 swapper/3/0
[  448.217368]  lock: 0xc47b1a40, .magic: dead4ead, .owner:
swapper/3/0, .owner_cpu: -1
[  448.217398] [<c0014398>] (unwind_backtrace+0x0/0x120) from
[<c0269ab0>] (do_raw_spin_unlock+0x44/0xdc)
[  448.217419] [<c0269ab0>] (do_raw_spin_unlock+0x44/0xdc) from
[<c071bbb0>] (_raw_spin_unlock_irqrestore+0xc/0x38)
[  448.217438] [<c071bbb0>]
(_raw_spin_unlock_irqrestore+0xc/0x38) from [<c00aa498>]
(hrtimer_try_to_cancel+0xf8/0x10c)
[  448.217455] [<c00aa498>] (hrtimer_try_to_cancel+0xf8/0x10c)
from [<c00aa4bc>] (hrtimer_cancel+0x10/0x20)
[  448.217475] [<c00aa4bc>] (hrtimer_cancel+0x10/0x20) from
[<c00e6934>] (rcu_idle_exit_common+0x5c/0xe0)
[  448.217494] [<c00e6934>] (rcu_idle_exit_common+0x5c/0xe0) from
[<c00e6ae8>] (rcu_idle_exit+0x9c/0xb4)
[  448.217514] [<c00e6ae8>] (rcu_idle_exit+0x9c/0xb4) from
[<c000f2dc>] (cpu_idle+0x98/0xf0)
[  448.217529] [<c000f2dc>] (cpu_idle+0x98/0xf0) from
[<000081ac>] (0x81ac)

CRs-Fixed: 460670
Change-Id: I588f6a864054abe6d4c249aad815c6d2f5a54077
Signed-off-by: Michael Bohan <mbohan@codeaurora.org>
Merge "media: dvb: Fix SDMX process size when crossing limit in TSIF"
msm8930 sglte: Add support for GSBI10 for serial console

This change adds GSBI10 UARTDM device and required resource
(its GPIOs and clocks) with their configurations for 8930
SGLTE EVT1 for serial console functionality.

CRs-Fixed: 459320
Change-Id: I14b9300c1a92cba5c1477aa35be0c83d4b46730f
Signed-off-by: Saket Saurabh <ssaurabh@codeaurora.org>
Signed-off-by: Mayank Rana <mrana@codeaurora.org>
msm8930 sglte: Add support for GSBI11 for serial console

This change adds GSBI11 UARTDM device and required resource
(its GPIOs and clocks) with their configurations for 8930
SGLTE EVT2 for serial console functionality.

CRs-Fixed: 459320
Change-Id: I552da00481feefb9b8c6857799995b5a0caade85
Signed-off-by: Saket Saurabh <ssaurabh@codeaurora.org>
Merge "hrtimer: Don't reinitialize a cpu_base's lock on CPU_UP"
Merge "board: 8930: Configure LDO L17 as always_on for 8930 SGLTE"
Merge "msm8930 sglte: Add support for GSBI10 for serial console"
Merge "msm8930 sglte: Add support for GSBI11 for serial console"
Merge "ASoC: msm: Add support to have FM playback through ASM loopback mode"
Merge "ASoC: msm: flush if prior and current backends rate not matching"
Merge "ASoC: msm: Handle data loss at device switch for FM"
Merge "ASoC: msm: Add msm-pcm-loopback device"
Merge "ASoC: msm: Add MultiMedia6 dai link"