mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-04-01 03:51:31 +00:00
binman: Add support for including spl/u-boot-spl-nodtb.bin
This file contains SPL image without a device tree. Add support for including this in images. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
47419eae4b
commit
4e6fdbef67
3 changed files with 33 additions and 0 deletions
17
tools/binman/etype/u_boot_spl_nodtb.py
Normal file
17
tools/binman/etype/u_boot_spl_nodtb.py
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
# Copyright (c) 2016 Google, Inc
|
||||||
|
# Written by Simon Glass <sjg@chromium.org>
|
||||||
|
#
|
||||||
|
# SPDX-License-Identifier: GPL-2.0+
|
||||||
|
#
|
||||||
|
# Entry-type module for 'u-boot-nodtb.bin'
|
||||||
|
#
|
||||||
|
|
||||||
|
from entry import Entry
|
||||||
|
from blob import Entry_blob
|
||||||
|
|
||||||
|
class Entry_u_boot_spl_nodtb(Entry_blob):
|
||||||
|
def __init__(self, image, etype, node):
|
||||||
|
Entry_blob.__init__(self, image, etype, node)
|
||||||
|
|
||||||
|
def GetDefaultFilename(self):
|
||||||
|
return 'spl/u-boot-spl-nodtb.bin'
|
|
@ -876,6 +876,11 @@ class TestFunctional(unittest.TestCase):
|
||||||
data = self._DoReadFile('51_u_boot_spl_dtb.dts')
|
data = self._DoReadFile('51_u_boot_spl_dtb.dts')
|
||||||
self.assertEqual(U_BOOT_SPL_DTB_DATA, data[:len(U_BOOT_SPL_DTB_DATA)])
|
self.assertEqual(U_BOOT_SPL_DTB_DATA, data[:len(U_BOOT_SPL_DTB_DATA)])
|
||||||
|
|
||||||
|
def testSplNoDtb(self):
|
||||||
|
"""Test that an image with spl/u-boot-spl-nodtb.bin can be created"""
|
||||||
|
data = self._DoReadFile('52_u_boot_spl_nodtb.dts')
|
||||||
|
self.assertEqual(U_BOOT_SPL_NODTB_DATA, data[:len(U_BOOT_SPL_NODTB_DATA)])
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
unittest.main()
|
unittest.main()
|
||||||
|
|
11
tools/binman/test/52_u_boot_spl_nodtb.dts
Normal file
11
tools/binman/test/52_u_boot_spl_nodtb.dts
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
/dts-v1/;
|
||||||
|
|
||||||
|
/ {
|
||||||
|
#address-cells = <1>;
|
||||||
|
#size-cells = <1>;
|
||||||
|
|
||||||
|
binman {
|
||||||
|
u-boot-spl-nodtb {
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
Loading…
Add table
Reference in a new issue