Revert "iopoll: Use ktime_get() instead of jiffies for timeout calculations"

This reverts commit 65ca3ec3b780c4815a666ce315b07dc8d086befd.
rtc: Bring to sane state

* CAF sync up for rtc breaks alarm suspend in some
  cases. Revert the suspects.

Revert "rtc: alarm: set power_on_alarm again when calling alarm_resume"

This reverts commit 017c15cb86628289156e6467ac53f07abe6ee696.

Revert "kernel: alarm: Do not call rtc_alarm_irq_enable in IRQ Disabled cont

This reverts commit 1ea6420fb4fcf68ce14048e134b807e3b184390c.

Revert "rtc: qpnp-rtc: Sets RTC time correctly"

This reverts commit 785b6907b7daf8af0bf052f801a0c1fd8eff24f0.

Revert "kernel: alarm: setup the RTC immediately for poweroff alarm"

This reverts commit 1d87e24760fac9b26a19c17bbf2ead2de30db61b.

Revert "rtc: alarm: Proper handling of spinlock"

This reverts commit 1ab10087383ea0ceec2176cd6262779caac1db5d.

Revert "rtc: alarm: update power_on alarm setting logic"

This reverts commit dd61a38271cf7542ac20d93efcceaa84bd0952e1.

Revert "rtc: qpnp-rtc: Set alarm control register properly"

This reverts commit fc6162126e8fe829e6aaf61368bdc6ba3b4cb6ab.

Revert "rtc:alarm: remove alarm_shutdown hook in alarm driver"

This reverts commit 0481b367b05ed02059cb9b1e6a21e6d9c60039d2.

Revert "alarm : Fix the race conditions in alarm-dev.c"

This reverts commit 5d95d04712be53aa669336724ad628c1d9089185.

Revert "qpnp-rtc: clear alarm register when rtc irq is disabled"

This reverts commit c736fbd94a3cfaa927f545dfcafde370d3d79dd0.

Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
netfilter: IDLETIMER: fix invalid deference of timer

"timer" was checked for null, but used later without being re-checked.

Reported-by: dan.carpenter@oracle.com
Signed-off-by: JP Abgrall <jpa@google.com>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
ASoC: msm: Add async ops for codec TX path

 * Improves low-latency capture performance

Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
ASoC: msm: qdsp6v2: add check for NULL dereference

The asm loopback driver during close does not check
for NULL before closing the playback and capture
instances.

The change ensures only the valid playback/capture
instances are closed.

Signed-off-by: Aravind Kumar <akumark@codeaurora.org>
Signed-off-by: Pradosh Das <c_prados@qti.qualcomm.com>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
SoC: msm: Add Buffer overflow check

The overflow check is required to ensure that user space data
in kernel may not go beyond buffer boundary.

Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
Signed-off-by: Mohammad Johny Shaik <mjshai@codeaurora.org>
Signed-off-by: Pavan Chikkala <pavanc@codeaurora.org>
Signed-off-by: Divya Narayanan Poojary <dnaray@codeaurora.org>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
slim_ngd: Use DSP before-shutdown notification for DSP SSR

QMI_SERVER_EXIT notification comes too late (after the DSP has
shutdown). This can result in unclocked access by BAM if there was
in-flight transaction. Use BEFORE_SHUTDOWN notification of SSR
framework instead to make sure in-flight transaction is finished
before DSP turns off its resources.

Signed-off-by: Sagar Dharia <sdharia@codeaurora.org>
Signed-off-by: Dilip Kota <c_dkota@codeaurora.org>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
slim_ngd: Ensure device state consistency with runtime-pm during SSR

During ADSP SSR, client's thread calling runtime-pm resume will
fail since ADSP is unreachable. Make sure such power-up/resume attempt
is blocked until ADSP comes up by using mutex during device-state
transition.

Signed-off-by: Sagar Dharia <sdharia@codeaurora.org>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
hammerhead: fast_charge: Simplify to single control

* Two separate controls are confusing for users.
* Simplify so that 1 control "fast_charge_level" can
  handle disabling fast charge as well as setting
  custom value.

Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>