PolarFire SoC based board working

From: Milan Obuch <freebsd-riscv_at_dino.sk>
Date: Sat, 26 Feb 2022 22:44:04 UTC
Hi,

at https://dmesgd.nycbug.org/index.cgi?do=view&id=6455 is uploaded
dmesg from system build using (almost) stock FreeBSD sources. This
system uses PolarFire SoC combining RISC V cores with FPGA from
Microchip. I use SoM and carrier board from Conclusive Engineering
(www.conclusive.pl).

Notes:

- dmesg uploaded uses network driver (cgem) as kernel module. As there
  is SGMII between MAC (in SoC) and PHY, if_cgem.c needs a bit of
  patching. Another patch is needed for building miibus.ko (preliminary
  review at https://reviews.freebsd.org/D34256).

- only one UART is shown here, however there are five in total. With
  simple tweak in FDT, all are working.

- with some more patches, GPIO does work as well, verified partially
  (some hardware design in FPGA is probably necessary for full
  verification, not done yet).

- another device requiring patches is SD/MMC driver. It works only in
  read only mode presently, I did not find the reason, yet. In dmesg
  given at URL above, memdisk is used for root filesystem.

- manual intervention is required at the moment when loader starts,
  selecting safe mode.

- when 'random: randomdev_wait_until_seeded unblock wait' lines started
  appearing, I used ctrl-C to unblock wait manually. I have probably
  patch dealing with this issue, test needed.

PolarFire SoC is used for Icicle board as well, it would be good to
know if some FreeBSD developer has this board...

Regards,
Milan