mirror of
https://xff.cz/git/u-boot/
synced 2025-09-01 16:52:14 +02:00
binman: Allow listing the entries in an image
It is useful to be able to summarise all the entries in an image, e.g. to display this to this user. Add a new ListEntries() method to Entry, and set up a way to call it through the Image class. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -162,3 +162,13 @@ class Image:
|
||||
file=fd)
|
||||
self._section.WriteMap(fd, 0)
|
||||
return fname
|
||||
|
||||
def BuildEntryList(self):
|
||||
"""List the files in an image
|
||||
|
||||
Returns:
|
||||
List of entry.EntryInfo objects describing all entries in the image
|
||||
"""
|
||||
entries = []
|
||||
self._section.ListEntries(entries, 0)
|
||||
return entries
|
||||
|
Reference in New Issue
Block a user