From patchwork Tue May 3 15:36:12 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 12835940 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AC9F0C433F5 for ; Tue, 3 May 2022 15:37:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=9mLXpZTdFMA/E33wFpuTPGeW++89UZGjAdMAAQ3xii4=; b=bIDPzgyrvJOAHe F3zpbXYhB7CiGIicebmZ+Ij/4bJlN81ly3pT7nYz5/0EanLybsjHc4U2T9JV0/ccOcFGP+GVtHjta 55FAb8fhXdHglhQdcGgRruR1mB6RBKlJP19+DpR7BuuOStEyN2gnKIKhHXPJZz4F0z4Jy/YhNEASS jvxsQlS0nCd6Q6L4vKf2/RzaYE5ai0Zoc1pR4904q6esv2/tFpxn7YfNukeOzKsp9G3BxrEjnGguu mSaJJXt3S+BNy70dl55ZGT/VuiRgys6kVrgrzbp5FGjVJIjAAnJ/jV07kzCdTkFEjnJDS7KRA9EY6 O+vxGWWESovHqfkaKd9g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nlua1-006Wgj-GL; Tue, 03 May 2022 15:36:49 +0000 Received: from mail-ed1-x52b.google.com ([2a00:1450:4864:20::52b]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nluZm-006Wa9-5I for linux-arm-kernel@lists.infradead.org; Tue, 03 May 2022 15:36:35 +0000 Received: by mail-ed1-x52b.google.com with SMTP id d6so20288506ede.8 for ; Tue, 03 May 2022 08:36:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=JuRsVVqEUdtcZTaqe1dOvQJoNCUAzBZXwnxfkTQiX94=; b=BRArI0GcCu4Ce05SnXkZg0daGlzie5NRXUDkV1Lr192k5CWtnRR5IYBTZ9jCJF5NV5 oYINrBDN+xg5CrgkZ+ij7xmWHycrwyTAk6SD4Tr4p1P4mYGB3RzXah89Kmf1ONiML7+n fLl2gttPlv3Jqvs2t2WisdUJ31poWq+jw32Djz5QFVvXYHWsKWqJgyGlwoAzmWxUlMms 2yDRbN/36WlMwwNfD+w7bhoYspqkNmmPOETwNV98BNCXgYQKXCUwWcPV0zlacOCxNm9R 10lO5yJ0fe+cS3aKodyIdl2BZ9uuYNurdKoApObiHGVTG60alfNDMcwE7fD4J42RPuU6 zjMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=JuRsVVqEUdtcZTaqe1dOvQJoNCUAzBZXwnxfkTQiX94=; b=7Xttw+xN46y3K6I6LwAdggcx6Wvc+/7vZQKp9MjYAHfB1wiB3NiBEQ2YqqJG1eIZna y1LeFQ2hzHAXleK9FPNZ26Y/QWwidyfaEqYDFqZiI6/1ug6lr194dnFtlRGR+a4STVrk QPiZDZCJMCdaQhYrQp9+bSfLFG1udVuz3FH6gYaNNuaxxN/3UFq8bZJLP6I03YvzmxgK IzxJzdWs8XBaAlJMISxCGZV4TRuDhejM8ME2h1w/4iekwRm2gifE6a0tENKOFpXshncd +EFrKyTbBukoMOjgydEEBuaadgchnQKI+aD1jK94fTSKrWmMpeJhpvjNI+LT1y8tSIUT zoRQ== X-Gm-Message-State: AOAM531xVPmbPKKrZmYHvMko1U0qcro1Yb7NyLUA6Y85o+hUpZMuKCtZ C7L/Y/R4ipbyuFGtmAdLtz4= X-Google-Smtp-Source: ABdhPJy4DPM17zPyvjTpRiksTw2yQVmQVsw9kTtZhpCWfe2/iq1eq++c9Q4Ba/UweKwkOXNIsoCR6Q== X-Received: by 2002:a05:6402:35c3:b0:423:f765:4523 with SMTP id z3-20020a05640235c300b00423f7654523mr18336737edc.311.1651592192529; Tue, 03 May 2022 08:36:32 -0700 (PDT) Received: from localhost.lan (ip-194-187-74-233.konfederacka.maverick.com.pl. [194.187.74.233]) by smtp.gmail.com with ESMTPSA id yl1-20020a17090693e100b006f3ef214dd1sm4693395ejb.55.2022.05.03.08.36.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 May 2022 08:36:32 -0700 (PDT) From: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= To: Rob Herring , Krzysztof Kozlowski Cc: Pavel Machek , "David S . Miller" , Jakub Kicinski , Paolo Abeni , Florian Fainelli , Hauke Mehrtens , Jacek Anaszewski , devicetree@vger.kernel.org, netdev@vger.kernel.org, linux-leds@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, bcm-kernel-feedback-list@broadcom.com, =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH 3/4] dt-bindings: leds: add Ethernet triggered LEDs to example Date: Tue, 3 May 2022 17:36:12 +0200 Message-Id: <20220503153613.15320-3-zajec5@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220503153613.15320-1-zajec5@gmail.com> References: <20220503153613.15320-1-zajec5@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220503_083634_243863_87EFE3E9 X-CRM114-Status: GOOD ( 12.67 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Rafał Miłecki This adds 3 entries to existing example: 1. LED triggered by switch port in 10 / 100 Mbps link state 2. LED triggered by switch port in 1000 Mbps link 3. LED triggered by Ethernet interface (any speed) Signed-off-by: Rafał Miłecki --- .../devicetree/bindings/leds/common.yaml | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/Documentation/devicetree/bindings/leds/common.yaml b/Documentation/devicetree/bindings/leds/common.yaml index 328952d7acbb..6c72121a1656 100644 --- a/Documentation/devicetree/bindings/leds/common.yaml +++ b/Documentation/devicetree/bindings/leds/common.yaml @@ -168,6 +168,7 @@ examples: - | #include #include + #include led-controller { compatible = "gpio-leds"; @@ -183,6 +184,26 @@ examples: gpios = <&gpio0 1 GPIO_ACTIVE_HIGH>; trigger-sources = <&ohci_port1>, <&ehci_port1>; }; + + led-2 { + function = LED_FUNCTION_WAN; + color = ; + gpios = <&gpio0 2 GPIO_ACTIVE_LOW>; + trigger-sources = <&wan_port (SPEED_10 | SPEED_100)>; + }; + + led-3 { + function = LED_FUNCTION_WAN; + color = ; + gpios = <&gpio0 3 GPIO_ACTIVE_LOW>; + trigger-sources = <&wan_port SPEED_1000>; + }; + + led-4 { + function = LED_FUNCTION_LAN; + gpios = <&gpio0 4 GPIO_ACTIVE_LOW>; + trigger-sources = <&gmac 0>; + }; }; - |