public inbox for linux-wireless@vger.kernel.org
 help / color / mirror / Atom feed
From: Marc Gonzalez <mgonzalez@freebox.fr>
To: Conor Dooley <conor@kernel.org>
Cc: Kalle Valo <kvalo@kernel.org>,
	Jeff Johnson <quic_jjohnson@quicinc.com>,
	ath10k <ath10k@lists.infradead.org>,
	wireless <linux-wireless@vger.kernel.org>,
	DT <devicetree@vger.kernel.org>, Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Pierre-Hugues Husson <phhusson@freebox.fr>,
	Jami Kettunen <jamipkettunen@gmail.com>,
	Jeffrey Hugo <quic_jhugo@quicinc.com>,
	Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Subject: Re: [PATCH 1/2] dt-bindings: net: wireless: ath10k: add qcom,no-msa-ready-indicator prop
Date: Tue, 5 Mar 2024 14:41:08 +0100	[thread overview]
Message-ID: <4df78b7e-92dc-45e4-9d5f-9ec8793c4fd3@freebox.fr> (raw)
In-Reply-To: <20240304-component-animator-e2ee0ab7574a@spud>

On 04/03/2024 20:34, Conor Dooley wrote:

> On Mon, Mar 04, 2024 at 05:21:37PM +0100, Marc Gonzalez wrote:
>
>> On 29/02/2024 19:40, Conor Dooley wrote:
>>
>>> On Wed, Feb 28, 2024 at 06:37:08PM +0200, Kalle Valo wrote:
>>>
>>>> Marc Gonzalez wrote:
>>>>
>>>>> As mentioned in my other reply, there are several msm8998-based
>>>>> devices affected by this issue. Is it not appropriate to consider
>>>>> a kernel-based work-around?
>>>>
>>>> Sorry, not following you here. But I'll try to answer anyway:
>>>>
>>>> I have understood that Device Tree is supposed to describe hardware, not
>>>> software. This is why having this property in DT does not look right
>>>> place for this. For example, if the ath10k firmware is fixed then DT
>>>> would have to be changed even though nothing changed in hardware. But of
>>>> course DT maintainers have the final say.
>>>
>>> I dunno, if the firmware affects the functionality of the hardware in a
>>> way that cannot be detected from the operating system at runtime how
>>> else is it supposed to deal with that?
>>> The devicetree is supposed to describe hardware, yes, but at a certain
>>> point the line between firmware and hardware is invisible :)
>>> Not describing software is mostly about not using it to determine
>>> software policy in the operating system.
>>
>> Recording here what was discussed a few days ago on IRC:
>>
>> If all msm8998 boards are affected, then it /might/ make sense
>> to work around the issue for ALL msm8998 boards:
>>
>> diff --git a/drivers/net/wireless/ath/ath10k/qmi.c b/drivers/net/wireless/ath/ath10k/qmi.c
>> index 0776e79b25f3a..9da06da518fb6 100644
>> --- a/drivers/net/wireless/ath/ath10k/qmi.c
>> +++ b/drivers/net/wireless/ath/ath10k/qmi.c
>> @@ -1076,6 +1076,9 @@ int ath10k_qmi_init(struct ath10k *ar, u32 msa_size)
>>  	qmi->ar = ar;
>>  	ar_snoc->qmi = qmi;
>>  
>> +	if (of_device_is_compatible(of_root, "qcom,msm8998")
>> +		qmi->no_point_in_waiting_for_msa_ready_indicator = true;
>> +
>>  	if (of_property_read_bool(dev->of_node, "qcom,msa-fixed-perm"))
>>  		qmi->msa_fixed_perm = true;
>>  
>>
>> Thus, anyone porting an msm8998 board to mainline would automatically
>> get the work-around, without having to hunt down the feature bit,
>> and tweak the FW files.
> 
> How come the root node comes into this, don't you have a soc-specific
> compatible for the integration on this SoC?
> (I am assuming that this is not the SDIO variant, given then it'd not be
> fixed to this particular implementation)

I see only
"qcom,ipq4019-wifi"
"qcom,wcn3990-wifi"
"qcom,wcn6750-wifi"

arch/arm64/boot/dts/qcom/msm8998.dtsi uses "qcom,wcn3990-wifi"
(which is also used for 9 other SoCs).

IIUC, you're saying there probably should have been a generic
compatible AND a board-specific compatible, like for ufshc:

$ git grep qcom,ufshc arch/arm64/boot/dts/qcom
arch/arm64/boot/dts/qcom/msm8996.dtsi:                  compatible = "qcom,msm8996-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/msm8998.dtsi:                  compatible = "qcom,msm8998-ufshc", "qcom,ufshc", "jedec,ufs-2.0";
arch/arm64/boot/dts/qcom/sa8775p.dtsi:                  compatible = "qcom,sa8775p-ufshc", "qcom,ufshc", "jedec,ufs-2.0";
arch/arm64/boot/dts/qcom/sc7280.dtsi:                   compatible = "qcom,sc7280-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sc8180x.dtsi:                  compatible = "qcom,sc8180x-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sc8280xp.dtsi:                 compatible = "qcom,sc8280xp-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sc8280xp.dtsi:                 compatible = "qcom,sc8280xp-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sdm845.dtsi:                   compatible = "qcom,sdm845-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sm6115.dtsi:                   compatible = "qcom,sm6115-ufshc", "qcom,ufshc", "jedec,ufs-2.0";
arch/arm64/boot/dts/qcom/sm6125.dtsi:                   compatible = "qcom,sm6125-ufshc", "qcom,ufshc", "jedec,ufs-2.0";
arch/arm64/boot/dts/qcom/sm6350.dtsi:                   compatible = "qcom,sm6350-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sm8150.dtsi:                   compatible = "qcom,sm8150-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sm8250.dtsi:                   compatible = "qcom,sm8250-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sm8350.dtsi:                   compatible = "qcom,sm8350-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sm8450.dtsi:                   compatible = "qcom,sm8450-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sm8550.dtsi:                   compatible = "qcom,sm8550-ufshc", "qcom,ufshc",
arch/arm64/boot/dts/qcom/sm8650.dtsi:                   compatible = "qcom,sm8650-ufshc", "qcom,ufshc", "jedec,ufs-2.0";


If all msm8998-based device trees had (for example)
a qcom,msm8998-wcn3990-wifi compatible, we could have
matched that to apply a quirk to all msm8998 boards.

Did I understand correctly?

(In the toy code I provided, I matched the of_root because
there is no SoC-specific compatible for the device itself.)

-- 
Regards



  parent reply	other threads:[~2024-03-05 13:41 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-28 13:22 [PATCH 0/2] Work around missing MSA_READY indicator from ath10k FW Marc Gonzalez
2024-02-28 13:24 ` [PATCH 1/2] dt-bindings: net: wireless: ath10k: add qcom,no-msa-ready-indicator prop Marc Gonzalez
2024-02-28 14:03   ` Kalle Valo
2024-02-28 16:12     ` Marc Gonzalez
2024-02-28 16:37       ` Kalle Valo
2024-02-28 17:19         ` Marc Gonzalez
2024-03-01  8:10           ` Kalle Valo
2024-03-04 15:51             ` Marc Gonzalez
2024-03-05 14:31               ` Kalle Valo
2024-03-05 17:32                 ` Marc Gonzalez
2024-03-05 19:20                   ` Kalle Valo
2024-03-13 15:09                     ` Marc Gonzalez
2024-03-13 15:48                       ` Konrad Dybcio
2024-03-13 15:53                       ` Dmitry Baryshkov
2024-03-14 12:31                         ` Marc Gonzalez
2024-03-14 12:52                           ` Dmitry Baryshkov
2024-03-18 16:56                         ` Marc Gonzalez
2024-03-19 13:47                           ` Marc Gonzalez
2024-03-19 14:39                             ` Marc Gonzalez
2024-03-19 17:05                               ` Marc Gonzalez
2024-03-26 15:04                       ` Marc Gonzalez
2024-03-26 17:45                         ` Marc Gonzalez
2024-03-26 17:51                           ` Dmitry Baryshkov
2024-03-26 20:21                             ` Jeff Johnson
2024-03-28 17:09                               ` Marc Gonzalez
2024-02-29 18:40         ` Conor Dooley
2024-02-29 19:46           ` Jeff Johnson
2024-03-07 15:29             ` Marc Gonzalez
2024-03-07 16:46               ` Jeff Johnson
2024-03-14 14:33                 ` Jeff Johnson
2024-03-14 17:52                   ` Marc Gonzalez
2024-03-14 19:28                     ` Jeff Johnson
2024-03-04 16:21           ` Marc Gonzalez
2024-03-04 19:34             ` Conor Dooley
2024-03-04 19:37               ` Dmitry Baryshkov
2024-03-04 19:45                 ` Conor Dooley
2024-03-04 19:59                   ` Dmitry Baryshkov
2024-03-04 20:17                     ` Conor Dooley
2024-03-04 20:21                       ` Dmitry Baryshkov
2024-03-05  8:04                         ` Krzysztof Kozlowski
2024-03-05 13:41               ` Marc Gonzalez [this message]
2024-03-05 15:02             ` Kalle Valo
2024-03-05 14:45           ` Kalle Valo
2024-02-28 14:59   ` Jeff Johnson
2024-02-28 16:00     ` Marc Gonzalez
2024-02-29 15:49     ` Marc Gonzalez
2024-02-28 13:25 ` [PATCH 2/2] wifi: ath10k: work around missing MSA_READY indicator Marc Gonzalez

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4df78b7e-92dc-45e4-9d5f-9ec8793c4fd3@freebox.fr \
    --to=mgonzalez@freebox.fr \
    --cc=ath10k@lists.infradead.org \
    --cc=conor+dt@kernel.org \
    --cc=conor@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dmitry.baryshkov@linaro.org \
    --cc=jamipkettunen@gmail.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=kvalo@kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=phhusson@freebox.fr \
    --cc=quic_jhugo@quicinc.com \
    --cc=quic_jjohnson@quicinc.com \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox