Perform some basic canonicalization:
- enum entries are sorted by value
- register type fields are sorted by starting bit
- - __register_mappings is sorted by name
+ - __register_mappings is sorted by offset
- the chips field of register mappings is sorted
Lazily computes the set of all chips mentioned by register mappings.
self.__regmap_by_addr = defaultdict(list)
self.__chips = set()
- # Merge regiseter mappings using sort order and garbage collect enums
+ # Merge register mappings using sort order and garbage collect enums
# and register types.
old_register_mappings = self.__register_mappings
- old_register_mappings.sort(key=lambda regmap: regmap.name)
+ old_register_mappings.sort(key=lambda regmap: regmap.map.at)
self.__register_mappings = []
for regmap in old_register_mappings: