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: <20240227010312.3305966-3-chris.packham@alliedtelesis.co.nz>
Date: Tue, 27 Feb 2024 14:03:10 +1300
From: Chris Packham <chris.packham@...iedtelesis.co.nz>
To: antoniu.miclaus@...log.com,
	alexandre.belloni@...tlin.com,
	robh+dt@...nel.org,
	krzysztof.kozlowski+dt@...aro.org,
	conor+dt@...nel.org,
	jdelvare@...e.com,
	linux@...ck-us.net
Cc: linux-rtc@...r.kernel.org,
	devicetree@...r.kernel.org,
	linux-kernel@...r.kernel.org,
	linux-hwmon@...r.kernel.org,
	Ibrahim Tilki <Ibrahim.Tilki@...log.com>,
	Zeynep Arslanbenzer <Zeynep.Arslanbenzer@...log.com>,
	Chris Packham <chris.packham@...iedtelesis.co.nz>
Subject: [PATCH v8 2/2] dt-bindings: rtc: add max313xx RTCs

From: Ibrahim Tilki <Ibrahim.Tilki@...log.com>

Add devicetree binding documentation for Analog Devices MAX313XX RTCs.
This combines the new models with the existing max31335 binding.

Signed-off-by: Ibrahim Tilki <Ibrahim.Tilki@...log.com>
Signed-off-by: Zeynep Arslanbenzer <Zeynep.Arslanbenzer@...log.com>
Signed-off-by: Chris Packham <chris.packham@...iedtelesis.co.nz>
---
 .../devicetree/bindings/rtc/adi,max31335.yaml | 88 ++++++++++++++++---
 1 file changed, 78 insertions(+), 10 deletions(-)

diff --git a/Documentation/devicetree/bindings/rtc/adi,max31335.yaml b/Documentation/devicetree/bindings/rtc/adi,max31335.yaml
index 0125cf6727cc..ad8d6fec9a2b 100644
--- a/Documentation/devicetree/bindings/rtc/adi,max31335.yaml
+++ b/Documentation/devicetree/bindings/rtc/adi,max31335.yaml
@@ -1,36 +1,54 @@
 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+# Copyright 2022 Analog Devices Inc.
 %YAML 1.2
 ---
 $id: http://devicetree.org/schemas/rtc/adi,max31335.yaml#
 $schema: http://devicetree.org/meta-schemas/core.yaml#
 
-title: Analog Devices MAX31335 RTC
+title: Analog Devices MAX313XX series I2C RTCs
 
 maintainers:
   - Antoniu Miclaus <antoniu.miclaus@...log.com>
+  - Chris Packham <chris.packham@...iedtelesis.co.nz>
 
-description:
-  Analog Devices MAX31335 I2C RTC ±2ppm Automotive Real-Time Clock with
-  Integrated MEMS Resonator.
-
-allOf:
-  - $ref: rtc.yaml#
+description: Analog Devices MAX313XX series I2C RTCs.
 
 properties:
   compatible:
-    const: adi,max31335
+    enum:
+      - adi,max31328
+      - adi,max31329
+      - adi,max31331
+      - adi,max31334
+      - adi,max31335
+      - adi,max31341
+      - adi,max31342
+      - adi,max31343
 
   reg:
-    maxItems: 1
+    description: I2C address of the RTC
+    items:
+      - enum: [0x68, 0x69]
 
   interrupts:
+    description:
+      Alarm1 interrupt line of the RTC. Some of the RTCs have two interrupt
+      lines and alarm1 interrupt muxing depends on the clockin/clockout
+      configuration.
     maxItems: 1
 
   "#clock-cells":
     description:
-      RTC can be used as a clock source through its clock output pin.
+      RTC can be used as a clock source through its clock output pin when
+      supplied.
     const: 0
 
+  clocks:
+    description:
+      RTC uses this clock for clock input when supplied. Clock has to provide
+      one of these four frequencies - 1Hz, 50Hz, 60Hz or 32.768kHz.
+    maxItems: 1
+
   adi,tc-diode:
     description:
       Select the diode configuration for the trickle charger.
@@ -48,6 +66,56 @@ required:
   - compatible
   - reg
 
+allOf:
+  - $ref: rtc.yaml#
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - adi,max31328
+              - adi,max31342
+
+    then:
+      properties:
+        aux-voltage-chargeable: false
+        trickle-resistor-ohms: false
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - adi,max31328
+              - adi,max31331
+              - adi,max31334
+              - adi,max31335
+              - adi,max31343
+
+    then:
+      properties:
+        clocks: false
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - adi,max31341
+              - adi,max31342
+
+    then:
+      properties:
+        reg:
+          items:
+            - const: 0x69
+
+    else:
+      properties:
+        reg:
+          items:
+            - const: 0x68
+
 unevaluatedProperties: false
 
 examples:
-- 
2.43.2


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ