From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mout01.posteo.de (mout01.posteo.de [185.67.36.65]) (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 8155F30BBBC for ; Tue, 21 Apr 2026 16:25:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.67.36.65 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776788716; cv=none; b=KpumiGqiIh5pnl293pQqX624F49Zs0oEzPk3U45Dt6J3NnzE3hsbHf0p0mUjWvIxdWLQXOZanmp72M+T2OSzovPydGNUJNsEBwj5V9puRgEGTYmzZ0vruLY9fV+Sv/EOYHsIEIu0V1ZpKa6mXWmHAkj9Ar7ZGp0m5jJqNae70CE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1776788716; c=relaxed/simple; bh=olIDjavRa7iyUYJTNhkrwZs+QbBFZD3TzoyGv9kPUrc=; h=Message-ID:Subject:From:To:Cc:Date:In-Reply-To:References: Content-Type:MIME-Version; b=MbKHg14uG4N4xiKO/qC4J3prdhoSM3JpcAJvd1s6nrbTyvAwSuXcbQdBSzXemA4zJQLQMTU6oFxetIGTU7u2qmbPwRlBgn9EGyYbOMWBHO6KZBPkP/Y8obKTwvaGr4Uiars/6mIEw7mAF+p6zREbWFQa7oiyry5pEkw3Wqcjh5U= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=posteo.de; spf=pass smtp.mailfrom=posteo.de; dkim=pass (2048-bit key) header.d=posteo.de header.i=@posteo.de header.b=VtVh+rhi; arc=none smtp.client-ip=185.67.36.65 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=posteo.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=posteo.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=posteo.de header.i=@posteo.de header.b="VtVh+rhi" Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 99A5E24002E for ; Tue, 21 Apr 2026 18:25:12 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=posteo.de; s=2017; t=1776788712; bh=xkStJTdt1UvdkTxyjSXbcae1im2J5rPNy90X5454nzI=; h=Message-ID:Subject:From:To:Cc:Date:Autocrypt:Content-Type: MIME-Version:OpenPGP:From; b=VtVh+rhiOzP8h7hOlf1oBvqe0mHuDnI5N/CCbcYRcAt18jTdkoPI9ffzlLtzdymVP gQ2ehGpK7k9Y79W+7sfQAqkeYnbS6F2DCyF1XeYJi6RZ1gMf2xwa6XZjxuwbr2ooIc 9L/2QQyC+gATAL6hwAJZXDrLdI3t2MUzV5f2NF2W+yTBhpK+BvYojaCaOjEfeTXyay 7jUhjoZ191wpqhV5Vu1kddc4PN6ZWy3qp/pzbYA/hFXeTqGyF3DEh5vyex/5BNK4SV /BJqOZS6EKBvyHySTdQsNa0LyBQkK48VFfxGDVljhHqXQBf4nPzFeNjclo5q4EErhx kfQenoYtfUd+A== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4g0SPf1Cdsz9rxB; Tue, 21 Apr 2026 18:25:09 +0200 (CEST) Message-ID: <33e04947d6d55035fe310935281a4f0b9e87ae08.camel@posteo.de> Subject: Re: [PATCH v8 1/2] dt-bindings: embedded-controller: Add synology microp devices From: Markus Probst To: Krzysztof Kozlowski Cc: Hans de Goede , Ilpo =?ISO-8859-1?Q?J=E4rvinen?= , Bryan O'Donoghue , Lee Jones , Pavel Machek , Miguel Ojeda , Boqun Feng , Gary Guo , =?ISO-8859-1?Q?Bj=F6rn?= Roy Baron , Benno Lossin , Andreas Hindborg , Alice Ryhl , Trevor Gross , Danilo Krummrich , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Greg Kroah-Hartman , platform-driver-x86@vger.kernel.org, linux-leds@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org Date: Tue, 21 Apr 2026 16:25:11 +0000 In-Reply-To: References: <20260420-synology_microp_initial-v8-0-7946a9124491@posteo.de> <20260420-synology_microp_initial-v8-1-7946a9124491@posteo.de> <20260421-just-benevolent-dormouse-2c35ed@quoll> <26b074972581ff398b5af964ba092c8117855062.camel@posteo.de> Autocrypt: addr=markus.probst@posteo.de; prefer-encrypt=mutual; keydata=mQINBGiDvXgBEADAXUceKafpl46S35UmDh2wRvvx+UfZbcTjeQOlSwKP7YVJ4JOZrVs93 qReNLkOWguIqPBxR9blQ4nyYrqSCV+MMw/3ifyXIm6Pw2YRUDg+WTEOjTixRCoWDgUj1nOsvJ9tVA m76Ww+/pAnepVRafMID0rqEfD9oGv1YrfpeFJhyE2zUw3SyyNLIKWD6QeLRhKQRbSnsXhGLFBXCqt 9k5JARhgQof9zvztcCVlT5KVvuyfC4H+HzeGmu9201BVyihJwKdcKPq+n/aY5FUVxNTgtI9f8wIbm fAjaoT1pjXSp+dszakA98fhONM98pOq723o/1ZGMZukyXFfsDGtA3BB79HoopHKujLGWAGskzClwT jRQxBqxh/U/lL1pc+0xPWikTNCmtziCOvv0KA0arDOMQlyFvImzX6oGVgE4ksKQYbMZ3Ikw6L1Rv1 J+FvN0aNwOKgL2ztBRYscUGcQvA0Zo1fGCAn/BLEJvQYShWKeKqjyncVGoXFsz2AcuFKe1pwETSsN 6OZncjy32e4ktgs07cWBfx0v62b8md36jau+B6RVnnodaA8++oXl3FRwiEW8XfXWIjy4umIv93tb8 8ekYsfOfWkTSewZYXGoqe4RtK80ulMHb/dh2FZQIFyRdN4HOmB4FYO5sEYFr9YjHLmDkrUgNodJCX CeMe4BO4iaxUQARAQABtCdNYXJrdXMgUHJvYnN0IDxtYXJrdXMucHJvYnN0QHBvc3Rlby5kZT6JAl QEEwEIAD4CGwMFCwkIBwICIgIGFQoJCAs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ELWeQVHSNDi9JabR/UzlR4NSnhfAjRIVlRM+eFbUl8XwxwVrAkojF5IraH2qRvg VCmuFsHUW07FUlrDrzpjXsD73cKppoFGDCdDR0BHJepXbFLS9+AqkT+guRJlnCTg2p+TQtnbwPgKp Vj98JixovCl99zRYTsL2bRNU5+q8iET65VMJ1ydyNanvLd5vI/NqDkXhlXLsGmdaDTtu4R21PkToX dQNGrZ91M9nlIBKw8Y7c7xZ4098qX2b8JX/CxD+gC1r4C8vuA3GkhFLx+KlkON7LyiJPkrePp6Qky jfGillcaQOqFZ3WwVqyzG1BUfTow== Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="=-PEBAOPbuxbtR+GiM4GcY" Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 OpenPGP: url=https://posteo.de/keys/markus.probst@posteo.de.asc; preference=encrypt --=-PEBAOPbuxbtR+GiM4GcY Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, 2026-04-21 at 17:32 +0200, Krzysztof Kozlowski wrote: > On 21/04/2026 16:50, Markus Probst wrote: > > On Tue, 2026-04-21 at 09:07 +0200, Krzysztof Kozlowski wrote: > > > On Mon, Apr 20, 2026 at 02:24:20PM +0000, Markus Probst wrote: > > > > Add the Synology Microp devicetree bindings. Those devices are > > > > microcontrollers found on Synology NAS devices. They are connected = to a > > > > serial port on the host device. > > > >=20 > > > > Those devices are used to control certain LEDs, fan speeds, a beepe= r, to > > > > handle buttons, fan failures and to properly shutdown and reboot th= e > > > > device. > > > >=20 > > > > The device has a different feature set depending on the Synology NA= S > > > > model, like having different number of fans, buttons and leds. Depe= nding > > > > on the architecture of the model, they also need a different system > > > > shutdown behaviour. > > > >=20 > > > > Signed-off-by: Markus Probst > > > > --- > > > > .../synology,ds1825p-microp.yaml | 108 +++++++++= ++++++++++++ > > > > 1 file changed, 108 insertions(+) > > > >=20 > > > > diff --git a/Documentation/devicetree/bindings/embedded-controller/= synology,ds1825p-microp.yaml b/Documentation/devicetree/bindings/embedded-c= ontroller/synology,ds1825p-microp.yaml > > > > new file mode 100644 > > > > index 000000000000..76c671a42fbf > > > > --- /dev/null > > > > +++ b/Documentation/devicetree/bindings/embedded-controller/synolog= y,ds1825p-microp.yaml > > > > @@ -0,0 +1,108 @@ > > > > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > > > > +%YAML 1.2 > > > > +--- > > > > +$id: http://devicetree.org/schemas/embedded-controller/synology,ds= 1825p-microp.yaml# > > > > +$schema: http://devicetree.org/meta-schemas/core.yaml# > > > > + > > > > +title: Synology NAS on-board Microcontroller > > > > + > > > > +maintainers: > > > > + - Markus Probst > > > > + > > > > +description: | > > > > + Synology Microp is a microcontroller found in Synology NAS devic= es. > > > > + It is connected to a serial port on the host device. > > > > + > > > > + It is necessary to properly shutdown and reboot the NAS device a= nd > > > > + provides additional functionality such as led control, fan speed= control, > > > > + a beeper and buttons on the NAS device. > > > > + > > > > +properties: > > > > + compatible: > > > > + oneOf: > > > > + - const: synology,ds223-microp > > > > + - const: synology,ds411p-microp > > > > + - const: synology,ds1010p-microp > > > > + - const: synology,ds710p-microp > > > > + - const: synology,ds723p-microp > > > > + - const: synology,ds225p-microp > > > > + - const: synology,rs422p-microp > > >=20 > > > That's one enum. > > >=20 > > > > + - maxItems: 2 > > > > + minItems: 2 > > >=20 > > > There is no such syntax foro compatibles. Please use any existing fil= e > > > as example or look at example-schema. > > In the example schema, another device is used as fallback.=20 >=20 > True. >=20 > > This is what > > I did here. >=20 > Not true. You have enum and min/maxItems. There is no such syntax for > compatibles. I repeat. >=20 > Instead of just blindly disagreeing and saying "I did that", point me to > example-schema having compatibles with min/maxItems. It is supposed to minimize the schema, otherwise - minItems: 3 maxItems: 3 items: enum: - synology,ds223j-microp - synology,ds124-microp - synology,ds118-microp would have been - items: - const: synology,ds223j-microp - const: synology,ds124-microp - const: synology,ds118-microp - items: - const: synology,ds124-microp - const: synology,ds223j-microp - const: synology,ds118-microp - items: - const: synology,ds118-microp - const: synology,ds223j-microp - const: synology,ds124-microp . In the case of dts validation, this is the same, with the exception of allowing any order. See below why the order does not matter. And yes, the example schema didn't use min/maxItems. >=20 >=20 >=20 > >=20 > >=20 > > Other sources suggest, I should add fallbacks that are less specific >=20 > That's not really discussed here. It all looks like some random schema > and considering amount of LLM flying on the lists I have now doubts. I am not using an LLM for coding. But it is the first device tree schema I try to write. >=20 > You need specific compatibles. > ... >=20 > >=20 > > If thisisn't fine either, replying to my previous message would > > probably the most efficient way to move forward [1]. >=20 >=20 > >=20 > > >=20 > > > > + items: > > > > + enum: > > >=20 > > > No, why the list is randomly ordered. >=20 > Look here Was answered below. They have the exactly same known feature set, thus the order does not matter. i. e. there is no known difference. >=20 > > >=20 > > > > + - synology,ds923p-microp > > > > + - synology,ds1522p-microp > > >=20 > > > And fallback, whichever is that, is not documented alone. > > >=20 > > > > + - minItems: 4 > > > > + maxItems: 4 > >=20 > > Those are devices with the exactly same known feature set. > > i. e. ds1522p can act as a fallback for ds923p, and ds923p could act as > > a fallback for ds1522p. >=20 > You are not responding to actual comments. Lets focus ONLY on above > list. ONLY. Point me, where did you document the fallback to be used > alone? First of course, define what is the fallback. In this schema, I defined ds923p as fallback for ds1522p, and ds1522p as fallback for ds923p. There was no separation of front and fallback until now. See below. >=20 > None of this matches example schema or any other bindings, none of this > produces correct constraints for correct DTS. >=20 > You need a defined enum of fallbacks and several lists for specific > fallback+front, like many other bindings in kernel. So now I can imagine what schema you want to see. i. e. - items: - enum: - front1 - front2 - front3 - const: fallback1 - items: - enum: - front4 - front5 - front6 - const: fallback2 - enum: - fallback1 - fallback2 But I am unsure how to determine which devices are the fallback and which are the front devices, given some of them have the same feature set. The oldest device as fallback each? Thanks - Markus Probst >=20 > Best regards, > Krzysztof --=-PEBAOPbuxbtR+GiM4GcY Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- iQJPBAABCAA5FiEEgnQYxPSsWOdyMMRzNHYf+OetQ9IFAmnnpN4bFIAAAAAABAAO bWFudTIsMi41KzEuMTIsMiwyAAoJEDR2H/jnrUPSv6oP/iKhbUeOAa2H/ZZm3YR1 hzPYkSPjRLGJgtboxyOkha/fHQUbbSFILkuZhwF2Auqt1456XitahIkpOr5XmiTV lrDptKc7VHSiC+lf6MMiA/LLOnRMt5DlFDPwpxnTzFchnUoqag+6mTnVEFfv4AxS HlSGEiOdkLdnRrNNyZImVGdRY9YAY3hZjjA6vKhkAEr34Zaf+f7kML+8iFQyCOdx BkR2TtGqakkGWqSkDiV+KQWZPKvio0ZL8dNe+qAibgTuC0E5ZiMJzyHYiw+JP9De 8txnKm3yUV18+tah8fqsvRQKuUHGODCaZoUDyid7g54ZVwJChmRJa78oltI8hZeY mPzuCmtDC3Hnrt7rfzCN/jTukAlDAGmZrSqrWsqwq2Zp1kqRM87U6x0HznNPVTjs U9qq/JN4zJj57dAXtbJg/lp84lDFsd58jIDtc+2E9eLvLj8Ji4nxumKCanrBudgd WX4cWJ9Oh/Jlq/B7Q+WLIhuPdhxvFFO6ThoIAd0/q8iC1K62h0NzXoJqpwJz38Gj DAELHq6uLll8NEWuRLJkdQzbYXixF3q+EaIeg6kzkCQ8WZ6YkUj8uxa/JAOA/smE RxyBM5GSG+dMVYjZ8fGxQ/9g/4PrmXFDiQfWNui0tVclaaveG+58zE3bRQfI6BVr q2BWCOJ+FR26o5f6NCYa9jWk =v/TB -----END PGP SIGNATURE----- --=-PEBAOPbuxbtR+GiM4GcY--