msm: bam_dmux: Reverts commit causing crash after data enable

Data call is not working and device is crashed when data is enabled.
sps_device_reset() call is failed when calling from disconnect_to_bam().
suspecting accessing to regiter when clocks are off.

Reverting all below commits to unblock and fix the actual issue.

Revert "msm: bam_dmux: Fix race condition during SSR"

This reverts commit e7c0d6229dda3a4949478356b4dd51d872b295ab.

Revert "msm: bam_dmux: add loopback support"

This reverts commit 89c96baacf357a9a9e419c0f0dbc4550d2b96d8f.

Revert "msm: bam_dmux: tune downlink polling parameters"

This reverts commit 308c38653b2677e9a6f0cc98084691d7774a70ca.

Revert "msm: bam_dmux: add downlink processing state logging"

This reverts commit 7c1856091b020ee4c2523cefc1ecd472dfc054fe.

Revert "msm: bam_dmux: prevent duplicate subsystem restart"

This reverts commit 7614a7fd15d8c3c8a5f73b3946c7f55422387450.

Revert "msm: bam_dmux: Update UL wakeup timeout to two seconds"

This reverts commit 1f31739b09b2a1546797e7b0d2409eb53a3305c0.

Revert "msm: bam_dmux: delay shutdown until DL polling is complete"

This reverts commit 096f7d336f88c814a3decfaf286632c1e3dad0fb.

Revert "msm: bam_dmux: increase shutdown logging granularity"

This reverts commit f7ae7a6010230835e609c67ad35a304415c617bd.

Revert "msm: bam_dmux: reduce notify_all() logging"

This reverts commit ac8152a4753fc5d01a1cb4ce90272b85f174887e.

Revert "msm: bam_dmux: correct sps_transfer_one() flag usage"

This reverts commit c85df96a0224fd1f891d6b00c949b882d8231879.

Revert "msm: bam_dmux: Use IPC Logging for string formatting"

This reverts commit f800bbaf86b6a2a8f9ab02ccd4089494fd000646.

Revert "msm: bam_dmux: wait for DL thread to shutdown in case of SSR"

This reverts commit 199294b2164e62a40dcf6853ede77215d619be31.

Revert "msm: bam_dmux: reset bam hardware when A2 goes into pc"

This reverts commit a82a95c209207c4f7721971785863e90603b93f2.

Change-Id: Idc66812ff48413794bc70920318ca535e62eeba8
Signed-off-by: Arun Kumar Neelakantam <aneela@codeaurora.org>
arm: if there's no handler we need to restore sigmask, syscall or no syscall

CRs-fixed: 592079
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Git-commit: 7dfae72027cd8345247e675a3b27439df95fe06e
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-stable.git
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
arm: new way of handling ERESTART_RESTARTBLOCK

new "syscall start" flag; handled in syscall_trace() by switching
syscall number to that of syscall_restart(2).  Restarts of that
kind (ERESTART_RESTARTBLOCK) are handled by setting that bit;
syscall number is not modified until the actual call.

CRs-fixed: 592079
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Git-commit: 6b5c8045ecc7e726cdaa2a9d9c8e5008050e1252
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-stable.git
Signed-off-by: Joonwoo Park <joonwoop@codeaurora.org>
Revert "Execute shader on wakeup from power collapse"

This reverts commit 28eabf6987637c6c438c461aa31ce25e0f7edcc5.

Conflicts:

	drivers/gpu/msm/adreno.c
	drivers/gpu/msm/adreno.h
	drivers/gpu/msm/adreno_a3xx.c
	drivers/gpu/msm/adreno_ringbuffer.c

Change-Id: I0a979f33d9030546d1e72b63cff88d269f63a4c7
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
msm: vidc: enable pic_order_cnt_type for H264 encoding

-current implementation will result in poc_type as 0 in SPS
params (even though the poc increment value is 2 in the
encoded stream).
-So changes done to return poc_type as 2 in SPS params

Change-Id: I5a22af422b0e1591a69a0b5b868342667ee60bbf
Signed-off-by: srikarri <sridur@codeaurora.org>
driver core: fix possible missing of device probe

Inside bus_add_driver(), one device might be added(device_add()) into
the bus or probed which is triggered by deferred probe
just after completing of driver_attach() and before
'klist_add_tail(&priv->knode_bus, &bus->p->klist_drivers)',
so the device won't be probed by this driver.

This patch moves the below line

	'klist_add_tail(&priv->knode_bus, &bus->p->klist_drivers)'

before driver_attach() inside bus_add_driver() to fix the
problem.

CRs-Fixed: 588802
Change-Id: I9250b399d57a89870d1df220b97fdca275e2e1a9
Signed-off-by: Ming Lei <ming.lei@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Git-commit: 190888ac01d059e38ffe77a2291d44cafa9016fb
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Signed-off-by: Sagar Dharia <sdharia@codeaurora.org>
Signed-off-by: Swetha Chikkaboraiah <schikk@codeaurora.org>
mach-msm:bus_config:fix possible missing error check

There is a possibility of msm_bus_board_get_iid returning the error.
ERROR check is required before proceeding with the msm_bus_get_fabric_device

CRs-Fixed: 588802
Change-Id: I1353ed1b2505b117b61b72600e74b5d68d0bc508
Signed-off-by: Swetha Chikkaboraiah <schikk@codeaurora.org>
wcnss: Add new device interface for user control messages

wcnss userspace service will use this new control interface to configure
certain parameters required by wcnss driver. This interface is required
to configure the serial number (for MAC address auto-generation),
calibrated data availability etc. These parameters were earlier written
thru module parameters from wcnss service, however that required the
wcnss userspace daemon to have the root permission.

Change-Id: I92cc7f2c63eae08b7a467b834116883027361299
CRs-Fixed: 590457
Signed-off-by: Sameer Thalappil <sameert@codeaurora.org>
diag: Reduce error message frequency

Some diag error messages are printed with high frequency. This
cause flooding of kernel logs. Rate limiting these messages will
help reading kernel logs.

Change-Id: I477ff2394116603a27d65948a60d3460c32572d1
CRs-fixed: 594186
Signed-off-by: Katish Paran <kparan@codeaurora.org>
Rotator getting stuck leading to fence timeout

Even though cancel_delayed_work should cancel the worker thread
in some race condition it can fail and get scheduled.
To avoid this situation use cancel_delayed_work_sync.
Also rotator_lock mutex need not be unlocked while waiting for isr
as isr does not aquire this mutex for doing its operations.
It is after this unlock of mutex sometimes in race condition rotator
clock is getting disabled via the msm_rotator_rot_clk_work_f

Change-Id: I574aec489fe51ec0e5f7c215c9aba9bb0ec66ffa
Signed-off-by: Justin Philip <jphili@codeaurora.org>
cpufreq: Optimize cpufreq_frequency_table_verify()

cpufreq_frequency_table_verify() is rewritten here to make it more logical
and efficient.
 - merge multiple lines for variable declarations together.
 - quit early if any frequency between min/max is found.
 - don't call cpufreq_verify_within_limits() in case any valid freq is
   found as it is of no use.
 - rename the count variable as found and change its type to boolean.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
deadline: Allow 0ms deadline latency, increase the read speed

Change a timer compare from after to after-equals, thus allowing
0 timeout and making deadline schedule FIFO.

Signed-off-by: xiaobing tu <xiaobing.tu@intel.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>
msm_kcal_ctrl: initial code for generic MSM LCD temperature calibrations

this should be compatible with all MDP devices from Qualcomm

Signed-off-by: Paul Reioux <reioux@gmail.com>

Conflicts:
	arch/arm/mach-msm/Makefile
MSM KCAL: add sRGB LUT for better color space profiling

Signed-off-by: Paul Reioux <reioux@gmail.com>
MSM KCAL: add lut edit capability

Signed-off-by: Paul Reioux <reioux@gmail.com>
MSM KCAL: add checksum and data integrity checks

Signed-off-by: Paul Reioux <reioux@gmail.com>
MSM KCAL: add reset lut capability

Signed-off-by: Paul Reioux <reioux@gmail.com>
msm_kcal: add late resume drivers to autoload the lut

Signed-off-by: Paul Reioux <reioux@gmail.com>
msm_kcal: delay late resume to be last to resume

Signed-off-by: Paul Reioux <reioux@gmail.com>
mach-msm: remove LG files