summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorLeonard Crestez <leonard.crestez@nxp.com>2019-02-27 21:51:26 +0200
committerYe Li <ye.li@nxp.com>2020-04-26 23:24:13 -0700
commit545d9288b79b8e609b777728c8a46d0f72694c48 (patch)
tree6fdb5be9fb70d8434bff3fe76e768b3a294452d2 /arch
parent6fc09fa61ac0c198931bd88184717e304903e1e2 (diff)
MLK-20958-2 imx8: Replace SC_R_LAST with SC_R_NONE in DTB
We are currently using SC_R_LAST as a marker for imx8 power domain tree nodes without a resource attached. This value is compiled into dtb as part of the linux build and used by uboot. The SC_R_LAST constant changes frequently as SCFW resources are added (by design) and every time we need to update linux and uboot headers together or boot can fail. Fix this by replacing SC_R_LAST usage with a new constant SC_R_NONE defined to be 0xFFF0. Signed-off-by: Leonard Crestez <leonard.crestez@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 93f302a6642adedfdd6336b22d08f32284539e35) (cherry picked from commit be563f60e44757afe4ef2b89d2f043b6aa2a1573)
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/dts/fsl-imx8dx.dtsi16
-rw-r--r--arch/arm/dts/fsl-imx8qm-device.dtsi18
-rw-r--r--arch/arm/mach-imx/imx8/cpu.c8
3 files changed, 21 insertions, 21 deletions
diff --git a/arch/arm/dts/fsl-imx8dx.dtsi b/arch/arm/dts/fsl-imx8dx.dtsi
index 6958a0e16f..a8571a12b5 100644
--- a/arch/arm/dts/fsl-imx8dx.dtsi
+++ b/arch/arm/dts/fsl-imx8dx.dtsi
@@ -243,7 +243,7 @@
pd_lsio: PD_LSIO {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -382,7 +382,7 @@
pd_conn: PD_CONN {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -490,7 +490,7 @@
pd_audio: PD_AUDIO {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -863,7 +863,7 @@
pd_dma: PD_DMA {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -1046,7 +1046,7 @@
pd_gpu: gpu-power-domain {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -1099,7 +1099,7 @@
pd_hsio: hsio-power-domain {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -1129,7 +1129,7 @@
pd_cm40: PD_CM40 {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -1386,7 +1386,7 @@
};
pd_caam: PD_CAAM {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
diff --git a/arch/arm/dts/fsl-imx8qm-device.dtsi b/arch/arm/dts/fsl-imx8qm-device.dtsi
index 33ac27306c..3d8cf711b1 100644
--- a/arch/arm/dts/fsl-imx8qm-device.dtsi
+++ b/arch/arm/dts/fsl-imx8qm-device.dtsi
@@ -184,7 +184,7 @@
pd_lsio: PD_LSIO {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -333,7 +333,7 @@
pd_conn: PD_CONN {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -440,7 +440,7 @@
pd_hsio: PD_HSIO {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -494,7 +494,7 @@
pd_audio: PD_AUDIO {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -945,7 +945,7 @@
pd_dma: PD_DMA {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -1192,7 +1192,7 @@
};
pd_gpu: PD_GPU {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -1410,7 +1410,7 @@
pd_cm40: PD_CM40 {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -1430,7 +1430,7 @@
pd_cm41: PD_CM41 {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
@@ -1453,7 +1453,7 @@
pd_caam: PD_CAAM {
compatible = "nxp,imx8-pd";
- reg = <SC_R_LAST>;
+ reg = <SC_R_NONE>;
#power-domain-cells = <0>;
#address-cells = <1>;
#size-cells = <0>;
diff --git a/arch/arm/mach-imx/imx8/cpu.c b/arch/arm/mach-imx/imx8/cpu.c
index d16efe601b..f695db3299 100644
--- a/arch/arm/mach-imx/imx8/cpu.c
+++ b/arch/arm/mach-imx/imx8/cpu.c
@@ -904,8 +904,8 @@ bool check_owned_udevice(struct udevice *dev)
}
/* Get the owner partition for resource*/
- resource_id = (sc_rsrc_t)ofnode_read_u32_default(args.node, "reg", SC_R_LAST);
- if (resource_id == SC_R_LAST) {
+ resource_id = (sc_rsrc_t)ofnode_read_u32_default(args.node, "reg", SC_R_NONE);
+ if (resource_id == SC_R_NONE) {
printf("Can't find the resource id for udev %s\n", dev->name);
return false;
}
@@ -967,8 +967,8 @@ struct udevice * board_imx_vservice_find_mu(struct udevice *dev)
}
/* Get the owner partition for resource*/
- resource_id = (sc_rsrc_t)ofnode_read_u32_default(args.node, "reg", SC_R_LAST);
- if (resource_id == SC_R_LAST) {
+ resource_id = (sc_rsrc_t)ofnode_read_u32_default(args.node, "reg", SC_R_NONE);
+ if (resource_id == SC_R_NONE) {
printf("Can't find the resource id for udev %s\n", dev->name);
return NULL;
}