util: Fixed gem5img.py script (#990)
Made the script more robust to different names. Co-authored-by: Hossam ElAtali <hossam.elatali@uwaterloo.ca>
This commit is contained in:
@@ -194,7 +194,8 @@ def findPartOffset(devFile, fileName, partition):
|
||||
r"\s*:\s*" # Separator
|
||||
r"start=\s*(?P<start>\d+),\s*" # Partition start record
|
||||
r"size=\s*(?P<size>\d+),\s*" # Partition size record
|
||||
r"type=(?P<type>\d+)" # Partition type record
|
||||
r"type=(?P<type>.+?),*?" # Partition type record
|
||||
r".*" # anything else, e.g., name field
|
||||
r"\s*$" # End of line
|
||||
)
|
||||
lines = out.splitlines()
|
||||
|
||||
Reference in New Issue
Block a user