[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v8 2/5] xen/arm: Enable the existing x86 virtual PCI support for ARM
- To: Stefano Stabellini <sstabellini@xxxxxxxxxx>
- From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
- Date: Sat, 16 Oct 2021 12:28:19 +0200
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Dcrc6y8tGnkbkpUojhCEgZSqBl91j1MTHBx0ByDrd4g=; b=XYh1MrWdtCqR8HTJKdFXt1z1zrmc89DZ2pIdUX/0lXiKEXQ8Q5NJ9yith312XmOxHYi0Zrypk7KQcfhxN57eQYJtTdYOoI9MDMlly5RqffTmjHCarGEmtb7Qv9tnB+QDhGzT+GhLuDpKYhdjIPeCAfBXyM2vflht3EW5M+MJ0mZkM6VM9oqZ91Q7/XqxHX/8XzC4wv25m0cnYO1FwTGq2x6HPGZ4qFSz8SYXN0uUMrGFyTT23E9Ya0L75S2nBuDDoni5TRL2rzVN1eTPMeRRT5gLZpEgQkYUUq+e1N79i/Vato3RSNj9KneObbRkSRjlOesrTkPzHoiPkuwavatrBw==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KUwNBL3JyckKk3quoDmvVM3Vw8aHXWONytzuJEBRDTFGjkEFz2mE3NUgGJ3yB97y6fHla40uE2lE/Bw6IqET4SUyF+fnS32lHKUyANeV9Pbg+BicZcT/D9e3hsO2y+LRsmOv+HUM0XGA8zlSRoTGOnRbP1MI9Rzn2mvMhmRjaq16Kw6esQINNGdPALjPq1Ri6/MZwW6sGJmBEDi3tukk3ueLWhmhDdNVJRbm22Nk5lgLHANg5v8zxgThf8rRXewZF0Dm9MP0rplNc/zisaPz4u2SUOjEs0w6vUBVA1xyg7UZKOuRdNDDWPatVMZ7r+xpSmj2FjETl6WR0YmUF4ZXjA==
- Authentication-results: esa3.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
- Cc: Julien Grall <julien@xxxxxxx>, Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>, "iwj@xxxxxxxxxxxxxx" <iwj@xxxxxxxxxxxxxx>, Rahul Singh <Rahul.Singh@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, "Jan Beulich" <jbeulich@xxxxxxxx>, Wei Liu <wl@xxxxxxx>, Paul Durrant <paul@xxxxxxx>
- Delivery-date: Sat, 16 Oct 2021 10:29:10 +0000
- Ironport-data: A9a23:fMEjkK8b8KFaTAy6ViMoDrUD93iTJUtcMsCJ2f8bNWPcYEJGY0x3y 2dLDzuAPfrcZTPweYp2a42y805TsJHVzdcxHQs//ik8E34SpcT7XtnIdU2Y0wF+jyHgoOCLy +1EN7Es+ehtFie0Si9AttENlFEkvU2ybuOU5NXsZ2YhGGeIdA970Ug6wrZg3NYy6TSEK1jlV e3a8pW31GCNg1aYAkpMg05UgEoy1BhakGpwUm0WPZinjneH/5UmJMt3yZWKB2n5WuFp8tuSH I4v+l0bElTxpH/BAvv9+lryn9ZjrrT6ZWBigVIOM0Sub4QrSoXfHc/XOdJFAXq7hQllkPhs0 PlptrLgeD4DO/adgNgYehJoFgxxaPguFL/veRBTsOSWxkzCNXDt3+9vHAc9OohwFuRfWD8Us 6ZCcXZUM07F17neLLGTE4GAguw5K8bmJsUHs2xIxjDFF/c2B5vERs0m4PcFgWxv2Z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eVi 387OvdkZLamlhSTyhpaByDI9BcT0bt1i4IxJdKCFsi0aG6NTgixiA2BBCwkUhf0DYLMdXQXq6h mXlvtDsCruGX/yfEC9hpccY9xEl0gkd2RzzQORSy4+srBUpqncEQzz9tpczH7ro3zNDRqd9u1Z 3/nZDnQrXseyD747y8DkTEOw
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On Fri, Oct 15, 2021 at 12:47:17PM -0700, Stefano Stabellini wrote:
> On Fri, 15 Oct 2021, Julien Grall wrote:
> > On 15/10/2021 18:33, Bertrand Marquis wrote:
> > > > On 15 Oct 2021, at 18:25, Julien Grall <julien@xxxxxxx> wrote:
> > > >
> > > > Hi Bertrand,
> > > >
> > > > On 15/10/2021 17:51, Bertrand Marquis wrote:
> > > > > diff --git a/xen/drivers/passthrough/pci.c
> > > > > b/xen/drivers/passthrough/pci.c
> > > > > index 3aa8c3175f..35e0190796 100644
> > > > > --- a/xen/drivers/passthrough/pci.c
> > > > > +++ b/xen/drivers/passthrough/pci.c
> > > > > @@ -756,6 +756,19 @@ int pci_add_device(u16 seg, u8 bus, u8 devfn,
> > > > > if ( !pdev->domain )
> > > > > {
> > > > > pdev->domain = hardware_domain;
> > > > > +#ifdef CONFIG_ARM
> > > > > + /*
> > > > > + * On ARM PCI devices discovery will be done by Dom0. Add
> > > > > vpci
> > > > > handler
> > > > > + * when Dom0 inform XEN to add the PCI devices in XEN.
> > > > > + */
> > > > > + ret = vpci_add_handlers(pdev);
> > > >
> > > > I don't seem to find the code to remove __init_hwdom in this series. Are
> > > > you intending to fix it separately?
> > >
> > > Yes I think it is better to fix that in a new patch as it will require
> > > some
> > > discussion as it will impact the x86 code if I just remove the flag now.
> > For the future patch series, may I ask to keep track of outstanding issues
> > in
> > the commit message (if you don't plan to address them before commiting) or
> > after --- (if they are meant to be addressed before commiting)?
> >
> > In this case, the impact on Arm is this would result to an hypervisor crash
> > if
> > called. If we drop __init_hwdom, the impact on x86 is Xen text will slightly
> > be bigger after the boot time.
> >
> > AFAICT, the code is not reachable on Arm (?). Therefore, one could argue we
> > this can wait after the week-end as this is a latent bug. Yet, I am not
> > really
> > comfortable to see knowningly buggy code merged.
> >
> > Stefano, would you be willing to remove __init_hwdom while committing it? If
> > not, can you update the commit message and mention this patch doesn't work
> > as
> > intended?
>
> I prefer not to do a change like this on commit as it affects x86.
>
> I added a note in the commit message about it. I also added Roger's ack
> that was given to the previous version. FYI this is the only outstanding
> TODO as far as I am aware (there are other pending patch series of
> course).
>
> After reviewing the whole series again, checking it against all the
> reviewers comments, and making it go through gitlab-ci, I committed the
> series.
Hello,
Maybe I'm being pedantic, or there was some communication outside the
mailing list, but I think strictly speaking you are missing an Ack
from either Jan or Paul for the xen/drivers/passthrough/pci.c change.
IMHO seeing how that chunk moved from 3 different places in just one
afternoon also doesn't give me a lot of confidence. It's Arm only code
at the end, so it's not going to effect the existing x86 support and
I'm not specially worried, but I would like to avoid having to move it
again.
Regards, Roger.
|