Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp1459924rdb; Sat, 3 Feb 2024 07:09:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IHoxgC1U26mAP4ALFNjpSoNPNCFF8WOZcFZv4iv9fdWFKW8b2hg+FkMEq/Baf2eGX+SMWEy X-Received: by 2002:a05:6808:1813:b0:3bf:c1e9:9f5e with SMTP id bh19-20020a056808181300b003bfc1e99f5emr5077040oib.55.1706972955200; Sat, 03 Feb 2024 07:09:15 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706972955; cv=pass; d=google.com; s=arc-20160816; b=wJMpaOTkdCa2NrfqNzN+fNRi6iYVrNILrjMeHEvjvciAF/Ff+p0Gc+7VXSB1qyDUGN j9kYR1kB1PbcOQb+Jyqr/xuNncJ0fTLhqN0GA0x11RLbP6OA++2g3Ph2q0lBHPRQqjcP z90zRE69xWs9aBjcO32kZgZucRZ0LOZ6peil4770bBUp6I8ELTt90j5hfs9NQ04U2Rol ckXI5rR7qMk0M4gDbNPCTNWgfeAJ4C9h4bPJAz27tkOV6Zge06bUgG5bdWPfQ58laFdo xCea06ZWObsfGVVrfdSdfc3GGLElSjG+GNniqD490dPr6S4fj1ffTmdPsCbse0fG50dP gZSg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=6by1CTg1ocC7Fc+lsM+Me54b/nbpGnv1LmIPgyM+JZg=; fh=ezV7IJWCVtElfzuQTAXzuUFwFfT7HZxGwjER6l96yWM=; b=JXH6DAv19yfMEHW/ZqmuGyj/aOZlrKN/gWmrR/bWoFyaa356B23IRlX6Qpz0F5myAa OztMLWgdWAM0Q6C04zu1iR2TtHZDox5gApaVX5ovAV+/f4ftqAIN02lAYkfwUkxB4YuX PxodfDU8+KKCkS6zBkKYBX9iuIqS7wpaCnLBmOiC/lobjdDSNUU7KgiU7h3nZjt0vLZf sHk1Nye52yTgI5jp68PAxnurAqJpHTRvYJ6UQYpDi7tJyVnsAGbScXOGJm4uL68B7Yj5 PSxiNP7gtGjUUjVrhXqok5BTh6kFzR9s8ZZk3QHIwbf+htur5N52b2L1BnX39XdnVfao ZE+Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=joSUV3VM; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-51138-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-51138-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=1; AJvYcCX8W86PaR8wUhGdkXaexysq4VJDB2LxcFdHT1zAw5uGSmoRNtEvLCKKVKfkUNoVXzZcUSN3UBmNvPMdcSiORj7xZ3CThjNvpbRnTl20LQ== Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id x18-20020a05622a001200b0042c0eb47eebsi1655108qtw.665.2024.02.03.07.09.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 03 Feb 2024 07:09:15 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-51138-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=joSUV3VM; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-51138-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-51138-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id BE0991C21A0A for ; Sat, 3 Feb 2024 15:09:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D54E75F476; Sat, 3 Feb 2024 15:09:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="joSUV3VM" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D7910386; Sat, 3 Feb 2024 15:09:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706972945; cv=none; b=AVCqsaXv8vY6LAdficpg2bhP+29S+aXA7vfyh0DCYxWipz5+/IH95NsHFCp0PT1LJvg41Ktbec7IXdyyEn6+KlyGUIai+a90z+R+7bVzsSolwhFmyQRvqhn6Hx/xaQwDArbiyzcxfVPsE8DX1cCHZVnNIHQWco6joOhM5pwWsVU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706972945; c=relaxed/simple; bh=n3DQeWHJWDUnE82O0BBKSEXBBTFwmxZR2bU3dokNRDk=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=kykSz8ks2RCQ3noMKuDnIYi1m5cKgu/0ZX6A70hUvRMmEbgB3p0XP7Z8MhmRdsluWAqdLkJyFWR7CqKgnlSOT40xDWuqF8t79G15uHSUfvnJu4X1t/fAdEdxW9atjpWSPOseEUI2+K+ZxYt9jcLHf3GaF/DLuoVfu5fEbUzPKxo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=joSUV3VM; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9CCEAC433F1; Sat, 3 Feb 2024 15:09:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1706972944; bh=n3DQeWHJWDUnE82O0BBKSEXBBTFwmxZR2bU3dokNRDk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=joSUV3VM4rycs/8+EsAkn7lP3I4OCEgqt2ns7lIRdED0K6MuzzofhIRoVC+/okzGn h2tSZcGOQ/ImpmRhUNDtjcXgEekW/dCsf4sxU6THHrXqKoX4p45YcpistEcNgWRHkr eG76v8xhQJPMi+3mKYz1fD5k5GZ8tIcwg3sekctRm+0DG+EF6qR+vYzTmV+QNxmRn3 XkHIme5Ojf+GZE1ONq2wiN1yMj7QPFsMHFd6psU5HphGPF+75cvbwQjGsXfNCATfvq 3VygN4Tn4qLmc04Nlwtq/+/d7HY8cqtHRMobhbXCPHCq5cYitzAkkCdRtJ0G9JfKVB x69x7aOqw4dcQ== Date: Sat, 3 Feb 2024 15:08:59 +0000 From: Conor Dooley To: Josua Mayer Cc: Nishanth Menon , Vignesh Raghavendra , Tero Kristo , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Alessandro Zummo , Alexandre Belloni , Yazan Shhady , linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-rtc@vger.kernel.org Subject: Re: [PATCH v4 2/5] dt-bindings: rtc: abx80x: convert to yaml Message-ID: <20240203-prolonged-backfield-c659e0016d70@spud> References: <20240202-add-am64-som-v4-0-5f8b12af5e71@solid-run.com> <20240202-add-am64-som-v4-2-5f8b12af5e71@solid-run.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="17xXMyX9vB+FnccJ" Content-Disposition: inline In-Reply-To: <20240202-add-am64-som-v4-2-5f8b12af5e71@solid-run.com> --17xXMyX9vB+FnccJ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hey, On Fri, Feb 02, 2024 at 05:10:49PM +0100, Josua Mayer wrote: > Convert the abracon abx80x rtc text bindings to dt-schema format. >=20 > In addition to the text description reference generic interrupts > properties and add an example. >=20 > Signed-off-by: Josua Mayer > --- > .../devicetree/bindings/rtc/abracon,abx80x.txt | 31 --------- > .../devicetree/bindings/rtc/abracon,abx80x.yaml | 74 ++++++++++++++++= ++++++ > 2 files changed, 74 insertions(+), 31 deletions(-) >=20 > diff --git a/Documentation/devicetree/bindings/rtc/abracon,abx80x.txt b/D= ocumentation/devicetree/bindings/rtc/abracon,abx80x.txt > deleted file mode 100644 > index 2405e35a1bc0..000000000000 > --- a/Documentation/devicetree/bindings/rtc/abracon,abx80x.txt > +++ /dev/null > @@ -1,31 +0,0 @@ > -Abracon ABX80X I2C ultra low power RTC/Alarm chip > - > -The Abracon ABX80X family consist of the ab0801, ab0803, ab0804, ab0805,= ab1801, > -ab1803, ab1804 and ab1805. The ab0805 is the superset of ab080x and the = ab1805 > -is the superset of ab180x. > - > -Required properties: > - > - - "compatible": should one of: > - "abracon,abx80x" > - "abracon,ab0801" > - "abracon,ab0803" > - "abracon,ab0804" > - "abracon,ab0805" > - "abracon,ab1801" > - "abracon,ab1803" > - "abracon,ab1804" > - "abracon,ab1805" > - "microcrystal,rv1805" > - Using "abracon,abx80x" will enable chip autodetection. > - - "reg": I2C bus address of the device > - > -Optional properties: > - > -The abx804 and abx805 have a trickle charger that is able to charge the > -connected battery or supercap. Both the following properties have to be = defined > -and valid to enable charging: > - > - - "abracon,tc-diode": should be "standard" (0.6V) or "schottky" (0.3V) > - - "abracon,tc-resistor": should be <0>, <3>, <6> or <11>. 0 disables th= e output > - resistor, the other values are in kOhm. > diff --git a/Documentation/devicetree/bindings/rtc/abracon,abx80x.yaml b/= Documentation/devicetree/bindings/rtc/abracon,abx80x.yaml > new file mode 100644 > index 000000000000..405b386a54b0 > --- /dev/null > +++ b/Documentation/devicetree/bindings/rtc/abracon,abx80x.yaml > @@ -0,0 +1,74 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/rtc/abracon,abx80x.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Abracon ABX80X I2C ultra low power RTC/Alarm chip > + > +maintainers: > + - devicetree@vger.kernel.org Ideally you put someone here, not the DT list. Usually the original author is a good choice, which I think happens to be the subsystem maintainer... Failing that, the rtc subsystem list is likely a better choice than the DT one. > + > +allOf: > + - $ref: rtc.yaml# > + - $ref: /schemas/interrupts.yaml# This should not be need. > + > +properties: > + compatible: > + description: > + Select a specific compatible chip. I'd drop this line. > + 'abracon,abx80x' has special meaning, > + it provides auto-dection based on ID register. And reword this. The compatible itself does not provide auto-detection, it's the opposite - the driver must perform auto detection if this compatible is used. > + enum: > + - abracon,abx80x > + - abracon,ab0801 > + - abracon,ab0803 > + - abracon,ab0804 > + - abracon,ab0805 > + - abracon,ab1801 > + - abracon,ab1803 > + - abracon,ab1804 > + - abracon,ab1805 > + - microcrystal,rv1805 > + > + reg: > + maxItems: 1 > + > + abracon,tc-diode: > + description: > + Trickle-charge diode type. > + Required to enable charging backup battery. > + > + Supported are 'standard' diodes with a 0.6V drop > + and 'schottky' diodes with a 0.3V drop. > + $ref: /schemas/types.yaml#/definitions/string > + enum: > + - standard > + - schottky > + > + abracon,tc-resistor: > + description: > + Trickle-charge resistor value in kOhm. > + Required to enable charging backup battery. > + $ref: /schemas/types.yaml#/definitions/uint32 > + enum: [0, 3, 6, 11] > + > +required: > + - compatible > + - reg > + > +unevaluatedProperties: false > + > +examples: > + - | > + #include > + > + rtc@69 { > + compatible =3D "abracon,abx80x"; > + reg =3D <0x69>; You'll have to make a "fake" i2c bus here to satisfy the tooling. There should be lots of examples for how to do this in other rtc bindings. Thanks, Conor. > + abracon,tc-diode =3D "schottky"; > + abracon,tc-resistor =3D <3>; > + interrupt-parent =3D <&fake_intc0>; > + interrupts =3D <44 IRQ_TYPE_EDGE_FALLING>; > + }; >=20 > --=20 > 2.35.3 >=20 --17xXMyX9vB+FnccJ Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZb5XCwAKCRB4tDGHoIJi 0irkAQCbUpXTrsuLcaoIcKjhRCjmidmeJEVH0ydbqhZIFCeipQD9GXWfXGxujmRu u+QORduBHw9wvIq0cTbVb8HcQlZ5TAE= =ZE4k -----END PGP SIGNATURE----- --17xXMyX9vB+FnccJ--