[PATCH v2 6/8] dt-bindings: wireless: ath12k: Add disable-rfkill property

Dale Whinham posted 8 patches 2 months, 1 week ago
There is a newer version of this series
[PATCH v2 6/8] dt-bindings: wireless: ath12k: Add disable-rfkill property
Posted by Dale Whinham 2 months, 1 week ago
From: Jérôme de Bretagne <jerome.debretagne@gmail.com>

rfkill should be disabled according to the Surface Pro 11's DSDT.

https://lore.kernel.org/all/20250113074810.29729-3-quic_lingbok@quicinc.com/
has added support to read the ACPI bitflag when ACPI is supported.

Document the disable-rfkill property to expose one specific feature
(DISABLE_RFKILL_BIT) for devices described with a DT, so that the
feature can be disabled.

Signed-off-by: Jérôme de Bretagne <jerome.debretagne@gmail.com>
Signed-off-by: Dale Whinham <daleyo@gmail.com>
---
 .../devicetree/bindings/net/wireless/qcom,ath12k.yaml          | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/Documentation/devicetree/bindings/net/wireless/qcom,ath12k.yaml b/Documentation/devicetree/bindings/net/wireless/qcom,ath12k.yaml
index dc68dd59988f..be44b1495ecc 100644
--- a/Documentation/devicetree/bindings/net/wireless/qcom,ath12k.yaml
+++ b/Documentation/devicetree/bindings/net/wireless/qcom,ath12k.yaml
@@ -54,6 +54,9 @@ properties:
   vddpcie1p8-supply:
     description: VDD_PCIE_1P8 supply regulator handle
 
+  disable-rfkill:
+    type: boolean
+
 required:
   - compatible
   - reg
-- 
2.52.0

Re: [PATCH v2 6/8] dt-bindings: wireless: ath12k: Add disable-rfkill property
Posted by Krzysztof Kozlowski 2 months, 1 week ago
On 01/12/2025 02:14, Dale Whinham wrote:
> From: Jérôme de Bretagne <jerome.debretagne@gmail.com>
> 
> rfkill should be disabled according to the Surface Pro 11's DSDT.
> 
> https://lore.kernel.org/all/20250113074810.29729-3-quic_lingbok@quicinc.com/
> has added support to read the ACPI bitflag when ACPI is supported.

It wasn't merged. If it was, reference commits, not random emails.

> 
> Document the disable-rfkill property to expose one specific feature
> (DISABLE_RFKILL_BIT) for devices described with a DT, so that the
> feature can be disabled.

This is just a circular logic. Add property to have property in DT so
that you can use feature.

No, describe the hardware or actual problem instead.

You still need to answer Rob's questions.

Best regards,
Krzysztof
Re: [PATCH v2 6/8] dt-bindings: wireless: ath12k: Add disable-rfkill property
Posted by Jérôme de Bretagne 2 months ago
Le lun. 1 déc. 2025 à 08:34, Krzysztof Kozlowski <krzk@kernel.org> a écrit :
>
> On 01/12/2025 02:14, Dale Whinham wrote:
> > From: Jérôme de Bretagne <jerome.debretagne@gmail.com>
> >
> > rfkill should be disabled according to the Surface Pro 11's DSDT.
> >
> > https://lore.kernel.org/all/20250113074810.29729-3-quic_lingbok@quicinc.com/
> > has added support to read the ACPI bitflag when ACPI is supported.
>
> It wasn't merged. If it was, reference commits, not random emails.

Good catch, It was merged in commit c6a7c0b09d5f, we will reference
this commit instead.

> > Document the disable-rfkill property to expose one specific feature
> > (DISABLE_RFKILL_BIT) for devices described with a DT, so that the
> > feature can be disabled.
>
> This is just a circular logic. Add property to have property in DT so
> that you can use feature.
>
> No, describe the hardware or actual problem instead.

Point taken. Would something like the following be better?

"For some devices, Wi-Fi is entirely hard blocked by default making
the Wi-Fi radio unusable, except if rfkill is disabled as described
by an ACPI bitflag on those models. Add the disable-rfkill property
to expose the DISABLE_RFKILL_BIT feature for devices described
by a devicetree."

> You still need to answer Rob's questions.

Indeed, we didn't answer another question, sorry. Here it is for
reference:

> [Rob] Assuming it belongs in DT, why is this ath12k specific? Could be
> for any wireless chip...

Agree, it could be applicable to any wireless chip, it should be moved
somewhere else. Would ieee80211.yaml be the right target file for
this property? Or any other file suggestion instead? Thank you.

Best regards,
Jérôme
Re: [PATCH v2 6/8] dt-bindings: wireless: ath12k: Add disable-rfkill property
Posted by Krzysztof Kozlowski 2 months ago
On 07/12/2025 20:28, Jérôme de Bretagne wrote:
> Le lun. 1 déc. 2025 à 08:34, Krzysztof Kozlowski <krzk@kernel.org> a écrit :
>>
>> On 01/12/2025 02:14, Dale Whinham wrote:
>>> From: Jérôme de Bretagne <jerome.debretagne@gmail.com>
>>>
>>> rfkill should be disabled according to the Surface Pro 11's DSDT.
>>>
>>> https://lore.kernel.org/all/20250113074810.29729-3-quic_lingbok@quicinc.com/
>>> has added support to read the ACPI bitflag when ACPI is supported.
>>
>> It wasn't merged. If it was, reference commits, not random emails.
> 
> Good catch, It was merged in commit c6a7c0b09d5f, we will reference
> this commit instead.
> 
>>> Document the disable-rfkill property to expose one specific feature
>>> (DISABLE_RFKILL_BIT) for devices described with a DT, so that the
>>> feature can be disabled.
>>
>> This is just a circular logic. Add property to have property in DT so
>> that you can use feature.
>>
>> No, describe the hardware or actual problem instead.
> 
> Point taken. Would something like the following be better?
> 
> "For some devices, Wi-Fi is entirely hard blocked by default making
> the Wi-Fi radio unusable, except if rfkill is disabled as described
> by an ACPI bitflag on those models. Add the disable-rfkill property
> to expose the DISABLE_RFKILL_BIT feature for devices described
> by a devicetree."
> 
>> You still need to answer Rob's questions.
> 
> Indeed, we didn't answer another question, sorry. Here it is for
> reference:
> 
>> [Rob] Assuming it belongs in DT, why is this ath12k specific? Could be
>> for any wireless chip...
> 
> Agree, it could be applicable to any wireless chip, it should be moved
> somewhere else. Would ieee80211.yaml be the right target file for
> this property? Or any other file suggestion instead? Thank you.

Yes, then place it please in above iee80211.yaml common file, with some
sort of bigger picture explanation.


Best regards,
Krzysztof
Re: [PATCH v2 6/8] dt-bindings: wireless: ath12k: Add disable-rfkill property
Posted by Rob Herring (Arm) 2 months, 1 week ago
On Mon, 01 Dec 2025 01:14:47 +0000, Dale Whinham wrote:
> From: Jérôme de Bretagne <jerome.debretagne@gmail.com>
> 
> rfkill should be disabled according to the Surface Pro 11's DSDT.
> 
> https://lore.kernel.org/all/20250113074810.29729-3-quic_lingbok@quicinc.com/
> has added support to read the ACPI bitflag when ACPI is supported.
> 
> Document the disable-rfkill property to expose one specific feature
> (DISABLE_RFKILL_BIT) for devices described with a DT, so that the
> feature can be disabled.
> 
> Signed-off-by: Jérôme de Bretagne <jerome.debretagne@gmail.com>
> Signed-off-by: Dale Whinham <daleyo@gmail.com>
> ---
>  .../devicetree/bindings/net/wireless/qcom,ath12k.yaml          | 3 +++
>  1 file changed, 3 insertions(+)
> 

My bot found errors running 'make dt_binding_check' on your patch:

yamllint warnings/errors:

dtschema/dtc warnings/errors:


doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20251201011457.17422-7-daleyo@gmail.com

The base for the series is generally the latest rc1. A different dependency
should be noted in *this* patch.

If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit after running the above command yourself. Note
that DT_SCHEMA_FILES can be set to your schema file to speed up checking
your schema. However, it must be unset to test all examples with your schema.