From: chaochao2021666@163.com
To: davem@davemloft.net, kuba@kernel.org, robh+dt@kernel.org
Cc: netdev@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, Chao Zeng <chao.zeng@siemens.com>
Subject: [PATCH 1/2] dt-bindings:dp83867:Add binding for the status led
Date: Mon, 9 Aug 2021 16:52:13 +0800 [thread overview]
Message-ID: <20210809085213.324129-1-chaochao2021666@163.com> (raw)
From: Chao Zeng <chao.zeng@siemens.com>
The phy status led of each of board maybe different.
Provide a method to custom phy status led behavior.
Datasheet:
http://www.ti.com/product/DP83867IR/datasheet
Signed-off-by: Chao Zeng <chao.zeng@siemens.com>
---
.../devicetree/bindings/net/ti,dp83867.yaml | 6 ++++++
include/dt-bindings/net/ti-dp83867.h | 18 ++++++++++++++++++
2 files changed, 24 insertions(+)
diff --git a/Documentation/devicetree/bindings/net/ti,dp83867.yaml b/Documentation/devicetree/bindings/net/ti,dp83867.yaml
index 047d757e8d82..a46a437818f2 100644
--- a/Documentation/devicetree/bindings/net/ti,dp83867.yaml
+++ b/Documentation/devicetree/bindings/net/ti,dp83867.yaml
@@ -106,6 +106,12 @@ properties:
Transmitt FIFO depth- see dt-bindings/net/ti-dp83867.h for applicable
values.
+ ti,led-sel:
+ $ref: /schemas/types.yaml#/definitions/uint32
+ description: |
+ This configure the status led. See dt-bindings/net/ti-dp83867.h
+ for different status led settings,select different configures
+
required:
- reg
diff --git a/include/dt-bindings/net/ti-dp83867.h b/include/dt-bindings/net/ti-dp83867.h
index 6fc4b445d3a1..de59c3a42c1e 100644
--- a/include/dt-bindings/net/ti-dp83867.h
+++ b/include/dt-bindings/net/ti-dp83867.h
@@ -48,6 +48,24 @@
#define DP83867_CLK_O_SEL_CHN_C_TCLK 0xA
#define DP83867_CLK_O_SEL_CHN_D_TCLK 0xB
#define DP83867_CLK_O_SEL_REF_CLK 0xC
+
+/* Led configuration flag*/
+#define DP83867_LINK_ESTABLISHED 0x0
+#define DP83867_RECEIVE_TRANSMIT_ACTIVITY 0x1
+#define DP83867_TRANSMIT_ACTIVITY 0x2
+#define DP83867_RECEIVE_ACTIVITY 0x3
+#define DP83867_COLLISION_DETECTED 0x4
+#define DP83867_LINK_ESTABLISHED_1000BT 0x5
+#define DP83867_LINK_ESTABLISHED_100BTX 0x6
+#define DP83867_LINK_ESTABLISHED_10BT 0x7
+#define DP83867_LINK_ESTABLISHED_10_100_BT 0x8
+#define DP83867_LINK_ESTABLISHED_100_1000_BT 0x9
+#define DP83867_FULL_DUPLEX 0xA
+#define DP83867_LINK_ESTABLISHED_BLINK_TRANSMIT_RECEIVE 0xB
+#define DP83867_RESERVED 0xC
+#define DP83867_RECEIVE_TRANSMIT_ERROR 0xD
+#define DP83867_RECEIVE_ERROR 0xE
+
/* Special flag to indicate clock should be off */
#define DP83867_CLK_O_SEL_OFF 0xFFFFFFFF
#endif
--
2.32.0
next reply other threads:[~2021-08-09 8:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-09 8:52 chaochao2021666 [this message]
2021-08-17 18:48 ` [PATCH 1/2] dt-bindings:dp83867:Add binding for the status led Rob Herring
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210809085213.324129-1-chaochao2021666@163.com \
--to=chaochao2021666@163.com \
--cc=chao.zeng@siemens.com \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=robh+dt@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.