summaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorBjorn Andersson <quic_bjorande@quicinc.com>2023-08-11 13:58:36 -0700
committerBjorn Andersson <andersson@kernel.org>2023-08-13 19:26:48 -0700
commit59e09100836fdb618b107c37189d6001b5825872 (patch)
tree02d9baf4c12f95070f4121956d0af6a5470fbfc3 /drivers/net
parentf9eac7e0298ff9df9ae10a579a620d07453845d4 (diff)
downloadlinux-stable-59e09100836fdb618b107c37189d6001b5825872.tar.gz
linux-stable-59e09100836fdb618b107c37189d6001b5825872.tar.bz2
linux-stable-59e09100836fdb618b107c37189d6001b5825872.zip
soc: qcom: aoss: Move length requirements from caller
The existing implementation of qmp_send() requires the caller to provide a buffer which is of word-aligned. The underlying reason for this is that message ram only supports word accesses, but pushing this requirement onto the clients results in the same boiler plate code sprinkled in every call site. By using a temporary buffer in qmp_send() we can hide the underlying hardware limitations from the clients and allow them to pass their NUL-terminates C string directly. Signed-off-by: Bjorn Andersson <quic_bjorande@quicinc.com> Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org> Link: https://lore.kernel.org/r/20230811205839.727373-2-quic_bjorande@quicinc.com Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/ipa/ipa_power.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ipa/ipa_power.c b/drivers/net/ipa/ipa_power.c
index 921eecf3eff6..26181eeed975 100644
--- a/drivers/net/ipa/ipa_power.c
+++ b/drivers/net/ipa/ipa_power.c
@@ -332,7 +332,7 @@ void ipa_power_retention(struct ipa *ipa, bool enable)
(void)snprintf(buf, sizeof(buf), fmt, enable ? '1' : '0');
- ret = qmp_send(power->qmp, buf, sizeof(buf));
+ ret = qmp_send(power->qmp, buf);
if (ret)
dev_err(power->dev, "error %d sending QMP %sable request\n",
ret, enable ? "en" : "dis");