From: Alistair Francis <alistair23@gmail.com>
To: Palmer Dabbelt <palmer@sifive.com>
Cc: Logan Gunthorpe <logang@deltatee.com>,
qemu-riscv@nongnu.org,
Alistair Francis <Alistair.Francis@wdc.com>,
"qemu-devel@nongnu.org Developers" <qemu-devel@nongnu.org>,
Guenter Roeck <linux@roeck-us.net>,
Andrea Bolognani <abologna@redhat.com>
Subject: Re: [Qemu-devel] [PATCH for-3.2 v7 5/6] hw/riscv/sifive_u: Connect the Xilinx PCIe
Date: Wed, 21 Nov 2018 13:49:53 -0800 [thread overview]
Message-ID: <CAKmqyKM2pmF_D812mp1hcJe8KcLGiNz9vLpy7OpsbS0XxNwo+w@mail.gmail.com> (raw)
In-Reply-To: <mhng-ac7d7069-f2ae-45b5-a950-17410b48481f@palmer-si-x1c4>
On Wed, Nov 21, 2018 at 1:26 PM Palmer Dabbelt <palmer@sifive.com> wrote:
>
> On Wed, 21 Nov 2018 10:32:45 PST (-0800), alistair23@gmail.com wrote:
> > On Wed, Nov 21, 2018 at 10:05 AM Logan Gunthorpe <logang@deltatee.com> wrote:
> >>
> >>
> >>
> >> On 2018-11-21 10:02 a.m., Alistair Francis wrote:
> >> > Connect the Xilinx PCIe device based on the information in the device
> >> > tree stored in the ROM of the HiFish Unleashed board.
> >>
> >> I only briefly tested this patch but could not get any PCI devices to
> >> come up with the sifive_u machine. Depending on the kernel I tried, it
> >> either failed to initialize a Xilinx PCIe (likely due to a mismatch with
> >> the DT) or it appears to successfully initialize a Microsemi device but
> >> did not enumerate any devices underneath.
> >
> > That seems like either a kernel or bbl issue.
> >
> > You need to make sure that bbl doesn't edit the device tree (to add
> > the Microsemi device or remove the Xilinx one) and ensure your kernel
> > supports the Xilinx one.
> >
> >>
> >> In any case, it would be nice if the Microsemi/Xilinx confusion was at
> >> least explained in the commit message.
> >
> > What should we say? The QEMU machine accurately models the real
> > hardware which reports a Xilinx PCIe. The confusion generally appears
> > above QEMU where people are used to using the MicroSemi one.
>
> I think the real issue here is that "sifive_u" doesn't actually fully describe
> the device we're trying to emulate. Is it a:
>
> * Generic SiFive U core? In that case we just have a 64-bit core and
> essentially no devices. This is kind of useless.
> * A HiFive Unleashed? In that case there's no PCIe, as it requires an
> expansion board.
> * A HiFive Unleashed + VC707? Here we have Xilinx PCIe.
> * A HiFive Unleashed + Microsemi Expansion? Here have Microsemi PCIe.
This isn't even always consistent. For example the sifive_u machine
exists for 32-bit cores, but the PCIe address reported by the hardware
only works for 64-bit machines.
So we need a trade off between accurately modelling the hardware or
having 32-bit support.
>
> There's a tradeoff between accurately emulating the hardware and blowing up the
> amount of targets we support in QEMU. We went through this discussion before
> and ended up where we are now, but maybe it's best to go have the discussion
> again?
Up to you, it is your board :)
I think it makes more sense to remove these generic boards (that is
what the virt board is for) and model real hardware boards.
Alistair
next prev parent reply other threads:[~2018-11-21 21:50 UTC|newest]
Thread overview: 65+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-21 17:02 [Qemu-devel] [PATCH for-3.2 v7 0/6] Connect a PCIe host and graphics support to RISC-V Alistair Francis
2018-11-21 17:02 ` [Qemu-devel] [PATCH for-3.2 v7 1/6] hw/riscv/virt: Increase the number of interrupts Alistair Francis
2018-11-21 17:58 ` Logan Gunthorpe
2018-11-21 18:17 ` Alistair Francis
2018-11-21 18:45 ` Logan Gunthorpe
2018-11-21 18:49 ` Alistair Francis
2018-11-21 18:56 ` Logan Gunthorpe
2018-11-21 18:59 ` Alistair Francis
2018-11-21 19:02 ` Logan Gunthorpe
2018-11-21 17:02 ` [Qemu-devel] [PATCH for-3.2 v7 2/6] hw/riscv/virt: Adjust memory layout spacing Alistair Francis
2018-11-21 17:59 ` Logan Gunthorpe
2018-11-21 17:02 ` [Qemu-devel] [PATCH for-3.2 v7 3/6] hw/riscv/virt: Connect the gpex PCIe Alistair Francis
2018-11-21 18:01 ` Logan Gunthorpe
2018-11-21 18:21 ` Alistair Francis
2018-11-21 17:02 ` [Qemu-devel] [PATCH for-3.2 v7 4/6] riscv: Enable VGA and PCIE_VGA Alistair Francis
2018-11-21 18:01 ` Logan Gunthorpe
2018-11-21 17:02 ` [Qemu-devel] [PATCH for-3.2 v7 5/6] hw/riscv/sifive_u: Connect the Xilinx PCIe Alistair Francis
2018-11-21 18:05 ` Logan Gunthorpe
2018-11-21 18:32 ` Alistair Francis
2018-11-21 18:50 ` Logan Gunthorpe
2018-11-21 19:02 ` Alistair Francis
2018-11-21 19:08 ` Logan Gunthorpe
2018-11-21 19:16 ` Alistair Francis
2018-11-21 19:19 ` Logan Gunthorpe
2018-11-21 19:21 ` Alistair Francis
2018-11-21 19:24 ` Logan Gunthorpe
2018-11-21 19:51 ` Alistair Francis
2018-11-21 21:54 ` Alistair Francis
2018-11-21 22:01 ` Logan Gunthorpe
2018-11-21 22:09 ` Alistair Francis
2018-11-21 22:11 ` Logan Gunthorpe
2018-11-21 22:15 ` Palmer Dabbelt
2018-11-21 21:37 ` Palmer Dabbelt
2018-11-21 22:01 ` Alistair Francis
2018-11-21 22:15 ` Palmer Dabbelt
2018-11-21 19:15 ` Logan Gunthorpe
2018-11-21 19:18 ` Alistair Francis
2018-11-21 19:20 ` Logan Gunthorpe
2018-11-21 21:26 ` Palmer Dabbelt
2018-11-21 21:49 ` Alistair Francis [this message]
2018-11-21 22:15 ` Palmer Dabbelt
2018-11-21 22:23 ` Alistair Francis
2018-11-21 22:36 ` Palmer Dabbelt
2018-11-21 23:10 ` Guenter Roeck
2018-11-21 23:26 ` Logan Gunthorpe
2018-11-22 2:13 ` Palmer Dabbelt
2018-11-22 2:23 ` Alistair Francis
2018-11-26 19:15 ` Palmer Dabbelt
2018-11-21 18:36 ` Guenter Roeck
2018-11-21 18:55 ` Logan Gunthorpe
2018-11-21 17:03 ` [Qemu-devel] [PATCH for-3.2 v7 6/6] hw/riscv/virt: Connect a VirtIO net PCIe device Alistair Francis
2018-11-21 18:07 ` Logan Gunthorpe
2018-11-21 18:34 ` Alistair Francis
2018-11-21 19:11 ` Logan Gunthorpe
2018-11-21 21:55 ` Alistair Francis
2018-11-21 22:07 ` Logan Gunthorpe
2018-11-21 22:11 ` Alistair Francis
2018-11-21 22:14 ` Alistair Francis
2018-11-21 22:16 ` Logan Gunthorpe
2018-11-21 22:18 ` Logan Gunthorpe
2018-11-22 10:59 ` [Qemu-devel] [PATCH for-3.2 v7 0/6] Connect a PCIe host and graphics support to RISC-V Andrea Bolognani
2018-11-26 16:03 ` Alistair Francis
2018-11-26 19:34 ` Palmer Dabbelt
2018-11-26 21:33 ` Guenter Roeck
2018-11-27 12:40 ` Andrea Bolognani
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAKmqyKM2pmF_D812mp1hcJe8KcLGiNz9vLpy7OpsbS0XxNwo+w@mail.gmail.com \
--to=alistair23@gmail.com \
--cc=Alistair.Francis@wdc.com \
--cc=abologna@redhat.com \
--cc=linux@roeck-us.net \
--cc=logang@deltatee.com \
--cc=palmer@sifive.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-riscv@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).