Running qemu tests on RISC-V

Simon Glass sjg at chromium.org
Mon Feb 7 19:19:43 CET 2022


Hi Tom,

On Mon, 7 Feb 2022 at 09:49, Tom Rini <trini at konsulko.com> wrote:
>
> On Mon, Feb 07, 2022 at 11:34:17AM -0500, Sean Anderson wrote:
> >
> >
> > On 2/7/22 10:53 AM, Heinrich Schuchardt wrote:
> > > On 2/7/22 16:38, Simon Glass wrote:
> > >> Hi,
> > >>
> > >> I am trying to run the SPL tests for riscv32 but it dies with an
> > >> illegal instruction. I have tried building qemu 4.2 but it seems to
> > >> happen on various versions. Has anyone seen this?
> > >
> > > Did you try to run qemu-riscv32_spl_defconfig in the Docker container we
> > > are using for Gitlab?

No, I want to run it outside docker. I can see that it works in the
docker container, but not sure why it fails for me.

> > >
> > > We are using QEMU v6.1.0 according to tools/docker/Dockerfile.
> > >
> > > With all that duplicate output below it is hard to understand what is
> > > going. Why is each byte written twice to the serial?
> >
> > If I had to guess there are 2 harts, and they both trigger an illegal
> > instruction. In situations like these, I have added a spinlock around puts.

There are 4 CPUs I think.

>
> It might also be worth asking why such an old QEMU?  I know my
> host-provided QEMU is 4.2.1 but I just don't use it since it's too old
> for everything we do, especially on something as fast moving as RISC-V.

I tried 6.x and went back to 4.2.1 because I thought that might be the problem.

>
> And as an aside, if anyone has tips on changes that would need to be
> made to our Dockerfile so that some of those tools that let you run app
> from a container "normally" would work with our container, that'd be
> handy and appreciated.

I'm not sure what that means, probably because I am not an expert in that area.

Regards,
Simon


More information about the U-Boot mailing list