I came across an outdated hello world tutorial for Migen which really confuses me.

In this tutorial, the author describes how CSRs (e.g. CSRStatus and CSRStorage) can be accessed from the host. In the example, CSRs are directly imported from Migen. Since CSRs are not longer available in Migen, I guess that Migen was split into Migen and MiSoC and that CSRs were moved to MiSoC.

What really puzzles me is that the author shows how CSRs can be accessed from the host. I first assumed that the host referred to SoC running on the FPGA but the example is written in Python:

@command('hello', ('v', int16))
def hello(dev, v):
    dev.regs.hello_input.wr(v)
    print("Hello returns %02x" % dev.regs.hello_output.rd())

Unless the SoC is running Linux, I think that the host machine refers to the machine connected to the FPGA. How is this possible? What interface does it use between the host and the FPGA?

The CSR system has been moved to MiSoC indeed.

CSRs are an abstraction that can be implemented in different ways - they can be memory-mapped in the address space of a CPU inside the same chip as the core using the CSRs, they can be memory-mapped using PCIe in a x86 CPU on PC hardware, or (as seems to be the case with OpenVizsla which I did not design) accessed using a custom protocol over USB.

6 days later

Thank you for the clarification. This is very much appreciated!