Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp5548798pxb; Sun, 7 Nov 2021 14:58:05 -0800 (PST) X-Google-Smtp-Source: ABdhPJzm0DQqZRIFActnMgaow3wsrsvi4mV6ssFWF8HAZjDWYjVunV5nZrhxIIWRQ+rnV/6fxI9J X-Received: by 2002:a05:6e02:1bcc:: with SMTP id x12mr30228079ilv.106.1636325884849; Sun, 07 Nov 2021 14:58:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1636325884; cv=none; d=google.com; s=arc-20160816; b=yl4Z4SvyKxT9Zv+TEZ7xb+4nLWZ1nqg7gQgfjVGvatcQS6dJdYofExgmGdx36BCde7 TiETf/z391XEf9gPH05OwFIMuaNyHz8uu6jQllTbFJKoj245an+0lceWDbxqmJBGi70M x7P7GphhRt8riyENPXpupVyPhuWiWtUUOoGu6tT2cL0K110/VcZ/SK8QIyrhTWAe3az9 mFCTbxERzjzz92wi5F3rb1hL4/K06x5WoB051z57+AtJ+UvLOgR+22FOTaFk7+RCXcCZ USt8Nt5ULjnf2VKnARFxXZNckdPk0PB7tdqOUws4oV8FkcYYbrwJ2z3rimuIqqBcFQ+k s/tA== 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:to:from :dkim-signature; bh=BkNZKWlktxVlCgFfDkbpw/BG6V3cG3yF0hJ0Q8+ra5w=; b=LTSZwQoUNn++Ts0MP2fye/S4o2ERXMX6AbYHFZcFNIiptozNcX/3nKeMcills5eeDs oxewDh7NH4ciNc5DAShFM2kP5+Bzi0CoLID9fedciVMLLE2HpWDzHss1FNM0xZMsa2ZY I73vOlI+uljxsp6gwP+kn5GMczwGolt96y7/kT2bFhOPvQGNUIGeSvBk4fku7RtcAi1D CTAPVNpEsyyl5jtjxus1/Hxhi7SjB8Wt+lP6mVXU/m32huh+FUeWj/qVKC/VE4KfHm0m fbU3iZayAJdvGR5t5k1CVxSowtfogI5hQ7guXRIb/7SmoM6CtQWoSesBb4tzlkB9Jaqm sS9A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=VARy+XsE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f11si33726996ila.39.2021.11.07.14.57.52; Sun, 07 Nov 2021 14:58:04 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=VARy+XsE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236158AbhKGSBC (ORCPT + 99 others); Sun, 7 Nov 2021 13:01:02 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50340 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236069AbhKGSAq (ORCPT ); Sun, 7 Nov 2021 13:00:46 -0500 Received: from mail-ed1-x534.google.com (mail-ed1-x534.google.com [IPv6:2a00:1450:4864:20::534]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E7B41C061570; Sun, 7 Nov 2021 09:58:02 -0800 (PST) Received: by mail-ed1-x534.google.com with SMTP id z21so7974842edb.5; Sun, 07 Nov 2021 09:58:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=BkNZKWlktxVlCgFfDkbpw/BG6V3cG3yF0hJ0Q8+ra5w=; b=VARy+XsEOaU09CQ+dUfJX0Nxvo8LYXkBBHABv+5OzCONOY8Tb6wuqjXsXsQxohRBq/ cDkoUtpm1WMQ341PXo2WHAP8tKoNpJQd8UT+6DNWka42/O2O58/NKEPGj6Y65Uqvt5Ge 5a5Z6q0iVozPLqTQ3RlU87F+52Kiy5yGLhiEJR9JXJ/uc8xmnASpiJkebMeKgEZx5qof 6nmcQJTUez/YGKrZST3wASRAX/CDfuHfZKsRIZAjSAK1WOHdIZdjIMY8KaHp37IPdGaT YOyjNu957Fjq6sxqgYwa8iHhTpUVonCQ7nI/2QalBbDxN7kFxswBct7Bp3U9ziXI2ZuO PaQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=BkNZKWlktxVlCgFfDkbpw/BG6V3cG3yF0hJ0Q8+ra5w=; b=pA95ZgbLS+Rfbkb8rlAO57auJb+CV9YSu4n/HYs1ll5OU7qX7TOSzkz5yy461Z8Yaj whtUAAMNGQb2iy3tlsLI21I2d3JF8YKC8ewRu0gM5ow/Sg8NpNC7KdF15c0qJCmDjvFd QeiryUWV5adkj3uqndB2v7XVEzaBVub8aUd4TeqhqvSn+u5uIE3JdtSh0GSZOqpPfnzE XrgQmEnwO4iQU6wCxE/7N5zSnzTj4HcILt4E8HalagDBVPeobJv5GPvujiMXWq1gYoBr Qp7B4fHzdcZbVvQye4MtyqpexTpuIpsXcAsbRgHd+0UrVIkDehz3tR7VP2+Kd2Zk7cGr AMdA== X-Gm-Message-State: AOAM531m0GzsGVhCC2IS/oS9KUJyInn3mLyn2jV9J37Hz+c/tAfcbS7d NUC7mFKHaCPZrG98CH7TfPE= X-Received: by 2002:a17:907:ea5:: with SMTP id ho37mr67011769ejc.133.1636307881428; Sun, 07 Nov 2021 09:58:01 -0800 (PST) Received: from Ansuel-xps.localdomain (93-42-71-246.ip85.fastwebnet.it. [93.42.71.246]) by smtp.googlemail.com with ESMTPSA id m11sm4251182edd.58.2021.11.07.09.58.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 07 Nov 2021 09:58:01 -0800 (PST) From: Ansuel Smith To: Andrew Lunn , Vivien Didelot , Florian Fainelli , Vladimir Oltean , "David S. Miller" , Jakub Kicinski , Rob Herring , Jonathan Corbet , Pavel Machek , Ansuel Smith , John Crispin , netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-leds@vger.kernel.org Subject: [RFC PATCH 6/6] dt-bindings: net: dsa: qca8k: add LEDs definition example Date: Sun, 7 Nov 2021 18:57:18 +0100 Message-Id: <20211107175718.9151-7-ansuelsmth@gmail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211107175718.9151-1-ansuelsmth@gmail.com> References: <20211107175718.9151-1-ansuelsmth@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add LEDs definition example for qca8k using the offload trigger as the default trigger and add all the supported offload triggers by the switch. Signed-off-by: Ansuel Smith --- .../devicetree/bindings/net/dsa/qca8k.yaml | 30 +++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/Documentation/devicetree/bindings/net/dsa/qca8k.yaml b/Documentation/devicetree/bindings/net/dsa/qca8k.yaml index 48de0ace265d..d8394f625d03 100644 --- a/Documentation/devicetree/bindings/net/dsa/qca8k.yaml +++ b/Documentation/devicetree/bindings/net/dsa/qca8k.yaml @@ -64,6 +64,8 @@ properties: internal mdio access is used. With the legacy mapping the reg corresponding to the internal mdio is the switch reg with an offset of -1. + Each phy have at least 3 LEDs connected and can be declared + using the standard LEDs structure. properties: '#address-cells': @@ -340,6 +342,34 @@ examples: internal_phy_port1: ethernet-phy@0 { reg = <0>; + + leds { + led@0 { + reg = <0>; + color = ; + function = LED_FUNCTION_LAN; + function-enumerator = <1>; + linux,default-trigger = "offload-phy-activity"; + linux,supported-offload-triggers = "rx-blink", "tx-blink", "ollision-blink", + "link-10M", "link-100M", "link-1000M", + "half-duplex", "full-duplex", "linkup-over", + "power-on-reset", "blink-2hz", "blink-4hz", + "blink-8hz", "blink-auto"; + }; + + led@1 { + reg = <1>; + color = ; + function = LED_FUNCTION_LAN; + function-enumerator = <1>; + linux,default-trigger = "offload-phy-activity"; + linux,supported-offload-triggers = "rx-blink", "tx-blink", "ollision-blink", + "link-10M", "link-100M", "link-1000M", + "half-duplex", "full-duplex", "linkup-over", + "power-on-reset", "blink-2hz", "blink-4hz", + "blink-8hz", "blink-auto"; + }; + }; }; internal_phy_port2: ethernet-phy@1 { -- 2.32.0