From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pl1-f174.google.com (mail-pl1-f174.google.com [209.85.214.174]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 05C8948F836 for ; Fri, 21 Aug 2026 12:37:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.174 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787315856; cv=none; b=eotUvqZ2MJ2H8UdG60DGVptxMkO/TC2RhcjVAUdRXA+mXS0BU0Co/hBrJtjmgQmt164qnYX1yKnhrjR00feeg2bpcSiXUDsT4y8nO308GVC24Y5DhSHl34dN5WyH7HLiHYmz5a5jBKaRMmPGgSFAPxNksMRLIl43v6jgzbbXSLw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787315856; c=relaxed/simple; bh=fd/UT7AxPRQvjkXClDym0Mq1d/+IXDaxoIQ4lUKy8qE=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=P42snIFLzd3c0R91VhJRkXJy4caD2hL/77tHmBBUduGqF6DJhzts20YyH8hSQ1O+9dFPVQrF4q3XwSm0tTInwH4fKUjttO2II0yyM4cbV7nz+XLsRHNFUgGh5De6TwhIyBfm6LT84PV4HMXenG5mTiCwc8Vniw3XbxqLpOksubE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=rps2IpGD; arc=none smtp.client-ip=209.85.214.174 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="rps2IpGD" Received: by mail-pl1-f174.google.com with SMTP id d9443c01a7336-2cf27856f9cso9469835ad.2 for ; Fri, 21 Aug 2026 05:37:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1787315854; x=1787920654; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to:content-type; bh=VlPMLvuSyJKeKr15QpRC8H8+tqS38ya8JdOW5OZvk7k=; b=rps2IpGDSLOhg3xBYaYV5XEVw6dtYCb3vqAix2ensjv7WvMoq3L4+qYguzt0CYsA2K 1HatvHHMrlo7I3Q0TkCAWej9dPLpf5EwGUXu/zcZ+SvBo/LOZw3UhYLaGH43qCbj8xdX jTEfh1IR+Fs/YYVJwh1TqTNMHs1jQa99dhLYUtiv5M3YvA2pgE4jAR5EynISPwhc7qtu GSPVUCl0duF97h5uNJvRFB9/DyTN/I1EvqNkEl+CDc6kNoX5o+/sCnMmcjZ3jxNSCKc6 XGEAGp3pCNfabbxLhxTyZ0vxK5uc64g1Ew4+dz95hJAzJrJzXjeuawzy/iQVBSneSLeb qUig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1787315854; x=1787920654; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=VlPMLvuSyJKeKr15QpRC8H8+tqS38ya8JdOW5OZvk7k=; b=jz+8euUjxSaTY/kPDiM5iTVoUluF+YdTDY3M9lazqfhV8EDbOl69TnzXKILGEbcgLY jO8nVPMk81C7QLAjKKt5ELSPKIQKxJQQnWSBQypvRipb1fBE3S9EfbZq5aTcfrZOEZXy SwEgzWv71QkZfHkwpcA+fMW6MiWabyIV0f+xWQbhdslyL8rhXcq+s5Mi30ERShC3UblL bX5Yngyie0kNygajMIxC/C2uwT3TAtWZMz39bq7yMlYZ43mU0ZwlhWQrcsp0FLVrvnWR yiE1/EBtTrIQtv5zZitNs6xXPHerixENdaqRQ1pHW+fYJhkomy8yqjb3ODW9H1E38xyL uh6Q== X-Forwarded-Encrypted: i=1; AHgh+RrB6iA7bgVMsgBfWcSwz71YAdVUzRBPyqr4MoXRdKN5zf9dcvDInH3NBbQ8rX6FBPKw43R4MQBKNe1TXLc=@vger.kernel.org X-Gm-Message-State: AFuF++k7Z8HOIFqCJioMJp5NNcdpcnfJVKE3zCV+fO8bM9sc/fU+wDjZ A3Sl5UrYlN1rqApM+1nihk7IigabmKszSP1QudDrTv5KpnfzeTo3MO1r X-Gm-Gg: AR+sD11ko0zKrFSPr1jD2ziuBOO92pKGE8XBTj6wKzNQpEE6Y4cHN2BBIzauy9jdwFa lwpU+33HWovVQayoQsM59G21W1WWvJ0hzO48w34wwipjME8/5PzvA6QEVDJXKGbnHQ1r1zS4yqz keI1qlG5Bxqm7CJmDn8zzcW6PgrQ7XCUg4bKIW0yxK4MDJ51BlkYT3V3lWf2rRNPMYvJ08MqKt2 mrq+AXvydo8QlVOmQfiBVkpd6ARGZ6KSsR5FlXXdfGDLfgmwRr/tn0wzf6lA5lQs6bLtbeXlkr8 VRMRi1kGWkIWCJA8wU7mYiIvOccVD6YwtmZUT8vXMG5odhROzHzUa6TUdLfQDwnJEEFxr6/rAuV bFeZTPCMK77jY2YKIy9J6UrlN7FvF7GkacY6N/OEDaNjfmPIUWN2CNBBfBfnCCnudTpQJ2RFJGV XnbdjRwpFlJFg9ej7EJIwzoe8b6BeWNvp9WUkcIJHJeYJIU1vStSkV+e5JMKYHJMGTsJD0g4Cwp 5zZIg9AMjQ= X-Received: by 2002:a17:902:ce08:b0:2cc:9179:32e with SMTP id d9443c01a7336-2d64afe9569mr119484575ad.10.1787315854187; Fri, 21 Aug 2026 05:37:34 -0700 (PDT) Received: from inhnjlux1020.ls.ege.ds ([2401:4900:7fb9:38e6:333a:f3ce:ece1:4458]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2d62d588035sm18057615ad.23.2026.08.21.05.37.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 21 Aug 2026 05:37:33 -0700 (PDT) From: Udaya Kiran Challa To: lee@kernel.org, pavel@kernel.org, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org Cc: skhan@linuxfoundation.org, me@brighamcampbell.com, linux-leds@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Udaya Kiran Challa Subject: [PATCH v2] dt-bindings: leds: lacie,netxbig-leds: Convert to DT schema Date: Fri, 21 Aug 2026 18:07:23 +0530 Message-Id: <20260821123723.198286-1-challauday369@gmail.com> X-Mailer: git-send-email 2.34.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Convert lacie,netxbig-leds devicetree binding from legacy text format to DT schema. Signed-off-by: Udaya Kiran Challa --- Changelog: Changes since v1: - Use pattenProperties for LED child nodes instead of additionalProperties - Explicitly list the two optional properties supported by the binding - Place the top-level required block after child-node definition Link to v1:https://lore.kernel.org/all/20260820150223.108374-1-challauday369@gmail.com/ --- .../bindings/leds/lacie,netxbig-leds.yaml | 144 ++++++++++++++++++ .../devicetree/bindings/leds/leds-netxbig.txt | 92 ----------- 2 files changed, 144 insertions(+), 92 deletions(-) create mode 100644 Documentation/devicetree/bindings/leds/lacie,netxbig-leds.yaml delete mode 100644 Documentation/devicetree/bindings/leds/leds-netxbig.txt diff --git a/Documentation/devicetree/bindings/leds/lacie,netxbig-leds.yaml b/Documentation/devicetree/bindings/leds/lacie,netxbig-leds.yaml new file mode 100644 index 000000000000..02759ecb32d0 --- /dev/null +++ b/Documentation/devicetree/bindings/leds/lacie,netxbig-leds.yaml @@ -0,0 +1,144 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/leds/lacie,netxbig-leds.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: LaCie/Seagate netxbig CPLD LEDs + +maintainers: + - Simon Guinot + +description: | + Binding for the CPLD LEDs (GPIO extension bus) found on some LaCie/Seagate + boards (Example: 2Big/5Big Network v2, 2Big NAS). + +properties: + compatible: + const: lacie,netxbig-leds + + gpio-ext: + description: Phandle for the gpio-ext bus. + $ref: /schemas/types.yaml#/definitions/phandle + + timers: + description: | + Timer array. Each timer entry is represented by three integers: + Mode (gpio-ext bus), delay_on and delay_off. + $ref: /schemas/types.yaml#/definitions/uint32-array + +patternProperties: + "^(?!gpio-ext$|pinctrl-[0-9]+$)[a-z][a-z0-9]*(-[a-z0-9]+)+$": + type: object + additionalProperties: false + + properties: + label: + description: | + Name for this LED. If omitted, the label is taken from the node name. + $ref: /schemas/types.yaml#/definitions/string + + mode-addr: + description: Mode register address on gpio-ext bus. + $ref: /schemas/types.yaml#/definitions/uint32 + + mode-val: + description: | + Mode to value mapping. Each entry is represented by two integers: + a mode and the corresponding value on the gpio-ext bus. + $ref: /schemas/types.yaml#/definitions/uint32-array + + bright-addr: + description: Brightness register address on gpio-ext bus. + $ref: /schemas/types.yaml#/definitions/uint32 + + max-brightness: + description: Maximum brightness value. + $ref: /schemas/types.yaml#/definitions/uint32 + + linux,default-trigger: + description: Trigger assigned to the LED. + $ref: /schemas/types.yaml#/definitions/string + + required: + - mode-addr + - mode-val + - bright-addr + - max-brightness + +required: + - compatible + - gpio-ext + +additionalProperties: false + +examples: + - | + #include + + netxbig-leds { + compatible = "lacie,netxbig-leds"; + + gpio-ext = <&netxbig_gpio_ext>; + + timers = ; + + blue-power { + label = "netxbig:blue:power"; + mode-addr = <0>; + mode-val = ; + bright-addr = <1>; + max-brightness = <7>; + }; + red-power { + label = "netxbig:red:power"; + mode-addr = <0>; + mode-val = ; + bright-addr = <1>; + max-brightness = <7>; + }; + blue-sata0 { + label = "netxbig:blue:sata0"; + mode-addr = <3>; + mode-val = ; + bright-addr = <2>; + max-brightness = <7>; + }; + red-sata0 { + label = "netxbig:red:sata0"; + mode-addr = <3>; + mode-val = ; + bright-addr = <2>; + max-brightness = <7>; + }; + blue-sata1 { + label = "netxbig:blue:sata1"; + mode-addr = <4>; + mode-val = ; + bright-addr = <2>; + max-brightness = <7>; + }; + red-sata1 { + label = "netxbig:red:sata1"; + mode-addr = <4>; + mode-val = ; + bright-addr = <2>; + max-brightness = <7>; + }; + }; diff --git a/Documentation/devicetree/bindings/leds/leds-netxbig.txt b/Documentation/devicetree/bindings/leds/leds-netxbig.txt deleted file mode 100644 index 5ef92a26d768..000000000000 --- a/Documentation/devicetree/bindings/leds/leds-netxbig.txt +++ /dev/null @@ -1,92 +0,0 @@ -Binding for the CPLD LEDs (GPIO extension bus) found on some LaCie/Seagate -boards (Example: 2Big/5Big Network v2, 2Big NAS). - -Required properties: -- compatible: "lacie,netxbig-leds". -- gpio-ext: Phandle for the gpio-ext bus. - -Optional properties: -- timers: Timer array. Each timer entry is represented by three integers: - Mode (gpio-ext bus), delay_on and delay_off. - -Each LED is represented as a sub-node of the netxbig-leds device. - -Required sub-node properties: -- mode-addr: Mode register address on gpio-ext bus. -- mode-val: Mode to value mapping. Each entry is represented by two integers: - A mode and the corresponding value on the gpio-ext bus. -- bright-addr: Brightness register address on gpio-ext bus. -- max-brightness: Maximum brightness value. - -Optional sub-node properties: -- label: Name for this LED. If omitted, the label is taken from the node name. -- linux,default-trigger: Trigger assigned to the LED. - -Example: - -netxbig-leds { - compatible = "lacie,netxbig-leds"; - - gpio-ext = &gpio_ext; - - timers = ; - - blue-power { - label = "netxbig:blue:power"; - mode-addr = <0>; - mode-val = ; - bright-addr = <1>; - max-brightness = <7>; - }; - red-power { - label = "netxbig:red:power"; - mode-addr = <0>; - mode-val = ; - bright-addr = <1>; - max-brightness = <7>; - }; - blue-sata0 { - label = "netxbig:blue:sata0"; - mode-addr = <3>; - mode-val = ; - bright-addr = <2>; - max-brightness = <7>; - }; - red-sata0 { - label = "netxbig:red:sata0"; - mode-addr = <3>; - mode-val = ; - bright-addr = <2>; - max-brightness = <7>; - }; - blue-sata1 { - label = "netxbig:blue:sata1"; - mode-addr = <4>; - mode-val = ; - bright-addr = <2>; - max-brightness = <7>; - }; - red-sata1 { - label = "netxbig:red:sata1"; - mode-addr = <4>; - mode-val = ; - bright-addr = <2>; - max-brightness = <7>; - }; -}; -- 2.34.1