[SLOF] [PATCH v3 1/3] board_qemu: drop unused values early in fdt-fix-node-phandle

Greg Kurz groug at kaod.org
Fri Jul 14 16:54:27 AEST 2017


These two values are pushed on the stack by decode-int and stay unused
until the 2drop line. Let's drop them right away to make it obvious.

Signed-off-by: Greg Kurz <groug at kaod.org>
---
v3: - use "nip nip" instead of "-rot 2drop"
---
 board-qemu/slof/fdt.fs |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/board-qemu/slof/fdt.fs b/board-qemu/slof/fdt.fs
index 8d4635f30495..50beac85e451 100644
--- a/board-qemu/slof/fdt.fs
+++ b/board-qemu/slof/fdt.fs
@@ -314,11 +314,10 @@ fdt-claim-reserve
    >r
    FALSE TO (fdt-phandle-replaced)
    s" phandle" r@ get-property 0= IF
-      decode-int                       ( p-addr2 p-len2 val )
+      decode-int nip nip
       \ ." found phandle: " dup . cr
-      r@ s" /" find-node               ( p-addr2 p-len2 val node root )  
-      fdt-replace-all-phandles         ( p-addr2 p-len2 )
-      2drop
+      r@ s" /" find-node               ( val node root )
+      fdt-replace-all-phandles
       (fdt-phandle-replaced) IF
          r@ set-node
          s" phandle" delete-property



More information about the SLOF mailing list