[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230731231014.GI1428172@hu-bjorande-lv.qualcomm.com>
Date: Mon, 31 Jul 2023 16:10:14 -0700
From: Bjorn Andersson <quic_bjorande@...cinc.com>
To: Chris Lew <quic_clew@...cinc.com>
CC: Bjorn Andersson <andersson@...nel.org>,
Konrad Dybcio <konrad.dybcio@...aro.org>,
Alex Elder <elder@...nel.org>,
"David S. Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>,
Mathieu Poirier <mathieu.poirier@...aro.org>,
<netdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
<linux-arm-msm@...r.kernel.org>, <linux-remoteproc@...r.kernel.org>
Subject: Re: [PATCH 1/4] soc: qcom: aoss: Move length requirements from caller
On Mon, Jul 31, 2023 at 02:29:44PM -0700, Chris Lew wrote:
>
>
> On 7/30/2023 9:10 PM, Bjorn Andersson wrote:
> > diff --git a/drivers/soc/qcom/qcom_aoss.c b/drivers/soc/qcom/qcom_aoss.c
> > /* The message RAM only implements 32-bit accesses */
> > __iowrite32_copy(qmp->msgram + qmp->offset + sizeof(u32),
> > - data, len / sizeof(u32));
> > - writel(len, qmp->msgram + qmp->offset);
> > + buf, sizeof(buf) / sizeof(u32));
> > + writel(sizeof(buf), qmp->msgram + qmp->offset);
>
> Looks like we are telling the firmware the packet size will always be
> QMP_MSG_LEN?
>
> This should be ok but might be a problem when debugging. The AOSS firmware
> only logs size of the message instead of the full string because of memory
> constraints.
>
Until now ipa_power_retention() has been passing 36 here, everyone else
64, so it is ok.
> We would normally match the firmware and host logs based on size, but won't
> be able to differentiate this way with a fixed size.
I don't mind us changing it to ALIGN(len, 4), but as that would change
the current behavior I'd like to do so in a subsequent patch.
Speaking of behavior, is 64 the max message size? We inherited the 64
from the initial downstream implementation, but qmp->size is quite a bit
bigger.
Regards,
Bjorn
Powered by blists - more mailing lists