lkml.org 
[lkml]   [2024]   [May]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3 1/3] dt-bindings: hwmon: Add adt7475 fan/pwm properties
On Mon, May 20, 2024 at 03:03:19PM +1200, Chris Packham wrote:
> Add fan child nodes that allow describing the connections for the
> ADT7475 to the fans it controls. This also allows setting some
> initial values for the pwm duty cycle and frequency.
>
> Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
> ---
>
> Notes:
> Changes in v3:
> - Use the pwm provider/consumer bindings
> Changes in v2:
> - Document 0 as a valid value (leaves hardware as-is)
>
> .../devicetree/bindings/hwmon/adt7475.yaml | 25 ++++++++++++++++++-
> 1 file changed, 24 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/hwmon/adt7475.yaml b/Documentation/devicetree/bindings/hwmon/adt7475.yaml
> index 051c976ab711..99bd689ae0cd 100644
> --- a/Documentation/devicetree/bindings/hwmon/adt7475.yaml
> +++ b/Documentation/devicetree/bindings/hwmon/adt7475.yaml
> @@ -51,6 +51,15 @@ properties:
> enum: [0, 1]
> default: 1
>
> + "#pwm-cells":
> + const: 4
> + description: |
> + Number of cells in a PWM specifier.
> + - 0: The pwm channel
> + - 1: The pwm frequency in hertz - 0, 11, 14, 22, 29, 35, 44, 58, 88, 22500

The standard binding is period in nanoseconds, not frequency in Hz.
What's gained from deviating from that?

> + - 2: PWM flags 0 or PWM_POLARITY_INVERTED
> + - 3: The default pwm duty cycle - 0-255

Same here I guess, why not match the units used for the period for the
duty cycle?

Cheers,
Conor.
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2024-05-20 18:49    [W:0.042 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site