Skip to content

Commit

Permalink
Fix estimation logic of hw property on import
Browse files Browse the repository at this point in the history
  • Loading branch information
amykyta3 authored Aug 24, 2023
1 parent 1d9bd5a commit 154a562
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/peakrdl_ipxact/importer.py
Original file line number Diff line number Diff line change
Expand Up @@ -632,12 +632,7 @@ def parse_field(self, field: ElementTree.Element, reg_access: rdltypes.AccessTyp
volatile = d.get("volatile", False)
if sw_access == rdltypes.AccessType.r:
hw_access = rdltypes.AccessType.w
elif sw_access in (rdltypes.AccessType.w, rdltypes.AccessType.w1):
if volatile:
hw_access = rdltypes.AccessType.r
else:
hw_access = rdltypes.AccessType.rw
elif sw_access in (rdltypes.AccessType.rw, rdltypes.AccessType.rw1):
elif sw_access in (rdltypes.AccessType.w, rdltypes.AccessType.w1, rdltypes.AccessType.rw, rdltypes.AccessType.rw1):
if volatile:
hw_access = rdltypes.AccessType.rw
else:
Expand Down

0 comments on commit 154a562

Please sign in to comment.