diff mbox series

[v1,1/2] dt-bindings: net: bluetooth: nxp: Add support for power save feature using GPIO

Message ID 20241001174021.522254-2-neeraj.sanjaykale@nxp.com (mailing list archive)
State Superseded
Headers show
Series Bluetooth: btnxpuart: Add GPIO mechanism to | expand

Checks

Context Check Description
tedd_an/pre-ci_am success Success
tedd_an/CheckPatch success CheckPatch PASS
tedd_an/GitLint fail WARNING: I3 - ignore-body-lines: gitlint will be switching from using Python regex 'match' (match beginning) to 'search' (match anywhere) semantics. Please review your ignore-body-lines.regex option accordingly. To remove this warning, set general.regex-style-search=True. More details: https://jorisroovers.github.io/gitlint/configuration/#regex-style-search 1: T1 Title exceeds max length (88>80): "[v1,1/2] dt-bindings: net: bluetooth: nxp: Add support for power save feature using GPIO"
tedd_an/SubjectPrefix fail "Bluetooth: " prefix is not specified in the subject
tedd_an/BuildKernel success BuildKernel PASS
tedd_an/CheckAllWarning success CheckAllWarning PASS
tedd_an/CheckSparse success CheckSparse PASS

Commit Message

Neeraj Sanjay Kale Oct. 1, 2024, 5:40 p.m. UTC
This adds a new optional device tree property called h2c-ps-gpio.

If this property is defined, the driver will use this GPIO for driving chip
into sleep/wakeup state.

Signed-off-by: Neeraj Sanjay Kale <neeraj.sanjaykale@nxp.com>
---
 .../devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml  | 7 +++++++
 1 file changed, 7 insertions(+)

Comments

Krzysztof Kozlowski Oct. 1, 2024, 6:03 p.m. UTC | #1
On 01/10/2024 19:40, Neeraj Sanjay Kale wrote:
> This adds a new optional device tree property called h2c-ps-gpio.
> 
> If this property is defined, the driver will use this GPIO for driving chip
> into sleep/wakeup state.

You described the desired Linux feature or behavior, not the actual
hardware. The bindings are about the latter, so instead you need to
rephrase this to match actual hardware
capabilities/features/configuration etc.

> 
> Signed-off-by: Neeraj Sanjay Kale <neeraj.sanjaykale@nxp.com>
> ---
>  .../devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml  | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml b/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
> index 37a65badb448..e4eeee9bed68 100644
> --- a/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
> +++ b/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
> @@ -34,6 +34,11 @@ properties:
>    firmware-name:
>      maxItems: 1
>  
> +  h2c-ps-gpio:
> +    maxItems: 1
> +    description:
> +      Host-To-Chip power save mechanism is driven by this GPIO.

Which pin is it?

> +



Best regards,
Krzysztof
Rob Herring (Arm) Oct. 2, 2024, 9:05 p.m. UTC | #2
On Tue, Oct 01, 2024 at 11:10:20PM +0530, Neeraj Sanjay Kale wrote:
> This adds a new optional device tree property called h2c-ps-gpio.
> 
> If this property is defined, the driver will use this GPIO for driving chip
> into sleep/wakeup state.
> 
> Signed-off-by: Neeraj Sanjay Kale <neeraj.sanjaykale@nxp.com>
> ---
>  .../devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml  | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml b/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
> index 37a65badb448..e4eeee9bed68 100644
> --- a/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
> +++ b/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
> @@ -34,6 +34,11 @@ properties:
>    firmware-name:
>      maxItems: 1
>  
> +  h2c-ps-gpio:

'-gpio' is deprecated. Use '-gpios'.

> +    maxItems: 1
> +    description:
> +      Host-To-Chip power save mechanism is driven by this GPIO.
> +
>  required:
>    - compatible
>  
> @@ -41,10 +46,12 @@ additionalProperties: false
>  
>  examples:
>    - |
> +    #include <dt-bindings/gpio/gpio.h>
>      serial {
>          bluetooth {
>              compatible = "nxp,88w8987-bt";
>              fw-init-baudrate = <3000000>;
>              firmware-name = "uartuart8987_bt_v0.bin";
> +            h2c-ps-gpio = <&gpio 11 GPIO_ACTIVE_HIGH>;
>          };
>      };
> -- 
> 2.25.1
>
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml b/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
index 37a65badb448..e4eeee9bed68 100644
--- a/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
+++ b/Documentation/devicetree/bindings/net/bluetooth/nxp,88w8987-bt.yaml
@@ -34,6 +34,11 @@  properties:
   firmware-name:
     maxItems: 1
 
+  h2c-ps-gpio:
+    maxItems: 1
+    description:
+      Host-To-Chip power save mechanism is driven by this GPIO.
+
 required:
   - compatible
 
@@ -41,10 +46,12 @@  additionalProperties: false
 
 examples:
   - |
+    #include <dt-bindings/gpio/gpio.h>
     serial {
         bluetooth {
             compatible = "nxp,88w8987-bt";
             fw-init-baudrate = <3000000>;
             firmware-name = "uartuart8987_bt_v0.bin";
+            h2c-ps-gpio = <&gpio 11 GPIO_ACTIVE_HIGH>;
         };
     };