* [PATCH v2 1/1] dt-bindings: i3c: add header for generic I3C flags
@ 2024-07-15 22:53 Frank Li
2024-07-16 6:17 ` Krzysztof Kozlowski
2024-07-23 23:51 ` Alexandre Belloni
0 siblings, 2 replies; 3+ messages in thread
From: Frank Li @ 2024-07-15 22:53 UTC (permalink / raw)
To: krzk
Cc: Frank.Li, alexandre.belloni, conor+dt, devicetree, imx, krzk+dt,
linux-i3c, linux-kernel, miquel.raynal, robh
From: Carlos Song <carlos.song@nxp.com>
Add header file for generic I3C flags to avoid hard code in dts file.
Signed-off-by: Carlos Song <carlos.song@nxp.com>
Reviewed-by: Frank Li <frank.li@nxp.com>
Acked-by: Jason Liu <jason.hui.liu@nxp.com>
Signed-off-by: Frank Li <Frank.Li@nxp.com>
---
Change from v1 to v2
- use full path for include header
- s/MIT/BSD-2-Clause/
---
Documentation/devicetree/bindings/i3c/i3c.yaml | 5 ++++-
MAINTAINERS | 1 +
include/dt-bindings/i3c/i3c.h | 16 ++++++++++++++++
3 files changed, 21 insertions(+), 1 deletion(-)
create mode 100644 include/dt-bindings/i3c/i3c.h
diff --git a/Documentation/devicetree/bindings/i3c/i3c.yaml b/Documentation/devicetree/bindings/i3c/i3c.yaml
index 113957ebe9f1d..e25fa72fd7857 100644
--- a/Documentation/devicetree/bindings/i3c/i3c.yaml
+++ b/Documentation/devicetree/bindings/i3c/i3c.yaml
@@ -91,6 +91,7 @@ patternProperties:
- const: 0
- description: |
Shall encode the I3C LVR (Legacy Virtual Register):
+ See include/dt-bindings/i3c/i3c.h
bit[31:8]: unused/ignored
bit[7:5]: I2C device index. Possible values:
* 0: I2C device has a 50 ns spike filter
@@ -153,6 +154,8 @@ additionalProperties: true
examples:
- |
+ #include <dt-bindings/i3c/i3c.h>
+
i3c@d040000 {
compatible = "cdns,i3c-master";
clocks = <&coreclock>, <&i3csysclock>;
@@ -166,7 +169,7 @@ examples:
/* I2C device. */
eeprom@57 {
compatible = "atmel,24c01";
- reg = <0x57 0x0 0x10>;
+ reg = <0x57 0x0 (I2C_FM | I2C_FILTER)>;
pagesize = <0x8>;
};
diff --git a/MAINTAINERS b/MAINTAINERS
index 3c4fdf74a3f9d..f0ce22e04d467 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -10479,6 +10479,7 @@ F: Documentation/ABI/testing/sysfs-bus-i3c
F: Documentation/devicetree/bindings/i3c/
F: Documentation/driver-api/i3c
F: drivers/i3c/
+F: include/dt-bindings/i3c/
F: include/linux/i3c/
IBM Operation Panel Input Driver
diff --git a/include/dt-bindings/i3c/i3c.h b/include/dt-bindings/i3c/i3c.h
new file mode 100644
index 0000000000000..373439218bba6
--- /dev/null
+++ b/include/dt-bindings/i3c/i3c.h
@@ -0,0 +1,16 @@
+/* SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause */
+/*
+ * Copyright 2024 NXP
+ */
+
+#ifndef _DT_BINDINGS_I3C_I3C_H
+#define _DT_BINDINGS_I3C_I3C_H
+
+#define I2C_FM (1 << 4)
+#define I2C_FM_PLUS (0 << 4)
+
+#define I2C_FILTER (0 << 5)
+#define I2C_NO_FILTER_HIGH_FREQUENCY (1 << 5)
+#define I2C_NO_FILTER_LOW_FREQUENCY (2 << 5)
+
+#endif
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH v2 1/1] dt-bindings: i3c: add header for generic I3C flags
2024-07-15 22:53 [PATCH v2 1/1] dt-bindings: i3c: add header for generic I3C flags Frank Li
@ 2024-07-16 6:17 ` Krzysztof Kozlowski
2024-07-23 23:51 ` Alexandre Belloni
1 sibling, 0 replies; 3+ messages in thread
From: Krzysztof Kozlowski @ 2024-07-16 6:17 UTC (permalink / raw)
To: Frank Li
Cc: alexandre.belloni, conor+dt, devicetree, imx, krzk+dt, linux-i3c,
linux-kernel, miquel.raynal, robh
On 16/07/2024 00:53, Frank Li wrote:
> From: Carlos Song <carlos.song@nxp.com>
>
> Add header file for generic I3C flags to avoid hard code in dts file.
>
> Signed-off-by: Carlos Song <carlos.song@nxp.com>
> Reviewed-by: Frank Li <frank.li@nxp.com>
> Acked-by: Jason Liu <jason.hui.liu@nxp.com>
> Signed-off-by: Frank Li <Frank.Li@nxp.com>
> ---
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v2 1/1] dt-bindings: i3c: add header for generic I3C flags
2024-07-15 22:53 [PATCH v2 1/1] dt-bindings: i3c: add header for generic I3C flags Frank Li
2024-07-16 6:17 ` Krzysztof Kozlowski
@ 2024-07-23 23:51 ` Alexandre Belloni
1 sibling, 0 replies; 3+ messages in thread
From: Alexandre Belloni @ 2024-07-23 23:51 UTC (permalink / raw)
To: krzk, Frank Li
Cc: conor+dt, devicetree, imx, krzk+dt, linux-i3c, linux-kernel,
miquel.raynal, robh
On Mon, 15 Jul 2024 18:53:51 -0400, Frank Li wrote:
> Add header file for generic I3C flags to avoid hard code in dts file.
>
>
Applied, thanks!
[1/1] dt-bindings: i3c: add header for generic I3C flags
https://git.kernel.org/abelloni/c/3564d9eb607d
Best regards,
--
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-07-23 23:51 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-15 22:53 [PATCH v2 1/1] dt-bindings: i3c: add header for generic I3C flags Frank Li
2024-07-16 6:17 ` Krzysztof Kozlowski
2024-07-23 23:51 ` Alexandre Belloni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).