lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5976952b-d5e8-4333-b769-d494b8195689@linaro.org>
Date: Wed, 20 Mar 2024 08:14:08 +0100
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: Alexey Klimov <alexey.klimov@...aro.org>, sre@...nel.org,
 robh@...nel.org, krzysztof.kozlowski+dt@...aro.org,
 linux-pm@...r.kernel.org, devicetree@...r.kernel.org,
 peter.griffin@...aro.org, robh+dt@...nel.org
Cc: conor+dt@...nel.org, linux-samsung-soc@...r.kernel.org,
 semen.protsenko@...aro.org, linux-kernel@...r.kernel.org,
 klimov.linux@...il.com, kernel-team@...roid.com, tudor.ambarus@...aro.org,
 andre.draszik@...aro.org, saravanak@...gle.com, willmcvicker@...gle.com,
 alim.akhtar@...sung.com, linux-arm-kernel@...ts.infradead.org,
 elder@...aro.org
Subject: Re: [PATCH 1/3] dt-bindings: power: reset: add gs101 poweroff
 bindings

On 20/03/2024 03:05, Alexey Klimov wrote:
> Signed-off-by: Alexey Klimov <alexey.klimov@...aro.org>

Missing commit msg.

A nit, subject: drop second/last, redundant "bindings". The
"dt-bindings" prefix is already stating that these are bindings.
See also:
https://elixir.bootlin.com/linux/v6.7-rc8/source/Documentation/devicetree/bindings/submitting-patches.rst#L18

> ---
>  .../power/reset/google,gs101-poweroff.yaml    | 54 +++++++++++++++++++
>  1 file changed, 54 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/power/reset/google,gs101-poweroff.yaml
> 
> diff --git a/Documentation/devicetree/bindings/power/reset/google,gs101-poweroff.yaml b/Documentation/devicetree/bindings/power/reset/google,gs101-poweroff.yaml
> new file mode 100644
> index 000000000000..d704bf28294a
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/power/reset/google,gs101-poweroff.yaml
> @@ -0,0 +1,54 @@
> +# SPDX-License-Identifier: GPL-2.0
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/power/reset/google,gs101-poweroff.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Google GS101 poweroff driver

Bindings are not for drivers, but hardware.

> +
> +maintainers:
> +  - Alexey Klimov <alexey.klimov@...aro.org>
> +
> +description: |+
> +  This is a Google Tensor gs101 poweroff driver using custom regmap

Bindings are not for drivers, but hardware.

> +  to map the poweroff register. The poweroff itself is performed with
> +  a write to the poweroff register from a privileged mode. Since generic
> +  syscon does not support this, the specific one is required.
> +  The write to the poweroff register is defined by the register map pointed
> +  by syscon reference plus the offset with the value and mask defined
> +  in the poweroff node.
> +  Default will be little endian mode, 32 bit access only.
> +
> +properties:
> +  compatible:
> +    const: google,gs101-poweroff
> +
> +  mask:
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    description: Update only the register bits defined by the mask (32 bit).
> +
> +  offset:
> +    $ref: /schemas/types.yaml#/definitions/uint32
> +    description: Offset in the register map for the poweroff register (in bytes).
> +
> +  samsung,syscon-phandle:
> +    $ref: /schemas/types.yaml#/definitions/phandle

This does not look right. The poweroff handling is within PMU, not
somewhere else. Don't use syscons as a replacement of regular MMIO
addresses.



Best regards,
Krzysztof


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ