msm: mdss: hdmi: clean up cn/itc bit set/unset

Properly set/unset the ITC/CN bits by using proper mutex,
error checks and other cleanup things.

Change-Id: I2730689dc70df1bce65bb1699938ce7793937688
Signed-off-by: Ajay Singh Parmar <aparmar@codeaurora.org>
msm: kgsl: Program clock control registers for A4XX

Progran the clock control registers for A4XX that control
internal clock gating of the GPU core. This programming
is more efficient for saving power since certain clocks internal
to the GPU will be turned off when not in use.

Change-Id: If44a3ee22c31a5e6bb1e65fafcdb58b1de4e0a33
Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
msm: socinfo: Add hardware platform id for SBC

The default CDT value for the Single Board Computer
reveals a platform with ID of 24. Add this value to the hw
platform list so that hw_platform sysfs node reports the
correct platform name.

Change-Id: I5b29835880872cb1c08688461a90a509655da573
Signed-off-by: Eugene Yasman <eyasman@codeaurora.org>
msm: gpiomux: remove conflict between nfc and camera on Hisense

NFC and camera use pin8 on different hardware.
This change enables conditional configuration of pin 8.

Change-Id: I0cb9e1fbc9de40fdac728cb66d9a0bc422c98e22
Signed-off-by: Houston Hoffman <hhoffman@codeaurora.org>
msm: clock-8x10: Update lookup table for NFC clocks for PVT

Configure I2C clock and GP clock for QCA199x NFCC on PVT
devices.

Change-Id: Ie9bee72e0b62255e3d2610c60f5f69fcdf69bfdc
Signed-off-by: Houston Hoffman <hhoffman@codeaurora.org>
msm: mdss: fix the non-continuous splash screen use case

In the non-continuous splash screen use case, we need to
stop the display.  The display clocks are on before we
stop the display.

Change-Id: If8f76d4776fb64f4deb89e5b78c52ab54a56f02a
Signed-off-by: Xiaoming Zhou <zhoux@codeaurora.org>
msm: mdss: Fix error cases in AD config

The BL linearity LUT was not being copied correctly. This change allows
AD config to exit with errors correctly if the BL linearity LUT is not
passed correctly.

Change-Id: I491a7cc4b168b7691c65cbc2d2963f8a7a3f804d
Signed-off-by: Benet Clark <benetc@codeaurora.org>
msm: cpr-regulator: add pvs voltage uplift workaround

There are some parts which require higher than expected voltage. Add a
workaround to check the condition in fuse and uplift the voltage and
quotient accordingly.

Change-Id: I59f821320e5e97fc2334ae7617a0045edb5cc970
Signed-off-by: Wu Fenglin <fenglinw@codeaurora.org>
ARM: dts: msm: enable pvs voltage uplift workaround for msm8226

Some 8x26 parts have lower pvs voltage than expected. Enable uplift
workaround of 50 mV on those parts under the specified conditions.

Change-Id: I3d8689ca0c5d576b1dd9057e36f67ea3622b80a1
Signed-off-by: Wu Fenglin <fenglinw@codeaurora.org>
msm: kgsl: Make sure the bus is on to consider power enabled

In theory only reg reads/writes should be using this check, and
they don't need the bus.  But just in case, make sure it is on
before allowing any activity.

Change-Id: I660fb947ad16e2872cfb95a9d99200a197b37f31
Signed-off-by: Lucille Sylvester <lsylvest@codeaurora.org>
cpufreq: interactive: sync freq feature for interactive governor

1) Add load info to cpufreq_interactive_cpuinfo
2) If load on any other online cpu exceeds sync_freq_load_threshold,
   do not allow the frequency to drop below sync_freq

Change-Id: I3617e10f87b85178914a18bcf04ac2a31a4f1ec1
Signed-off-by: Rohit Gupta <rohgup@codeaurora.org>
msm: ADSPRPC: Add mappings to IOMMU for remote heap

The remote heap buffers need to be mapped and unmapped in
the IOMMU when SMMU is present on the remote processor.

Change-Id: I9d78e1098a4163109dbde4c23681be4cfb8a353a
Acked-by: Sathish Ambley <sambley@qti.qualcomm.com>
Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
msm: ADSPRPC: Save and restore contexts when interrupted

While a RPC session is in progress, wait could get interrupted
as a result of device entering power collase and the system call
retried once the device leaves power collapse. This requires that
the RPC session context is saved and restored across these
interrupts to avoid duplicate invocations being sent across to
the remote processor.

Change-Id: I71141c13da7be3d33e13305e0744148921123160
Acked-by: Sathish Ambley <sambley@qti.qualcomm.com>
Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
msm: ipc_logging: Support multiplatform

Upstream prefers existing drivers be converted to support multiplatform
kernels.  This requires drivers to be located in generic functionality
directories instead of specific mach directories.

Move the ipc_logging driver to the kernel/trace location to support
multiplatform.

Change-Id: I8b217f2c13254814e9dfa95f46308150f1fc2a1b
Signed-off-by: Jeffrey Hugo <jhugo@codeaurora.org>
scsi: ufs: dump device descriptor info via debugfs

This change adds a debugfs capability to dump Device Descriptor
information, parsed and detailed. It helps developer to get
important information about the UFS device it handles.

Change-Id: Ia149e4c82e33755b235eb6afe52541c8b23a0708
Signed-off-by: Yaniv Gardi <ygardi@codeaurora.org>
msm: mdss: Block postprocessing updates during DTM

When calibration tool requests the fb driver to enter in
Display Tuning Mode (DTM), PostProcessing blocks should
not update the HSIC, Memory color, Six Zone colors, etc.
Updating them during DTM conflicts the update from
calibration tool.

Change-Id: I11fcac57a651581d85e771911f83b2fdd9c3c681
Signed-off-by: Dhaval Patel <pdhaval@codeaurora.org>
msm: mdss: Verify histogram size before sending to user

Add check to DSPP histograms to verify that the number of pixels collected
is the same as the resolution of the region being processed.

Change-Id: I21acd1b4a25d06391c853e7495ca3fb3bb0ffef4
Signed-off-by: Carl Vanderlip <carlv@codeaurora.org>
msm: rpm-regulator-smd: limit current to RPM defined maximum

Modify the rpm_vreg_get_optimum_mode() function so that it
restricts the maximum current that can be sent for the 'ma' KVP
to the limit defined by the RPM.

Change-Id: I744e656c75a5e78a81df9c283a8f14a977c4c6ee
Signed-off-by: David Collins <collinsd@codeaurora.org>
msm: rpm-regulator-smd: remove incorrect rpm_regulator_get() unlock calls

The rpm_regulator_get() function calls rpm_vreg_unlock() in
failure paths after two kzalloc() calls.  However, there is no
corresponding rpm_vreg_lock() call before these calls.  Also, the
code being executed does not require mutual exclusion.  Thus,
remove the rpm_vreg_unlock() calls in order to avoid possible
locking problems if kzalloc() fails.

Change-Id: I0a0f2ffde5a6c54600a823e3ed12c3c47c3bac6a
Signed-off-by: David Collins <collinsd@codeaurora.org>
qup_i2c: Correct free memory call

Correct freeing of memory, which is allocated using
the devm prefixed API, to free it using devm_kfree rather
then kfree.

CRs-Fixed: 582597
Change-Id: If1aa9bcd86bb3a7d35adc5630ff19ad08bbdf762
Signed-off-by: Gilad Avidov <gavidov@codeaurora.org>