]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
optee: add property no-map to secure reserved memory
authorEtienne Carriere <etienne.carriere@st.com>
Thu, 10 Sep 2020 08:50:01 +0000 (10:50 +0200)
committerSimon Glass <sjg@chromium.org>
Tue, 22 Sep 2020 18:54:13 +0000 (12:54 -0600)
OP-TEE reserved memory node must set property "no-map" to prevent
Linux kernel from mapping secure memory unless what non-secure world
speculative accesses of the CPU can violate the memory firmware
configuration.

Fixes: 6ccb05eae01b ("image: fdt: copy possible optee nodes to a loaded devicetree")
Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
Signed-off-by: Patrice Chotard <patrice.chotard@st.com>
lib/optee/optee.c

index 963c2ff4304eadee618486cb87a372f9a0c76b77..9e6606568f32860a7a37a6f22b39496883efe04e 100644 (file)
@@ -192,7 +192,7 @@ int optee_copy_fdt_nodes(const void *old_blob, void *new_blob)
                                ret = fdtdec_add_reserved_memory(new_blob,
                                                                 nodename,
                                                                 &carveout,
-                                                                NULL, false);
+                                                                NULL, true);
                                free(oldname);
 
                                if (ret < 0)