Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
interconnect/wishbone: increase WB address width to 31
This is needed to support memory regions up to 4GB in size (currently limited to 2GB, or 0x8000_0000). FIXME: CI complains about assertions re. axi_lite.address_width in relationship to len(wishbone.adr) and wishbone_adr_shift, which seems to be a problem on the 32bit (vexriscv?) CPU used for CI, but seems to work fine on Rocket. Signed-off-by: Gabriel Somlo <gsomlo@gmail.com> foo
- Loading branch information
70eae5c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This breaks all my simulations. The address bus is now 31 bits wide, but is being connected to a VexriscV cpu core with a 30-bit wide address. This makes the top bit a "Z" which is not decodable in a verilog simulation, and the simulation stops before even running the first instruction.
I would recommend doing this in a way where if you want a VexriscV that can go 4GiB memory, you set an argument in the init() parameters to specify that, and then pass the adr_width=31 field only when that is set. Otherwise you're going to break a lot of other people's infrastructure...
70eae5c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bunnie: thanks for the feedback, i'm going to look at this.
70eae5c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe if I revert this change, and try to somehow compute the adequate address width (based on the size of the region available to the caller of
addr_adapter
) here:https://github.com/enjoy-digital/litex/blob/master/litex/soc/integration/soc.py#L291
we can keep things from breaking? I'm going to try this, see if it's feasible.
Sorry about the breakage :(
70eae5c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for looking into it! Feel free to ditch my pull request once you have found a work-around.
70eae5c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for trying to fix it for us, the default
adr_width
has been reverted so it will fix things on your side and we'll find another way to get our use-case working without touching the defaultadr_width
.