]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
arm64: dts: imx8m: Reinstate TEE ifdeffery
authorMarek Vasut <marex@nabladev.com>
Tue, 30 Jun 2026 16:08:56 +0000 (18:08 +0200)
committerFabio Estevam <festevam@gmail.com>
Mon, 27 Jul 2026 14:28:57 +0000 (11:28 -0300)
Since b57ed147939c ("dts: imx8m{m,n,p,q}: Make optee packaging optional")
the TEE node is always present in U-Boot proper fitImage, even if the
CONFIG_OPTEE is disabled because the u-boot.itb should not contain any
tee.bin. This is wasteful, and produces the following warning which is
also confusing to users:

"
Image 'image' is missing optional external blobs but is still functional: tee-os

/binman/section/fit/images/tee/tee-os (tee.bin):
   See the documentation for your board. You may need to build Open Portable
   Trusted Execution Environment (OP-TEE) and build with TEE=/path/to/tee.bin
"

Reinstate the CONFIG_OPTEE ifdeffery to mitigate the problem, but retain the
binman "optional" keyword at tee.bin .

Before:
"
$ mkimage -l u-boot.itb
FIT description: Configuration to load ATF before U-Boot
Created:         Tue Jun 30 17:23:54 2026
 Image 0 (uboot)
...
 Image 2 (tee) <------------------------------ bogus empty image entry
  Description:  OP-TEE                                 |
  Created:      Tue Jun 30 17:23:54 2026               |
  Type:         Trusted Execution Environment Image    |
  Compression:  uncompressed                           |
  Data Size:    0 Bytes = 0.00 KiB = 0.00 MiB <--------'
 Image 3 (fdt-1)
...
"

After:
"
$ mkimage -l u-boot.itb
FIT description: Configuration to load ATF before U-Boot
Created:         Tue Jun 30 17:58:15 2026
 Image 0 (uboot)
...
 Image 1 (atf)
...
 Image 2 (fdt-1)
...
"

Fixes: b57ed147939c ("dts: imx8m{m,n,p,q}: Make optee packaging optional")
Signed-off-by: Marek Vasut <marex@nabladev.com>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
arch/arm/dts/imx8mm-u-boot.dtsi
arch/arm/dts/imx8mn-u-boot.dtsi
arch/arm/dts/imx8mp-u-boot.dtsi
arch/arm/dts/imx8mq-u-boot.dtsi

index 50ecb6cad398825ef70a37157938bcfcb11a22d9..c3d9b4f42378bda95be8a1d8c32fc3f96aeb7151 100644 (file)
                                        };
 #endif
 
+#ifdef CONFIG_OPTEE
                                        tee: tee {
                                                description = "OP-TEE";
                                                type = "tee";
                                                        optional;
                                                };
                                        };
+#endif
 
                                        binman_fip: fip {
                                                arch = "arm64";
                                                fdt = "fdt-SEQ";
                                                firmware = "uboot";
 #ifndef CONFIG_ARMV8_PSCI
+#ifdef CONFIG_OPTEE
                                                loadables = "atf", "tee";
+#else
+                                               loadables = "atf";
+#endif
 #endif
                                        };
                                };
index 690f56e65bbc4d20b3a3c36f497e768bb300374a..f9cbfd03f99cf9d03e354a5ae7ce2eba3b2ac6d4 100644 (file)
                                        };
 #endif
 
+#ifdef CONFIG_OPTEE
                                        tee: tee {
                                                description = "OP-TEE";
                                                type = "tee";
                                                        optional;
                                                };
                                        };
+#endif
 
                                        binman_fip: fip {
                                                arch = "arm64";
                                                fdt = "fdt-SEQ";
                                                firmware = "uboot";
 #ifndef CONFIG_ARMV8_PSCI
+#ifdef CONFIG_OPTEE
                                                loadables = "atf", "tee";
+#else
+                                               loadables = "atf";
+#endif
 #endif
                                        };
                                };
index d9d220c70db600a7be1d021a0c4e8927a2f2b17f..58b6863f003e2605f26aa9cd5dd65f9a94408045 100644 (file)
                                        };
 #endif
 
+#ifdef CONFIG_OPTEE
                                        tee: tee {
                                                description = "OP-TEE";
                                                type = "tee";
                                                        optional;
                                                };
                                        };
+#endif
 
                                        @fdt-SEQ {
                                                description = "NAME";
                                                fdt = "fdt-SEQ";
                                                firmware = "uboot";
 #ifndef CONFIG_ARMV8_PSCI
+#ifdef CONFIG_OPTEE
                                                loadables = "atf", "tee";
+#else
+                                               loadables = "atf";
+#endif
 #endif
                                        };
                                };
index b4deaa92160baf203b8c22cc8d98fbebb38c934f..c694740175066d1cb331c2dffc67362034bc203f 100644 (file)
                                };
 #endif
 
+#ifdef CONFIG_OPTEE
                                tee: tee {
                                        description = "OP-TEE";
                                        type = "tee";
                                                optional;
                                        };
                                };
+#endif
 
                                fdt {
                                        compression = "none";
                                        fdt = "fdt";
                                        firmware = "uboot";
 #ifndef CONFIG_ARMV8_PSCI
+#ifdef CONFIG_OPTEE
                                        loadables = "atf", "tee";
+#else
+                                       loadables = "atf";
+#endif
 #endif
                                };
                        };