Lothar Waßmann [Tue, 7 Mar 2017 14:09:26 +0000 (15:09 +0100)]
power: reset: set arm_pm_restart hook in msm-poweroff driver
For some yet unknown reason the system fails to restart via the PSCI
subsystem. Setup the arm_pm_restart hook to restart the system via
do_msm_restart().
This may not be the ultimately correct solution, but it at least makes
the system rebootable.
Lothar Waßmann [Thu, 5 Jan 2017 13:57:39 +0000 (14:57 +0100)]
arm64: dts: add support for Ka-Ro electronics TXSD-410E module
The TXSD-410E is a SoM largely compatible to a Qualcomm APQ8016-SBC
board in a different form factor.
It features an LVDS output instead of HDMI and has no onboard USB hub.
commit 691849c2ffa1 ("Move to new qcom_smem_get() api") left over a
check of a now uninitialized variable.
Remove the variable and do the check in the hopefully intended
manner.
Lothar Waßmann [Thu, 5 Jan 2017 09:31:15 +0000 (10:31 +0100)]
drm: msm: dsi: keep a reference on msm_host->device_node until driver removal
Since the device_node pointer is stored for later usage, its refcount
must not be decreased to prevent deletion of the object while it may
still be referenced.
msm8916-wcd codec is found in Qualcomm msm8916 and apq8016 processors.
This codec IP is split in to two parts(Digital & Analog), Analog part
is integrated in to PMIC PM8916 and the digital part is integrated into
Application processor. Register access to the analog part is done via
SPMI interface to PMIC, and registers on the Application processor are
memory mapped. Data transfer between Analog and Digital Die is done via
a internal bus called PDM.
This codec support includes:
- 3 Microphones: Primary Mic(Handset mic), Headset Mic and Secondary Mic.
- 2 Digital Microphones.
- 2 Mic Bias Circuits.
- Earpiece
- Headset
- Loud Speaker.
This patch introduces SOC_SINGLE_S8_TLV() macro for volume control
on chips which supports both negative and positive gains with sign
bit on a 8 bit register, Gain ranges from -128 to +127 with a
predefined step size.
Currently we only have support to DOUBLE_S8_TLV() which does not fit
for cases where we just have separate gain control register for each
channel.
One of the Qualcomm SOC msm8916 has such gain control register whose gain
range is from -38.4dB to +38.4dB with step size of 0.3dB.
This patch adds DT bindings required for msm8916 codec which is
integrated in msm8916 and apq8016 SOCs.
Codec IP is divided into two parts, first analog which is integrated
in pmic pm8916 and secondly digital part which is integrated into
application processor. Codec register controls are also split across
pmic an lpass. Analog part is controlled via spmi bus to pmic, registers
on the Application processor are memory mapped.
Georgi Djakov [Thu, 14 Apr 2016 14:34:49 +0000 (17:34 +0300)]
arm64: dts: qcom: msm8916: Use fixed factor xo clock
The rpmcc driver is providing the XO clock, which is the parent of almost
all clocks. But during boot, this driver may probe later and leave most of
the clocks without parent. The common clock framework currently reports
invalid rate for orphan clocks and this may confuse drivers.
To resolve this, use fixed clocks registration until we have some support
to deal with the this issue. Removing the generic rpmcc compatible is
enough to switch back to fixed factor XO clock.
Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
Georgi Djakov [Thu, 14 Apr 2016 14:34:48 +0000 (17:34 +0300)]
clk: qcom: Add support for RPM Clocks
This adds initial support for clocks controlled by the Resource
Power Manager (RPM) processor on some Qualcomm SoCs, which use
the qcom_rpm driver to communicate with RPM.
Such platforms are apq8064 and msm8960.
Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
Georgi Djakov [Thu, 14 Apr 2016 14:34:47 +0000 (17:34 +0300)]
clk: qcom: Add support for SMD-RPM Clocks
This adds initial support for clocks controlled by the Resource
Power Manager (RPM) processor on some Qualcomm SoCs, which use
the qcom_smd_rpm driver to communicate with RPM.
Such platforms are msm8916, apq8084 and msm8974.
The RPM is a dedicated hardware engine for managing the shared
SoC resources in order to keep the lowest power profile. It
communicates with other hardware subsystems via shared memory
and accepts clock requests, aggregates the requests and turns
the clocks on/off or scales them on demand.
This driver is based on the codeaurora.org driver:
https://www.codeaurora.org/cgit/quic/la/kernel/msm-3.10/tree/drivers/clk/qcom/clock-rpm.c
Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
Bjorn Andersson [Fri, 17 Jun 2016 04:08:17 +0000 (21:08 -0700)]
remoteproc: qcom: Merge cleanup and fixup from the future
This incorporates cleanups done in preparation for mainline submission;
halt regs comes from the tcsr syscon, the mdt loader uses
rproc_da_to_va() to simplify the api, supplies are handled, requesting
stop is implemented and a few minor cleanups of the DT binding.
Also included is a fix for an issue triggered by the latest DB410c
firmware, where using the mpss_region for verification of the mdt header
results in a timeout on verifying the rest of the modem firmware.
Bjorn Andersson [Mon, 11 Jan 2016 18:33:27 +0000 (10:33 -0800)]
wcn36xx: Disable power save
Enabling power save results in extremely long ping times and stalling
transfers. So disable it for not until we can figure out how to work
around this.
Bjorn Andersson [Thu, 25 Feb 2016 16:09:15 +0000 (08:09 -0800)]
soc: qcom: wcnss_ctrl: Make wcnss_ctrl parent the other components
We need the signal from wcnss_ctrl indicating that the firmware is up
and running before we can communicate with the other components of the
chip. So make these other components children of the wcnss_ctrl device,
so they can be probed in order.
The process seems to take between 1/2-5 seconds, so this is done in a
worker, instead of holding up the probe.
Bluetooth: Introduce Qualcomm WCNSS SMD based HCI driver
The Qualcomm WCNSS chip provides two SMD channels to the BT core; one
for command and one for event packets. This driver exposes the two
channels as a hci device.
With the introduction of the upstream wcnss remoteproc driver we do iris
xo calibration before we boot the wcnss - as it should have been done
from the beginning.
This patch cleans out the iris xo calibration code and simplifies the
platform integration implementation.
soc: qcom: wcnss_ctrl: Expose the cbc status to others
The prima driver needs a way to wait for the wcnss firmware to become
available, it does this by repeatedly querying the wcnss control driver
if we've reached cbc (cold boot completed).
qcom-scm: Align PAS api with "upstream" implementation
This aligns the PAS implementation with the patches heading upstream,
in particular tying the dma allocation in pas_init_image to the scm
platform_device rather then the caller.
Bjorn Andersson [Thu, 25 Feb 2016 16:09:15 +0000 (08:09 -0800)]
soc: qcom: wcnss_ctrl: Make wcnss_ctrl parent the other components
This is a hacked up version of the patch sent to LKML, as I don't want
to change the smd API in the release branch.
We need the signal from wcnss_ctrl indicating that the firmware is up
and running before we can communicate with the other components of the
chip. So make these other components children of the wcnss_ctrl device,
so they can be probed in order.
The process seems to take between 1/2-5 seconds, so this is done in a
worker, instead of holding up the probe.
This introduces the peripheral image loader, for loading WCNSS firmware
and boot the core on e.g. MSM8974. The firmware is verified and booted
with the help of the Peripheral Authentication System (PAS) in
TrustZone.
Lee Jones [Tue, 12 Jan 2016 12:46:17 +0000 (12:46 +0000)]
remoteproc: debugfs: Add ability to boot remote processor using debugfs
This functionality is especially useful during the testing phase. When
used in conjunction with Mailbox's Test Framework we can trivially conduct
end-to-end testing i.e. boot co-processor, send and receive messages to
the co-processor, then shut it down again (repeat as required).
Signed-off-by: Ludovic Barre <ludovic.barre@st.com> Signed-off-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Bjorn Andersson [Thu, 16 Jun 2016 18:24:35 +0000 (11:24 -0700)]
tty: serial: msm: Don't reconfigure same baud rate
msm_set_termios() is called whenever the tty is opened. Setting the baud
rate requires a full reset of the msm serial block, even when the rate
is unchanged. In the case when the same uart is used as console this
reset will discard any console output data still being clocked out of
the TX fifo.
By skipping the rate-change in the case where the baud rate is unchanged
since last request we can avoid the reset and the discarding of the
data.
regulator: qcom_smd: add regulator ops for pm8941 lnldo
After "regulator: qcom_smd: add list_voltage callback" patch adding
pm8941 lnldo regulators would bug on list_voltages as it is a fixed
regulator without any linear range.
This patch fixes that issue by adding dedicated ops for pm8941 lnldo
without list_voltages callback.
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org>
Georgi Djakov [Fri, 10 Jun 2016 12:00:50 +0000 (15:00 +0300)]
mmc: sdhci-msm: Add support for UHS cards
Enabling support for ultra high speed mode cards requires some
voltage switching and interaction with the PMIC via a special
power IRQ. Add support for this.
Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
Jisheng Zhang [Tue, 16 Feb 2016 13:08:22 +0000 (21:08 +0800)]
mmc: sdhci-msm: use sdhci_pltfm_init for private allocation
Commit 0e748234293f ("mmc: sdhci: Add size for caller in init+register")
allows users of sdhci_pltfm to allocate private space in calls to
sdhci_pltfm_init+sdhci_pltfm_register. This patch migrates sdhci-msm
to this allocation.
Jisheng Zhang [Tue, 16 Feb 2016 13:08:21 +0000 (21:08 +0800)]
mmc: sdhci-msm: factorise sdhci_msm_pdata outisde of sdhci_msm_host
There's no need to allocate one sdhci_msm_pdata for each sdhci_msm_host.
This patch removes the sdhci_msm_pdata member from sdhci_msm_host and
uses one static global sdhci_msm_pdata for all sdhci msm hosts. It also
marks sdhci_msm_ops as const.
Parth Pancholi [Fri, 10 Jun 2016 18:19:55 +0000 (19:19 +0100)]
ARM: dts: sd_600eval: Fix eMMC lockup issue
This board locks up if we stress test the eMMC, as the regulator s4 is
unable to supply enough current for all the peripherials attached to it.
As this supply is wired up to most of the peripherials including DDR,
it resulted in such lockup.
This patch fixes this issue by setting s4 regulator correctly with
Auto power mode.