]> git.ipfire.org Git - people/ms/u-boot.git/commitdiff
fdt: Drop fdt_select.py
authorSimon Glass <sjg@chromium.org>
Sat, 27 May 2017 13:38:30 +0000 (07:38 -0600)
committerSimon Glass <sjg@chromium.org>
Fri, 2 Jun 2017 16:18:20 +0000 (10:18 -0600)
This file was used to select between the normal and fallback libfdt
implementations. Now that we only have one, it is not needed.

Drop it and fix up all users.

Signed-off-by: Simon Glass <sjg@chromium.org>
tools/binman/control.py
tools/binman/etype/u_boot_dtb_with_ucode.py
tools/binman/fdt_test.py
tools/binman/func_test.py
tools/dtoc/dtoc.py
tools/dtoc/fdt.py
tools/dtoc/fdt_select.py [deleted file]

index 42d75efbcdaa3e3bbbc1503af312ea5eaee81303..e9d48df03014cde346fd9175c5d32fb8b6d75e9a 100644 (file)
@@ -12,7 +12,7 @@ import sys
 import tools
 
 import command
-import fdt_select
+import fdt
 import fdt_util
 from image import Image
 import tout
index 01ee36fb0d957548c3606e6ffda477998ac41511..a384a759c4c73755c49f489ea2076ca796adb529 100644 (file)
@@ -6,7 +6,7 @@
 # Entry-type module for U-Boot device tree with the microcode removed
 #
 
-import fdt_select
+import fdt
 from entry import Entry
 from blob import Entry_blob
 import tools
index df2b0a6af75c4802e82ff87bfca77bd1f7124177..249a9ea388ed50c2d73d97a2857ec90d772858cf 100644 (file)
@@ -12,7 +12,7 @@ import tempfile
 import unittest
 
 import fdt
-from fdt_select import FdtScan
+from fdt import FdtScan
 import fdt_util
 import tools
 
index 8960e23f2cc72cb81ec29a46b8ce7e7bec5da86c..8b4db4165970ab5f114729124335a54907a1b44f 100644 (file)
@@ -21,7 +21,7 @@ import cmdline
 import command
 import control
 import entry
-import fdt_select
+import fdt
 import fdt_util
 import tools
 import tout
index 2e0b9c04e209e2b9b5297886c66152445b34b676..08e35f148c0d9828b4e3118d230c57abe498676d 100755 (executable)
@@ -17,7 +17,6 @@ our_path = os.path.dirname(os.path.realpath(__file__))
 sys.path.append(os.path.join(our_path, '../patman'))
 
 import fdt
-import fdt_select
 import fdt_util
 
 # When we see these properties we ignore them - i.e. do not create a structure member
@@ -170,7 +169,7 @@ class DtbPlatdata:
         Once this is done, self.fdt.GetRoot() can be called to obtain the
         device tree root node, and progress from there.
         """
-        self.fdt = fdt_select.FdtScan(self._dtb_fname)
+        self.fdt = fdt.FdtScan(self._dtb_fname)
 
     def ScanNode(self, root):
         for node in root.subnodes:
index bff31d1c921eceb8f3a255d263e57b778c9b9f93..63a32ea2d7bfcaeb9897406a986ff8dc65ac61c5 100644 (file)
@@ -14,8 +14,8 @@ import libfdt
 
 # This deals with a device tree, presenting it as an assortment of Node and
 # Prop objects, representing nodes and properties, respectively. This file
-# contains the base classes and defines the high-level API. See fdt_select.py
-# for how to create an Fdt object.
+# contains the base classes and defines the high-level API. You can use
+# FdtScan() as a convenience function to create and scan an Fdt.
 
 # This implementation uses a libfdt Python library to access the device tree,
 # so it is fairly efficient.
@@ -400,3 +400,9 @@ class Fdt:
         """
         node = Node(fdt, offset, name, path)
         return node
+
+def FdtScan(fname):
+    """Returns a new Fdt object from the implementation we are using"""
+    dtb = Fdt(fname)
+    dtb.Scan()
+    return dtb
diff --git a/tools/dtoc/fdt_select.py b/tools/dtoc/fdt_select.py
deleted file mode 100644 (file)
index d6337ea..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright (C) 2016 Google, Inc
-# Written by Simon Glass <sjg@chromium.org>
-#
-# SPDX-License-Identifier:      GPL-2.0+
-#
-
-# Bring in the normal fdt library (which relies on libfdt)
-import fdt
-
-def FdtScan(fname):
-    """Returns a new Fdt object from the implementation we are using"""
-    dtb = fdt.Fdt(fname)
-    dtb.Scan()
-    return dtb