From ecab89737a4eb58c043388b1ca1c0f1dfdaa3346 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Fri, 6 Jul 2018 10:27:40 -0600 Subject: binman: Add a ProcessFdt() method Some entry types modify the device tree, e.g. to remove microcode or add a property. So far this just modifies their local copy and does not affect a 'shared' device tree. Rather than doing this modification in the ObtainContents() method, and a new ProcessFdt() method which is specifically designed to modify this shared device tree. Move the existing device-tree code over to use this method, reducing ObtainContents() to the goal of just obtaining the contents without any processing, even for device tree. Signed-off-by: Simon Glass --- tools/binman/image.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'tools/binman/image.py') diff --git a/tools/binman/image.py b/tools/binman/image.py index 835b66c99f..9732493709 100644 --- a/tools/binman/image.py +++ b/tools/binman/image.py @@ -54,6 +54,9 @@ class Image: self._filename = filename self._section = bsection.Section('main-section', self._node) + def ProcessFdt(self, fdt): + return self._section.ProcessFdt(fdt) + def GetEntryContents(self): """Call ObtainContents() for the section """ -- cgit