[dv] reggen fixes
- fixed field reset value to be set in hex instead if decimal
- fixed chip reg block to sort blocks and windows by base addr so that new updates
show up as incremental change (fix for #153)
diff --git a/util/topgen.py b/util/topgen.py
index 64b38dd..b83d394 100755
--- a/util/topgen.py
+++ b/util/topgen.py
@@ -185,6 +185,10 @@
if block.name == module["name"]:
block.base_addr = module["base_addr"]
break
+
+ top_block.blocks.sort(key=lambda block: block.base_addr)
+ top_block.wins.sort(key=lambda win: win.base_addr)
+
# generate the top ral model with template
gen_dv.gen_ral(top_block, str(out_path))