[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Near-upstream kernel for VisionFive2



On 27-10-23, Hal Feng wrote:
> On Wed, 25 Oct 2023 at 12:29:06 +0200, Baptiste Jonglez <baptiste@bitsofnetworks.org> wrote:
> >
> > Hi,
> >
> > We're trying to build a system that is as close as possible to upstream
> > for the VisionFive2.  Here "upstream" means both Debian and Linux kernel.
> >
> > The current progress is here: https://framagit.org/compile-farm/debian-risc-v-build
> >
> > The main blockers right now are NVMe and networking.  Did anybody have
> > success with these with a reasonable kernel config?
> 
> The JH7110_VisionFive2_upstream branch provided a defconfig (arch/riscv/configs/starfive_visionfive2_defconfig)
> for the VisionFive 2 board [1]. You can refer to this file to make your own one.
> 
> [1] https://github.com/starfive-tech/linux/commit/b3b7bd55b3b54dd4e26750078b8a18ea2333ee5c

Thanks, I did try to use this config as a base, but unfortunately it's
quite far from a standard Debian kernel config (everything is selected as
built-in instead of modules, the compression mode is uncommon, etc).  So I
started from the current riscv64 kernel config from upstream Debian and
added missing config items.

> I had tested NVMe (Samsung 970 EVO Plus) and Ethernet successfully with
> starfive_visionfive2_defconfig.

I tested several combinations:

- another Samsung 970 EVO Plus unit and my kernel based on JH7110_VisionFive2_upstream: still hangs
- Ubuntu 23.10 image (with a kernel identified as "6.5.0-9.9.1-generic 6.5.3") and both Samsung SSDs: still hangs

However, I finally determined that the problem is actually caused by the
power supply.  It's a 5V/2.4A adapter ("Akashi" brand), but clearly it
cannot supply enough power for the board + the Samsung SSD, or maybe the
voltage is not stable enough.

I tried another higher-quality power supply (5V/2A from OnePlus) and this
time everything works fine with the Samsung SSD.

Sorry for the noise about this misleading PCIe/NVMe "problem".

> Ethernet

This was solved after enabling CONFIG_MOTORCOMM_PHY (not currently present
in the upstream Debian kernel config).

> The crypto code in the mainline can really cause the kernel crash, so you should
> disable it as what starfive_visionfive2_defconfig does.

Ok, thanks for the hint, I have blacklisted it for now.

Baptiste

Attachment: signature.asc
Description: PGP signature


Reply to: