m-labs / misoc

The original high performance and small footprint system-on-chip based on Migen™
https://m-labs.hk
Other
306 stars 85 forks source link

bios: added debug info about flashboot source #89

Closed danielkucera closed 5 years ago

sbourdeauducq commented 6 years ago

OK, but what do you need this for?

danielkucera commented 6 years ago

I was playing with gateware and modifying flash_boot_address but then I realized that the change is not propagated into bios because it was compiled few weeks ago and not recompiling after gateware change. So I added this to see where does bios try to load the firmware from to avoid similar problems and complicated debugging in the future.

sbourdeauducq commented 6 years ago

the change is not propagated into bios because it was compiled few weeks ago and not recompiling after gateware change.

Is that because you didn't reflash it, or because there is a problem with the build system?

danielkucera commented 6 years ago

I'm building the flash file on my own from top.bin and bios.bin and if I don't do rm build/software/bios/*, bios is not rebuilt automatically

sbourdeauducq commented 6 years ago

Then it is a problem with the build system? In that case it should be fixed instead. This problem can pop up in other (and worse) ways otherwise, e.g. if you change the addresses of the CSRs used by the BIOS for everything (UART etc.).

danielkucera commented 6 years ago

probably yes. I'm not denying there is another problem but I think this patch has it's added value and is worth accepting. If you don't agree I have no problem if you refuse it.

sbourdeauducq commented 6 years ago

It's generally better to go for the root cause of the problems than accumulate a pile of ad-hoc incomplete solutions.

danielkucera commented 6 years ago

for the main problem see issue #91

sbourdeauducq commented 5 years ago

OK, then let's fix #91.