ATH11K Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzk@kernel.org>
To: Jeff Johnson <quic_jjohnson@quicinc.com>,
	Bartosz Golaszewski <brgl@bgdev.pl>,
	Kalle Valo <kvalo@kernel.org>
Cc: "David S . Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Jeff Johnson <jjohnson@kernel.org>,
	linux-wireless@vger.kernel.org, netdev@vger.kernel.org,
	devicetree@vger.kernel.org, ath11k@lists.infradead.org,
	linux-kernel@vger.kernel.org,
	Bartosz Golaszewski <bartosz.golaszewski@linaro.org>,
	Arnd Bergmann <arnd@arndb.de>
Subject: Re: [PATCH net-next v2] dt-bindings: net: ath11k: document the inputs of the ath11k on WCN6855
Date: Tue, 24 Sep 2024 10:06:59 +0200	[thread overview]
Message-ID: <1e79d94e-2f83-4762-b126-ed865142f1ed@kernel.org> (raw)
In-Reply-To: <b7fdafd6-5029-4b80-b264-11943740b354@quicinc.com>

On 20/09/2024 23:02, Jeff Johnson wrote:
> On 9/20/2024 1:22 AM, Bartosz Golaszewski wrote:
>> On Fri, 20 Sep 2024 08:45:56 +0200, Kalle Valo <kvalo@kernel.org> said:
>>> Krzysztof Kozlowski <krzk@kernel.org> writes:
>>>
>>>> On 19/09/2024 09:48, Kalle Valo wrote:
>>>>> Krzysztof Kozlowski <krzk@kernel.org> writes:
>>>>>
>>>>>> On 14/08/2024 10:23, Bartosz Golaszewski wrote:
>>>>>>> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>>>>>>>
>>>>>>> Describe the inputs from the PMU of the ath11k module on WCN6855.
>>>>>>>
>>>>>>> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>>>>>>> ---
>>>>>>> v1 -> v2:
>>>>>>> - update the example
>>>>>>
>>>>>> I don't understand why this patch is no being picked up. The code
>>>>>> correct represents the piece of hardware. The supplies should be
>>>>>> required, because this one particular device - the one described in this
>>>>>> binding - cannot work without them.
>>>>>
>>>>> I have already explained the situation. With supplies changed to
>>>>> optional I'm happy take the patch.
>>>>
>>>> You did not provide any relevant argument to this case. Your concerns
>>>> described quite different case and are no applicable to DT based platforms.
>>>
>>> Ok, I'll try to explain my concerns one more time. I'll try to be
>>> thorough so will be a longer mail.
>>>
>>> In ath11k we have board files, it's basically board/product specific
>>> calibration data which is combined with the calibration data from chip's
>>> OTP. Choosing the correct board file is essential as otherwise the
>>> performance can be bad or the device doesn't work at all.
>>>
>>> The board files are stored in board-2.bin file in /lib/firmware. ath11k
>>> chooses the correct board file based on the information provided by the
>>> ath11k firmware and then transfers the board file to firmware. From
>>> board-2.bin the correct board file is search based on strings like this:
>>>
>>> bus=pci,vendor=17cb,device=1103,subsystem-vendor=105b,subsystem-device=e0ca,qmi-chip-id=2,qmi-board-id=255
>>> bus=pci,vendor=17cb,device=1103,subsystem-vendor=105b,subsystem-device=e0ca,qmi-chip-id=2,qmi-board-id=255,variant=HO_BNM
>>>
>>> But the firmware does not always provide unique enough information for
>>> choosing the correct board file and that's why we added the variant
>>> property (the second example above). This variant property gives us the
>>> means to name the board files uniquely and not have any conflicts. In
>>> x86 systems we retrieve it from SMBIOS and in DT systems using
>>> qcom,ath11k-calibration-variant property.
>>>
>>
>> No issues here.
>>
>>> If WCN6855 supplies are marked as required, it means that we cannot use
>>> qcom,ath11k-calibration-variant DT property anymore with WCN6855 M.2
>>> boards. So if we have devices which don't provide unique information
>>> then for those devices it's impossible to automatically to choose the
>>> correct board file.
>>>
>>
>> What you're really trying to say is: we cannot use the following snippet of
>> DTS anymore:
>>
>> 	&pcie4_port0 {
>> 		wifi@0 {
>> 			compatible = "pci17cb,1103";
>> 			reg = <0x10000 0x0 0x0 0x0 0x0>;
>>
>> 			qcom,ath11k-calibration-variant = "LE_X13S";
>> 		};
>> 	};
>>
>> First: it's not true. We are not allowed to break existing device-tree sources
>> and a change to the schema has no power to do so anyway. You will however no
>> longer be able to upstream just this as it will not pass make dtbs_check
>> anymore.
>>
>> Second: this bit is incomplete even if the WCN6855 package is on a detachable
>> M.2 card. When a DT property is defined as optional in schema, it doesn't
>> mean: "the driver will work fine without it". It means: "the *hardware* does
>> not actually need it to function". That's a huge difference. DTS is not a
>> configuration file for your convenience.
>>
>>> So based on this, to me the correct solution here is to make the
>>> supplies optional so that qcom,ath11k-calibration-variant DT property
>>> can continue to be used with WCN6855 M.2 boards.
>>>
>>
>> No, this is the convenient solution. The *correct* solution is to say how the
>> ath11k inside the WCN6855 package is really supplied. The dt-bindings should
>> define the correct representation, not the convenient one.
>>
>> Let me give you an analogy: we don't really need to have always-on, fixed
>> regulators in DTS. The drivers don't really need them. We do it for
>> completeness of the HW description.
> 
> Again, since I'm a DT n00b:
> Just to make sure I understand, you are saying that with this change any
> existing .dts/.dtb files will still work with an updated driver, so the new
> properties are not required to be populated on existing devices.

Did you folks rejected patches acked by DT maintainers on basis of not
understanding DT at all?

> 
> However a new driver with support for these properties will utilize them when
> they are present, and the current ath11k .dts files will need to be updated to

It is not related to drivers at all. Nothing in this thread is related
to drivers.

Can we entirely drop the drivers from the discussion?

> include these properties for pci17cb,1103, i.e. the following needs updating:
> arch/arm64/boot/dts/qcom/sc8280xp-lenovo-thinkpad-x13s.dts
> &pcie4_port0 {
> 	wifi@0 {
> 		compatible = "pci17cb,1103";
> 		reg = <0x10000 0x0 0x0 0x0 0x0>;
> 
> 		qcom,ath11k-calibration-variant = "LE_X13S";
> 	};
> };
> 
> 

Best regards,
Krzysztof



  parent reply	other threads:[~2024-09-24  8:07 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-14  8:23 [PATCH net-next v2] dt-bindings: net: ath11k: document the inputs of the ath11k on WCN6855 Bartosz Golaszewski
2024-08-14 16:25 ` Conor Dooley
2024-08-16  8:26 ` Kalle Valo
2024-08-16  9:10   ` Bartosz Golaszewski
2024-09-02  8:34     ` Bartosz Golaszewski
2024-09-05 15:47     ` Kalle Valo
2024-09-05 18:19       ` Bartosz Golaszewski
2024-09-05 18:28         ` Kalle Valo
2024-09-05 21:27           ` Krzysztof Kozlowski
2024-09-06  7:44           ` Bartosz Golaszewski
2024-09-06 18:38             ` Jeff Johnson
2024-09-09  8:19               ` Bartosz Golaszewski
2024-09-09  8:39                 ` Bartosz Golaszewski
2024-09-19  6:55 ` Krzysztof Kozlowski
2024-09-19  7:48   ` Kalle Valo
2024-09-19  8:59     ` Bartosz Golaszewski
2024-09-20  6:22       ` Kalle Valo
2024-09-20  7:58         ` Bartosz Golaszewski
2024-09-19 10:00     ` Krzysztof Kozlowski
2024-09-20  6:45       ` Kalle Valo
2024-09-20  8:22         ` Bartosz Golaszewski
2024-09-20 21:02           ` Jeff Johnson
2024-09-21  4:56             ` Bartosz Golaszewski
2024-09-24  8:06             ` Krzysztof Kozlowski [this message]
2024-09-24 16:46               ` Jeff Johnson
2024-09-24 17:07                 ` Bartosz Golaszewski
2024-09-24  8:04         ` Krzysztof Kozlowski
2024-09-25  5:58           ` Kalle Valo
2024-09-25  7:10             ` Krzysztof Kozlowski
2024-09-28  9:22 ` Kalle Valo

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=1e79d94e-2f83-4762-b126-ed865142f1ed@kernel.org \
    --to=krzk@kernel.org \
    --cc=arnd@arndb.de \
    --cc=ath11k@lists.infradead.org \
    --cc=bartosz.golaszewski@linaro.org \
    --cc=brgl@bgdev.pl \
    --cc=conor+dt@kernel.org \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=edumazet@google.com \
    --cc=jjohnson@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=kuba@kernel.org \
    --cc=kvalo@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=quic_jjohnson@quicinc.com \
    --cc=robh@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