Hi all,
thanks for the effort in this! just a few things:
@Mateusz: for additional CSR in LiteX UART, as Tim suggests the feature is already in SoCController:
https://github.com/enjoy-digital/litex/blob/master/litex/soc/integration/soc_core.py#L46-L49SoCControllerI think the features that are in the SoC to ease CPU/software support should be located in a single module
and we should avoid duplicating it in the different cores.
Also upstreaming things is very good, but we also have to be aware that we will loose some flexibility
we currently have with patches, so we really need to think now how we can facilitate the work in the
future with drivers already upstreamed:
- As @Mateusz says, it's easy to add CSR in LiteX and it works well when software is also build directly
with LiteX. But when drivers and OSes are involved and when software can't be recompiled, we loose
some flexibility. For now, it's possible to give fixed location to CSR regions, but it's not possible
to give fixed location for the CSR of a Module (this is determined automatically). I'm happy to work
with you on that @Mateusz since i also wanted to remove this limitation. Feel free to create an issue
or PR on LiteX so that we can work on that together.
- It can take some time and some iterations to find a good gateware/software architecture, so i think
we should only upstream things for which we already have a good feedback. I'm not aware of how much
work is needed to upstream patches to the kernel but i'd just like to avoid a situation where we have
new ideas to improve the gateware but just don't change things just because the drivers is already
upstreamed and it's too much work to change it. Having kernel developers involved in the process would
be very valuable.
- An argument against reactions like the ones we saw when posting the Linux-on-LiteX-Vexriscv results:
"why aren't you using the regular UART16550 drivers" and that we will probably have again, is that
here both gateware and software are flexible and we can take advantage of that to be simple/efficient
on both: Most of the cores were developed to be simple and minimal on the gateware side to take
advantage of the software, but if things needs to be changed on the gateware to assist the software,
simplify the driver or just be similar to others drivers, it's possible and things can be discussed.
@Joel: For the Arty, there are pre-built bitstreams in:
https://github.com/litex-hub/linux-on-litex-vexriscv-prebuiltYou should be able to just use the prebuilt FPGA bitstreams and kernel images. Then if you want
to work on the LiteEth driver, just re-compiling the kernel with buildroot should be enough, no need
to re-generate the gateware.
Florent