From patchwork Thu May 5 13:55:08 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: 12839596 X-Patchwork-Delegate: kuba@kernel.org 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C8A6BC3527A for ; Thu, 5 May 2022 13:55:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1380298AbiEEN7S (ORCPT ); Thu, 5 May 2022 09:59:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47714 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1380319AbiEEN7E (ORCPT ); Thu, 5 May 2022 09:59:04 -0400 Received: from mail-ej1-x62a.google.com (mail-ej1-x62a.google.com [IPv6:2a00:1450:4864:20::62a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7E0BB6255; Thu, 5 May 2022 06:55:23 -0700 (PDT) Received: by mail-ej1-x62a.google.com with SMTP id dk23so8893006ejb.8; Thu, 05 May 2022 06:55:23 -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=6jGlMaGnRuy7SzW1gLK1rbP4ej3ug9RnCTQFRGlHRyo=; b=UUjXmrWy0gc/YOU7UeZa/CBI2LHDiPBYI52bgE+CbxJBhcB5C29lQYCzJli3U7TlfI VSIZSLABxigpDo0RK/fTgnO11zb2Hxbg3dpSIYqdXFuy1HyLNlLCPsVM3/4p7ChNQraL ip5Kp/VrhE6bSHlbuvdOYCniW3gznAqfI6urKJ7S6u3wV93iQ+MRNtObs9iBk+/4eZcr eDjAKYbd3TbhgERHeDSzzliH5C2D9f5OE6DqXm7BTHHND2xq2F99vOTp4Rt9kIFtB3CY 3TZb+4+EbCQrFdFzj987cHw2xs19Y7zrWXG9LJwsL3+w5oTI5TWjGTNui7nbsnwk6MSk 713Q== 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=6jGlMaGnRuy7SzW1gLK1rbP4ej3ug9RnCTQFRGlHRyo=; b=ec/ANootBarMcCrn6AST1ddkdEtPC8hJfVW1Q1JLW19g9LTVy1DVx58hTWUjj6oML6 UeOi4OL/C60M4/QaQ5Wnyl7P1R2906Dl0MARLnzS5LHOasWsjCcAKrWGBLWoRhZ8vAXn cK+LnHHVVInNiQbY+hImvhkTYY5Pc7w9wFOPzIq7As49GIx6XGvFkvkTqdRwAUd7E1Lc qCDOnweV4YCDBJAFXkq+ZI3e18As0fmYomVe3sfh248Qam+xX29ygC2bq2Lv/ZgE/WoP r6kxdvJAHl/+KJf7ldSR8RDe/YnaLeQLK6kWyBcZ+b5xMZDaRSwDPXqOSUAIicn0+2e9 kZtw== X-Gm-Message-State: AOAM533QrMng/kxdCE9AH7tMlQL7+nXfLux/1gPnV3D/wnnSUfLxL2bX zYJqigA+G31vzstS1VvbWwY= X-Google-Smtp-Source: ABdhPJwRXqicutb+lLbMz0m+5wqMzInuLtPPN4SwqVojZi82lcp2HvixDpRomdqZLM07KxrlmZbQVw== X-Received: by 2002:a17:907:6e2a:b0:6f4:69bb:7ef6 with SMTP id sd42-20020a1709076e2a00b006f469bb7ef6mr17152406ejc.0.1651758922083; Thu, 05 May 2022 06:55:22 -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 e15-20020a50e44f000000b0042617ba63c7sm877949edm.81.2022.05.05.06.55.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 May 2022 06:55:21 -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, ansuelsmth@gmail.com, andrew@lunn.ch, vivien.didelot@gmail.com, Vladimir Oltean , Jonathan Corbet , John Crispin , linux-doc@vger.kernel.org, =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH RESEND 1/5] dt-bindings: net: add bitfield defines for Ethernet speeds Date: Thu, 5 May 2022 15:55:08 +0200 Message-Id: <20220505135512.3486-2-zajec5@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220505135512.3486-1-zajec5@gmail.com> References: <20220505135512.3486-1-zajec5@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Rafał Miłecki This allows specifying multiple Ethernet speeds in a single DT uint32 value. Signed-off-by: Rafał Miłecki --- include/dt-bindings/net/eth.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 include/dt-bindings/net/eth.h diff --git a/include/dt-bindings/net/eth.h b/include/dt-bindings/net/eth.h new file mode 100644 index 000000000000..89caff09179b --- /dev/null +++ b/include/dt-bindings/net/eth.h @@ -0,0 +1,27 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +/* + * Device Tree constants for the Ethernet + */ + +#ifndef _DT_BINDINGS_ETH_H +#define _DT_BINDINGS_ETH_H + +#define SPEED_UNSPEC 0 +#define SPEED_10 (1 << 0) +#define SPEED_100 (1 << 1) +#define SPEED_1000 (1 << 2) +#define SPEED_2000 (1 << 3) +#define SPEED_2500 (1 << 4) +#define SPEED_5000 (1 << 5) +#define SPEED_10000 (1 << 6) +#define SPEED_14000 (1 << 7) +#define SPEED_20000 (1 << 8) +#define SPEED_25000 (1 << 9) +#define SPEED_40000 (1 << 10) +#define SPEED_50000 (1 << 11) +#define SPEED_56000 (1 << 12) +#define SPEED_100000 (1 << 13) +#define SPEED_200000 (1 << 14) +#define SPEED_400000 (1 << 15) + +#endif From patchwork Thu May 5 13:55:09 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: 12839598 X-Patchwork-Delegate: kuba@kernel.org 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8F406C4332F for ; Thu, 5 May 2022 13:55:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345466AbiEEN7W (ORCPT ); Thu, 5 May 2022 09:59:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48222 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1380347AbiEEN7J (ORCPT ); Thu, 5 May 2022 09:59:09 -0400 Received: from mail-ej1-x62f.google.com (mail-ej1-x62f.google.com [IPv6:2a00:1450:4864:20::62f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B4A5F1834B; Thu, 5 May 2022 06:55:29 -0700 (PDT) Received: by mail-ej1-x62f.google.com with SMTP id i19so8873989eja.11; Thu, 05 May 2022 06:55:29 -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=ahkARIN+8V3yBAvDKNOhMu072AYtqbFU/lpjoQxJ3Ks=; b=gyhScaHs263fn2FMoFIaeIpmB1OR6lK4hIvTWKMnoqsCeTC4u7f5XlTXbu1qDGT80A 7fcgacj4FhqraB8kY6V759+NYx4cX2hkWcGvb32qC9sVoAGgT0c4dRd6y7e+IOJSFnNl PHH4QW2DAEqWANTXLaKCgcW6G7rVVLpcz1Y9yRu2BHdODLKSj7bnvTA+PdIgmneIxKQn oC0YfGZpHfaQqXIvYNm6WzICki7T1sEtt3tFgVSroKZ0jNV5NchrvnoWG+0aocWXlN2T BarZsb5ZxvXwki1O9/qbU1o/HM708vc56H6LtIseoYFnr1ECso98W2oRXzZ4Y6JD/N+5 dK2g== 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=ahkARIN+8V3yBAvDKNOhMu072AYtqbFU/lpjoQxJ3Ks=; b=D4u2Bx7nQGaPPfrDj3pV00Lmfdiw/k60rB5PoCdnO62pcg9svUDiMyxJO5KZCHoziD kXTcAf0PuHML6/rerD111Bls12pBQEKXC14WCH+nswz4PtiwMrKXwEAHESV03Oe1oncC 1JbxO7aVcqoGM0uQLFtHYqU0fqKzPHHEqDvsixxwzmXIsLAimxBbe+1UycAzlxxXTH3W N58PCQQCUM4fOcokmNsoqL6d/ES3tnc+XiHp2ahG5d67nFPG97NzDtpkXtxBuwEnjjZC W5NdspzxS/ccCYLmpUtedlNoF8UiZwx+S2cMW13ztJrynCUtLZEeSES+0l6EMrAgfOtb W3Ng== X-Gm-Message-State: AOAM530qkHmiNA+u5cJAL+qMkR0iJ+fele4w1jWwkh8va5ml/G+StHDh IJ6zVwMCtErq0SCwjfJKiq8= X-Google-Smtp-Source: ABdhPJzi3vKiAPWHMT0W9f/YUPiDcbp8oCkahrkdy1du7Mdl6X0NgMbhUvQRlzLOh3T78kfW8HG0HA== X-Received: by 2002:a17:906:2646:b0:6d5:d889:c92b with SMTP id i6-20020a170906264600b006d5d889c92bmr27143703ejc.696.1651758928315; Thu, 05 May 2022 06:55:28 -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 e15-20020a50e44f000000b0042617ba63c7sm877949edm.81.2022.05.05.06.55.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 May 2022 06:55:27 -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, ansuelsmth@gmail.com, andrew@lunn.ch, vivien.didelot@gmail.com, Vladimir Oltean , Jonathan Corbet , John Crispin , linux-doc@vger.kernel.org, =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH RESEND 2/5] dt-bindings: net: allow Ethernet devices as LED triggers Date: Thu, 5 May 2022 15:55:09 +0200 Message-Id: <20220505135512.3486-3-zajec5@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220505135512.3486-1-zajec5@gmail.com> References: <20220505135512.3486-1-zajec5@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.org From: Rafał Miłecki This allows specifying Ethernet interfaces and switch ports as triggers for LEDs activity. Signed-off-by: Rafał Miłecki --- Documentation/devicetree/bindings/net/ethernet-controller.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Documentation/devicetree/bindings/net/ethernet-controller.yaml b/Documentation/devicetree/bindings/net/ethernet-controller.yaml index 4f15463611f8..ebeb4446d253 100644 --- a/Documentation/devicetree/bindings/net/ethernet-controller.yaml +++ b/Documentation/devicetree/bindings/net/ethernet-controller.yaml @@ -232,6 +232,9 @@ properties: required: - speed +allOf: + - $ref: /schemas/leds/trigger-source.yaml + additionalProperties: true ... From patchwork Thu May 5 13:55:10 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: 12839597 X-Patchwork-Delegate: kuba@kernel.org 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A4F08C433EF for ; Thu, 5 May 2022 13:55:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1380179AbiEEN7U (ORCPT ); Thu, 5 May 2022 09:59:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48480 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1380360AbiEEN7L (ORCPT ); Thu, 5 May 2022 09:59:11 -0400 Received: from mail-ed1-x52d.google.com (mail-ed1-x52d.google.com [IPv6:2a00:1450:4864:20::52d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 345631834B; Thu, 5 May 2022 06:55:32 -0700 (PDT) Received: by mail-ed1-x52d.google.com with SMTP id b24so5291411edu.10; Thu, 05 May 2022 06:55:32 -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=W/5UaXxDAqcyJs7vU252H7GvKSWg0c/fiI5EtvVqQfvbbPoDgxZeoXXz2Bgk//+mch 8qTUnwBd0j2CIEhPg/aS4YTarFuuVfBGllA8yzs84ycZDVCyOTpXIptNc42tOPCz4bJ5 G4qBDcunfd4lFqKQXpcXd1p7ZPDRbz1YTdnhFD3UVZsw0EdVd6t6mOQkTvUbFeuyyhi+ KBPyzJUQv7RpdP7/H9jVZW+yKVEZfCeDO9cmF157c2iIt02b+3+CtN86kfjCVVC1+ZVw LS+UMchVLfARzZsy9nsMQoagGcQ5TlLJ6F9G12/UQkZ3H9uRyUhbgGQJpWvM+/y93GgN l/Ag== 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=b/l3ej1DiCFCdYFM7rr6P/R1+zRtYRGMNX3mjOEBDaexQFs2ImN8Yin+6MTcLhpjEw lDvEfJznOKkUL+m3vjNO5PO3BIX/2f33gXwLP2G8iWDNpETvirK1CVj/R/pMWWaszA5i GvmoM/BpySOq82BmFd7u74tivPmsR9HMZHJRaypo91EpiRaoNOiSI6xWIu4KqVMWl4FV UaErHHnkVYH+Qox6Lar3p6hZS+Pq8Q7zn1i2H690mXmiv5evYWv9xBTxD7ZJTWYHTc21 9kv973BXyzAYknaPb91XCnbdB9WCNgyIKwtRLO/+kR43BromnrnKHrbqrsjKCSbb+AA4 LbyQ== X-Gm-Message-State: AOAM530L+tXXK6sCg7nWzyXLgi2vuAruYKZ8c3pJwIoWR9huMtlhBDxN RFSSe47qzZHk/uKtyo1rxOc= X-Google-Smtp-Source: ABdhPJzTLEuqMS0XXlAUBVlv48aIfbTihrqnsUKYIVW/6h2dIhYSa6hS2trVlUxvL1OW4mGnO/lzDw== X-Received: by 2002:a05:6402:f25:b0:427:bf59:ad72 with SMTP id i37-20020a0564020f2500b00427bf59ad72mr23149749eda.231.1651758930769; Thu, 05 May 2022 06:55:30 -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 e15-20020a50e44f000000b0042617ba63c7sm877949edm.81.2022.05.05.06.55.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 May 2022 06:55:30 -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, ansuelsmth@gmail.com, andrew@lunn.ch, vivien.didelot@gmail.com, Vladimir Oltean , Jonathan Corbet , John Crispin , linux-doc@vger.kernel.org, =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH RESEND 3/5] dt-bindings: leds: add Ethernet triggered LEDs to example Date: Thu, 5 May 2022 15:55:10 +0200 Message-Id: <20220505135512.3486-4-zajec5@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220505135512.3486-1-zajec5@gmail.com> References: <20220505135512.3486-1-zajec5@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org X-Patchwork-Delegate: kuba@kernel.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>; + }; }; - | From patchwork Thu May 5 13:55:11 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: 12839599 X-Patchwork-Delegate: kuba@kernel.org 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6D39CC433EF for ; Thu, 5 May 2022 13:55:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232613AbiEEN70 (ORCPT ); Thu, 5 May 2022 09:59:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48866 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1351058AbiEEN7Q (ORCPT ); Thu, 5 May 2022 09:59:16 -0400 Received: from mail-ed1-x536.google.com (mail-ed1-x536.google.com [IPv6:2a00:1450:4864:20::536]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 339A51834B; Thu, 5 May 2022 06:55:35 -0700 (PDT) Received: by mail-ed1-x536.google.com with SMTP id be20so5275643edb.12; Thu, 05 May 2022 06:55:35 -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=HxnwmUt5XXOQZLtedBMlDA6s9oP05DqI/7RXSR5ri4c=; b=f74uBA86yjxvRibJ5/m+mK0DKh+ITswdWnRayKUptZ68YBTe6giJ2U/Lff31CW9f2n 9xGhm2wejuObPDBrG/3iASSUq9QfrBEHo9CHcJOx+LtXaAk3kBaC8NYeHavBp9JJPJW3 4/jU+k7P7Nv51sG3CBKYgFLbUSE8DJyl8s3/o7mtfgrioAjbcaESnqnMPYUzvVVgwt99 I2JWRpZiaWk/V5OWWuYafMakfSJUZBXNhnJ/0ExZAUI+CKp7mWEh7WdkidS8L9exbXd0 TkBYmGpCOIIezWpQPkCXVDhGeP9ylbzvBrrpUNYBUv6B4SIsypPPL2nb5wfM+F1LFumY aD/w== 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=HxnwmUt5XXOQZLtedBMlDA6s9oP05DqI/7RXSR5ri4c=; b=cPtLxMJgCQ7e59Qy1y0MRo7O1zTWbmp+i1uCjFLZCnUcw+5XH6R7sXBbBqVMBd4PaV Uemc2aWgooB6Ktn4ZMuuEqeO8gESiG6gaIBaJBWQeOOTYnJvfdx7L8G1IyrdTul1G2W6 mUvJTDJ2L+dqS0wbjuLk5Is7Zw4N22GFldbA5QUOlEwB0CFhnFIeNo3QVtmErSJJD5XJ M8eXJPHpoOzG+ZvXYeK/tgoAnarD1GXeAlIm6Z4jFBG6ekm879rinbcFZjBJlOm4FiWR lJIIC2pK5tPa+4A2I+5a4MMDboDCYQqhxY2nDXw44YjoUPkaSbB8O3BivmPxtdM59VcF Ss7w== X-Gm-Message-State: AOAM533nCwuK4vIAa78mFBrPuyuvaegwFHzcylNT04B+mg5MXNJMDDCz WOfkkLDlVwmnSK8mRnVeu6c= X-Google-Smtp-Source: ABdhPJzKQ4doBuTShpt/bqmUap9zPNLxvV2r0btNGW4wF9eKsbrNNiPReGQVLou27wEe566MwrMcEg== X-Received: by 2002:a05:6402:26d3:b0:427:c571:86fe with SMTP id x19-20020a05640226d300b00427c57186femr22415605edd.133.1651758933825; Thu, 05 May 2022 06:55:33 -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 e15-20020a50e44f000000b0042617ba63c7sm877949edm.81.2022.05.05.06.55.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 May 2022 06:55:33 -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, ansuelsmth@gmail.com, andrew@lunn.ch, vivien.didelot@gmail.com, Vladimir Oltean , Jonathan Corbet , John Crispin , linux-doc@vger.kernel.org, =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH RESEND 4/5] ARM: dts: BCM5301X: Add triggers for Luxul XWR-1200 network LEDs Date: Thu, 5 May 2022 15:55:11 +0200 Message-Id: <20220505135512.3486-5-zajec5@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220505135512.3486-1-zajec5@gmail.com> References: <20220505135512.3486-1-zajec5@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Rafał Miłecki Those LEDs are not hardware controlled so bootloader / operating system may want to control them manually depending on switch ports state. Signed-off-by: Rafał Miłecki --- arch/arm/boot/dts/bcm47081-luxul-xwr-1200.dts | 22 ++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/arch/arm/boot/dts/bcm47081-luxul-xwr-1200.dts b/arch/arm/boot/dts/bcm47081-luxul-xwr-1200.dts index 9316a36434f7..ee1b0fd3eb86 100644 --- a/arch/arm/boot/dts/bcm47081-luxul-xwr-1200.dts +++ b/arch/arm/boot/dts/bcm47081-luxul-xwr-1200.dts @@ -5,6 +5,8 @@ /dts-v1/; +#include + #include "bcm47081.dtsi" #include "bcm5301x-nand-cs0-bch4.dtsi" @@ -38,24 +40,28 @@ power { lan3 { label = "bcm53xx:green:lan3"; gpios = <&chipcommon 1 GPIO_ACTIVE_LOW>; + trigger-sources = <&port_lan3 SPEED_UNSPEC>; linux,default-trigger = "none"; }; lan4 { label = "bcm53xx:green:lan4"; gpios = <&chipcommon 2 GPIO_ACTIVE_LOW>; + trigger-sources = <&port_lan4 SPEED_UNSPEC>; linux,default-trigger = "none"; }; wan { label = "bcm53xx:green:wan"; gpios = <&chipcommon 3 GPIO_ACTIVE_LOW>; + trigger-sources = <&port_wan SPEED_UNSPEC>; linux,default-trigger = "none"; }; lan2 { label = "bcm53xx:green:lan2"; gpios = <&chipcommon 6 GPIO_ACTIVE_LOW>; + trigger-sources = <&port_lan2 SPEED_UNSPEC>; linux,default-trigger = "none"; }; @@ -87,6 +93,7 @@ status { lan1 { label = "bcm53xx:green:lan1"; gpios = <&chipcommon 15 GPIO_ACTIVE_LOW>; + trigger-sources = <&port_lan1 SPEED_UNSPEC>; linux,default-trigger = "none"; }; }; @@ -114,29 +121,34 @@ &srab { status = "okay"; ports { - port@0 { + port_lan4: port@0 { reg = <0>; label = "lan4"; + #trigger-source-cells = <1>; }; - port@1 { + port_lan3: port@1 { reg = <1>; label = "lan3"; + #trigger-source-cells = <1>; }; - port@2 { + port_lan2: port@2 { reg = <2>; label = "lan2"; + #trigger-source-cells = <1>; }; - port@3 { + port_lan1: port@3 { reg = <3>; label = "lan1"; + #trigger-source-cells = <1>; }; - port@4 { + port_wan: port@4 { reg = <4>; label = "wan"; + #trigger-source-cells = <1>; }; port@5 {