Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp1141462rwb; Fri, 7 Oct 2022 08:37:02 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5NXBcypbn1JfCmHTJ1vvFbTo6w+7W84ARX39+aXOtJYyhXL/diV6H6Th5K7VG0nPURyIXQ X-Received: by 2002:a17:90b:2751:b0:20a:e437:a9e8 with SMTP id qi17-20020a17090b275100b0020ae437a9e8mr16707551pjb.181.1665157021780; Fri, 07 Oct 2022 08:37:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665157021; cv=none; d=google.com; s=arc-20160816; b=UesdxVFMjw7ykGdiAxsBut9uD9EO7x0Kc7DBOvvvfyKF1fN9r9F31BQhUFFns48FC9 1sb+ZB2cIMyLykhahsz1os1DYSZX1hSvyiGACosk5zzxXudW8fL6FOyAYzRecezcWUJd MfAlMinMQIJGGzFGMSAXzfB6v9BRwDjvT9EVGmyij+gosY8cNthxhLfsBeWIcwsxzZRE WWvYlGyADl05kCYFzau/9gGNCrfby4g5lc7ZyuRd2/VYPcd8eGyFc8CB2T8cX2LSxi8o LcG9nLDYLHzHFWHevWoBHfFeOP2rgYLvab1Ax2uvr3e1fi37zNomtZEjlACLRguPmtqL 3Rbw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=/Ey+jWLzFOuhyp2YVJoMqpRDWRSBJ6wVscx7GRuCPHA=; b=ZJb2SqxlEtbEPJ0CqkzuvrZaFXPrloioCtsy9o7imh+8wY6os0pXYvfqlPZD58uDDz pUv/nVI9uFgTFdWvFReB6by1SvssGVOt9X4qhNmVfVaTQmS5NCdB3Inwuh3AX8NTlVeu 8SQCoi0VRvSdKcIqEWYQ2lz9bXkY3uwGWgb3D9RTlsoTgS0VH16viKSM52DzldPyixNV E2nb7boubUkOzqTZ+3/8GWvGHRK71U45ticYoldf8gHFdZaQHBm3/I4NZ7z6g5tsvfD0 /+rfrL/TLGilsHoe14/WO01e+W5nxu+cxpFV9/Volc6ZTDj2hdIpK4Lizy2LFnDdpCx7 dzkA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 137-20020a63048f000000b0043158b8ca77si3134523pge.123.2022.10.07.08.36.49; Fri, 07 Oct 2022 08:37:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229965AbiJGO5L (ORCPT + 99 others); Fri, 7 Oct 2022 10:57:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33816 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229902AbiJGO44 (ORCPT ); Fri, 7 Oct 2022 10:56:56 -0400 Received: from smtpout1.mo528.mail-out.ovh.net (smtpout1.mo528.mail-out.ovh.net [46.105.34.251]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A17C4AD9B8; Fri, 7 Oct 2022 07:56:54 -0700 (PDT) Received: from pro2.mail.ovh.net (unknown [10.109.146.13]) by mo528.mail-out.ovh.net (Postfix) with ESMTPS id 1BCB712E155D4; Fri, 7 Oct 2022 16:56:52 +0200 (CEST) Received: from localhost.localdomain (88.161.25.233) by DAG1EX1.emp2.local (172.16.2.1) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.12; Fri, 7 Oct 2022 16:56:50 +0200 From: Jean-Jacques Hiblot To: , , , , CC: , , , , , , , , Jean-Jacques Hiblot , Rob Herring Subject: [PATCH v4 5/6] dt-bindings: leds: Add binding for a multicolor group of LEDs Date: Fri, 7 Oct 2022 16:56:40 +0200 Message-ID: <20221007145641.3307075-6-jjhiblot@traphandler.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221007145641.3307075-1-jjhiblot@traphandler.com> References: <20221007145641.3307075-1-jjhiblot@traphandler.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [88.161.25.233] X-ClientProxiedBy: CAS1.emp2.local (172.16.1.1) To DAG1EX1.emp2.local (172.16.2.1) X-Ovh-Tracer-Id: 4482207533028358609 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: -100 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedvfedrfeeijedgkeefucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuqfggjfdpvefjgfevmfevgfenuceurghilhhouhhtmecuhedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhephffvvefufffkofgjfhgggfgtihesthekredtredttdenucfhrhhomheplfgvrghnqdflrggtqhhuvghsucfjihgslhhothcuoehjjhhhihgslhhothesthhrrghphhgrnhgulhgvrhdrtghomheqnecuggftrfgrthhtvghrnheptddtffevleejteelieejhfffvedtffeljeehjeeigfejledufedvveejuddtjefhnecuffhomhgrihhnpeguvghvihgtvghtrhgvvgdrohhrghenucfkpheptddrtddrtddrtddpkeekrdduiedurddvhedrvdeffeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhhouggvpehsmhhtphhouhhtpdhhvghlohepphhrohdvrdhmrghilhdrohhvhhdrnhgvthdpihhnvghtpedtrddtrddtrddtpdhmrghilhhfrhhomhepjhhjhhhisghlohhtsehtrhgrphhhrghnughlvghrrdgtohhmpdhnsggprhgtphhtthhopedupdhrtghpthhtoheprhhosghhsehkvghrnhgvlhdrohhrghdpoffvtefjohhsthepmhhohedvke X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This allows to group multiple monochromatic LEDs into a multicolor LED, e.g. RGB LEDs. Signed-off-by: Jean-Jacques Hiblot Reviewed-by: Rob Herring --- .../bindings/leds/leds-group-multicolor.yaml | 64 +++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 Documentation/devicetree/bindings/leds/leds-group-multicolor.yaml diff --git a/Documentation/devicetree/bindings/leds/leds-group-multicolor.yaml b/Documentation/devicetree/bindings/leds/leds-group-multicolor.yaml new file mode 100644 index 000000000000..8ed059a5a724 --- /dev/null +++ b/Documentation/devicetree/bindings/leds/leds-group-multicolor.yaml @@ -0,0 +1,64 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/leds/leds-group-multicolor.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Multi-color LED built with monochromatic LEDs + +maintainers: + - Jean-Jacques Hiblot + +description: | + This driver combines several monochromatic LEDs into one multi-color + LED using the multicolor LED class. + +properties: + compatible: + const: leds-group-multicolor + + leds: + description: + An aray of monochromatic leds + $ref: /schemas/types.yaml#/definitions/phandle-array + +required: + - leds + +allOf: + - $ref: leds-class-multicolor.yaml# + +unevaluatedProperties: false + +examples: + - | + #include + #include + + monochromatic-leds { + compatible = "gpio-leds"; + + led0: led-0 { + gpios = <&mcu_pio 0 GPIO_ACTIVE_LOW>; + color = ; + }; + + led1: led-1 { + gpios = <&mcu_pio 1 GPIO_ACTIVE_HIGH>; + color = ; + }; + + led2: led-2 { + gpios = <&mcu_pio 2 GPIO_ACTIVE_HIGH>; + color = ; + }; + }; + + multi-led { + compatible = "leds-group-multicolor"; + color = ; + function = LED_FUNCTION_INDICATOR; + leds = <&led0>, <&led1>, <&led2>; + }; + +... -- 2.25.1