* [PATCH 1/2] ARM: mxs: Add serial: Search for specific ocotp nodes
@ 2023-10-09 17:37 Fabio Estevam
2023-10-09 17:37 ` [PATCH 2/2] ARM: dts: mxs: Remove fsl,ocotp Fabio Estevam
2023-10-10 2:44 ` [PATCH 1/2] ARM: mxs: Add serial: Search for specific ocotp nodes Shawn Guo
0 siblings, 2 replies; 3+ messages in thread
From: Fabio Estevam @ 2023-10-09 17:37 UTC (permalink / raw)
To: shawnguo; +Cc: linux-arm-kernel, Fabio Estevam
From: Fabio Estevam <festevam@denx.de>
Per mxs-ocotp.yaml, "fsl,ocotp" is not a valid entry.
"fsl,ocotp" is only used to indicate the location of the
struct device_node that points to the ocotp node.
Search for the specific "fsl,imx28-ocotp" and "fsl,imx23-ocotp"
instead and remove the undocumented "fsl,ocotp" fallback.
Signed-off-by: Fabio Estevam <festevam@denx.de>
---
arch/arm/mach-mxs/mach-mxs.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-mxs/mach-mxs.c b/arch/arm/mach-mxs/mach-mxs.c
index 3faf9a1e3e36..d16e638990da 100644
--- a/arch/arm/mach-mxs/mach-mxs.c
+++ b/arch/arm/mach-mxs/mach-mxs.c
@@ -94,7 +94,9 @@ static const u32 *mxs_get_ocotp(void)
if (once)
return ocotp_words;
- np = of_find_compatible_node(NULL, NULL, "fsl,ocotp");
+ np = of_find_compatible_node(NULL, NULL, "fsl,imx28-ocotp");
+ if (!np)
+ np = of_find_compatible_node(NULL, NULL, "fsl,imx23-ocotp");
ocotp_base = of_iomap(np, 0);
WARN_ON(!ocotp_base);
--
2.34.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2] ARM: dts: mxs: Remove fsl,ocotp
2023-10-09 17:37 [PATCH 1/2] ARM: mxs: Add serial: Search for specific ocotp nodes Fabio Estevam
@ 2023-10-09 17:37 ` Fabio Estevam
2023-10-10 2:44 ` [PATCH 1/2] ARM: mxs: Add serial: Search for specific ocotp nodes Shawn Guo
1 sibling, 0 replies; 3+ messages in thread
From: Fabio Estevam @ 2023-10-09 17:37 UTC (permalink / raw)
To: shawnguo; +Cc: linux-arm-kernel, Fabio Estevam
From: Fabio Estevam <festevam@denx.de>
Per mxs-ocotp.yaml, "fsl,ocotp" is not a valid entry.
Remove it to fix the following schema warning:
efuse@8002c000: compatible: ['fsl,imx23-ocotp', 'fsl,ocotp'] is too long
from schema $id: http://devicetree.org/schemas/nvmem/mxs-ocotp.yaml#
Signed-off-by: Fabio Estevam <festevam@denx.de>
---
arch/arm/boot/dts/nxp/mxs/imx23.dtsi | 2 +-
arch/arm/boot/dts/nxp/mxs/imx28.dtsi | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/arm/boot/dts/nxp/mxs/imx23.dtsi b/arch/arm/boot/dts/nxp/mxs/imx23.dtsi
index f98ee2e42431..40bea0ae7a59 100644
--- a/arch/arm/boot/dts/nxp/mxs/imx23.dtsi
+++ b/arch/arm/boot/dts/nxp/mxs/imx23.dtsi
@@ -437,7 +437,7 @@ pxp@8002a000 {
};
efuse@8002c000 {
- compatible = "fsl,imx23-ocotp", "fsl,ocotp";
+ compatible = "fsl,imx23-ocotp";
#address-cells = <1>;
#size-cells = <1>;
reg = <0x8002c000 0x2000>;
diff --git a/arch/arm/boot/dts/nxp/mxs/imx28.dtsi b/arch/arm/boot/dts/nxp/mxs/imx28.dtsi
index 37b9d409a5cd..92d940b63b4f 100644
--- a/arch/arm/boot/dts/nxp/mxs/imx28.dtsi
+++ b/arch/arm/boot/dts/nxp/mxs/imx28.dtsi
@@ -1016,7 +1016,7 @@ pxp: pxp@8002a000 {
};
ocotp: efuse@8002c000 {
- compatible = "fsl,imx28-ocotp", "fsl,ocotp";
+ compatible = "fsl,imx28-ocotp";
#address-cells = <1>;
#size-cells = <1>;
reg = <0x8002c000 0x2000>;
--
2.34.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/2] ARM: mxs: Add serial: Search for specific ocotp nodes
2023-10-09 17:37 [PATCH 1/2] ARM: mxs: Add serial: Search for specific ocotp nodes Fabio Estevam
2023-10-09 17:37 ` [PATCH 2/2] ARM: dts: mxs: Remove fsl,ocotp Fabio Estevam
@ 2023-10-10 2:44 ` Shawn Guo
1 sibling, 0 replies; 3+ messages in thread
From: Shawn Guo @ 2023-10-10 2:44 UTC (permalink / raw)
To: Fabio Estevam; +Cc: linux-arm-kernel, Fabio Estevam
On Mon, Oct 09, 2023 at 02:37:39PM -0300, Fabio Estevam wrote:
> From: Fabio Estevam <festevam@denx.de>
>
> Per mxs-ocotp.yaml, "fsl,ocotp" is not a valid entry.
>
> "fsl,ocotp" is only used to indicate the location of the
> struct device_node that points to the ocotp node.
>
> Search for the specific "fsl,imx28-ocotp" and "fsl,imx23-ocotp"
> instead and remove the undocumented "fsl,ocotp" fallback.
Since the compatible is being used, can we document it instead?
Shawn
>
> Signed-off-by: Fabio Estevam <festevam@denx.de>
> ---
> arch/arm/mach-mxs/mach-mxs.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm/mach-mxs/mach-mxs.c b/arch/arm/mach-mxs/mach-mxs.c
> index 3faf9a1e3e36..d16e638990da 100644
> --- a/arch/arm/mach-mxs/mach-mxs.c
> +++ b/arch/arm/mach-mxs/mach-mxs.c
> @@ -94,7 +94,9 @@ static const u32 *mxs_get_ocotp(void)
> if (once)
> return ocotp_words;
>
> - np = of_find_compatible_node(NULL, NULL, "fsl,ocotp");
> + np = of_find_compatible_node(NULL, NULL, "fsl,imx28-ocotp");
> + if (!np)
> + np = of_find_compatible_node(NULL, NULL, "fsl,imx23-ocotp");
> ocotp_base = of_iomap(np, 0);
> WARN_ON(!ocotp_base);
>
> --
> 2.34.1
>
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-10-10 2:44 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-09 17:37 [PATCH 1/2] ARM: mxs: Add serial: Search for specific ocotp nodes Fabio Estevam
2023-10-09 17:37 ` [PATCH 2/2] ARM: dts: mxs: Remove fsl,ocotp Fabio Estevam
2023-10-10 2:44 ` [PATCH 1/2] ARM: mxs: Add serial: Search for specific ocotp nodes Shawn Guo
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).