mirror of
https://github.com/torvalds/linux.git
synced 2026-11-07 06:17:02 +01:00
dt-bindings: rtc: Add pinctrl for S35390A
Synology NAS devices use the output pin for interrupt signal 1 to wake up the system. Move devicetree bindings for sii,s35390a into its own file. Add necessary properties to configure the individual pins via pinctrl, which allows the interrupt signal 1 to be used for wakeup alarm. Signed-off-by: Markus Probst <markus.probst@posteo.de> Reviewed-by: Rob Herring (Arm) <robh@kernel.org> Reviewed-by: Linus Walleij <linusw@kernel.org> Link: https://patch.msgid.link/20260930-rtc_s35390a_int1-v10-1-e7b1cbc50a7b@posteo.de Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
This commit is contained in:
parent
c1c260266a
commit
2166aaa173
118
Documentation/devicetree/bindings/rtc/sii,s35390a.yaml
Normal file
118
Documentation/devicetree/bindings/rtc/sii,s35390a.yaml
Normal file
|
|
@ -0,0 +1,118 @@
|
|||
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
|
||||
%YAML 1.2
|
||||
---
|
||||
$id: http://devicetree.org/schemas/rtc/sii,s35390a.yaml#
|
||||
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
||||
|
||||
title: S-35390A 2-wire real-time clock
|
||||
|
||||
maintainers:
|
||||
- Markus Probst <markus.probst@posteo.de>
|
||||
|
||||
description:
|
||||
The S-35390A is a CMOS 2-wire real-time clock IC which operates with the
|
||||
very low current consumption in the wide range of operation voltage.
|
||||
|
||||
allOf:
|
||||
- $ref: rtc.yaml#
|
||||
|
||||
properties:
|
||||
compatible:
|
||||
const: sii,s35390a
|
||||
|
||||
reg:
|
||||
maxItems: 1
|
||||
|
||||
interrupts:
|
||||
minItems: 1
|
||||
maxItems: 2
|
||||
description: Supports up to 2 interrupt lines via the INT1 and INT2 pins.
|
||||
|
||||
interrupt-names:
|
||||
minItems: 1
|
||||
maxItems: 2
|
||||
items:
|
||||
enum:
|
||||
- int1
|
||||
- int2
|
||||
|
||||
wakeup-parent: true
|
||||
|
||||
wakeup-source: true
|
||||
|
||||
"#clock-cells":
|
||||
const: 1
|
||||
|
||||
patternProperties:
|
||||
"^pins":
|
||||
type: object
|
||||
additionalProperties: false
|
||||
|
||||
patternProperties:
|
||||
"-pins$":
|
||||
$ref: /schemas/pinctrl/pinmux-node.yaml#
|
||||
additionalProperties: false
|
||||
|
||||
properties:
|
||||
pins:
|
||||
minItems: 1
|
||||
items:
|
||||
enum:
|
||||
- int1
|
||||
- int2
|
||||
|
||||
function:
|
||||
description: |
|
||||
Pin function:
|
||||
- ignore: Preserve the previous state.
|
||||
- disable: Disable pin output.
|
||||
- wakeup: Output wakes up the system.
|
||||
- clock: Output clock pulse.
|
||||
- pmin1: Minute periodical output with 50% duty.
|
||||
- pmin2: Minute periodical output L for 7.81 ms.
|
||||
Can only be used with pin int1.
|
||||
enum:
|
||||
- ignore
|
||||
- disable
|
||||
- wakeup
|
||||
- clock
|
||||
- pmin1
|
||||
- pmin2
|
||||
|
||||
required:
|
||||
- pins
|
||||
- function
|
||||
|
||||
required:
|
||||
- compatible
|
||||
- reg
|
||||
|
||||
unevaluatedProperties: false
|
||||
|
||||
examples:
|
||||
- |
|
||||
i2c {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
rtc@30 {
|
||||
compatible = "sii,s35390a";
|
||||
reg = <0x30>;
|
||||
pinctrl-0 = <&rtc_pins_default>;
|
||||
pinctrl-names = "default";
|
||||
|
||||
interrupt-names = "int1";
|
||||
interrupts = <23>;
|
||||
|
||||
rtc_pins_default: pins {
|
||||
int1-pins {
|
||||
pins = "int1";
|
||||
function = "wakeup";
|
||||
};
|
||||
int2-pins {
|
||||
pins = "int2";
|
||||
function = "disable";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
@ -81,8 +81,6 @@ properties:
|
|||
- ricoh,rv5c386
|
||||
# I2C bus SERIAL INTERFACE REAL-TIME CLOCK IC
|
||||
- ricoh,rv5c387a
|
||||
# 2-wire CMOS real-time clock
|
||||
- sii,s35390a
|
||||
# ST SPEAr Real-time Clock
|
||||
- st,spear600-rtc
|
||||
# VIA/Wondermedia VT8500 Real-time Clock
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user