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

Re: [PATCH v2 6/6] xen_arm: Add virtual PCIe host bridge support


  • To: Vikram Garhwal <vikram.garhwal@xxxxxxx>
  • From: Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Date: Thu, 23 Nov 2023 00:11:30 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=epam.com; dmarc=pass action=none header.from=epam.com; dkim=pass header.d=epam.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=Yg5IKdJ3sJaUwvbyO2HX4rr4pZeOo+2XVSWIPetYogQ=; b=Y47oKmjG7XXFPQzX0qG74VSQpspebMuCauIfEXHhI7S1klCgh1PrLft1bLzzs6kUzjgLazwBDb+/urVCKfYEyOrprY2lyrMB06P+jPG43BiqgfgsRMwkHRWRJplbW1Qad16GvZz08yRpjm98hIqb7sAIqmwAw3YzBsi11hhWpEcrRLz1p+mO//Kj/qf9dcHxSnlnREK+l4aKY23Xdb5A8kuXPD+mgXEVB3w3Az3m2/+TZ7jHlNLQfropbfP1KVVIegcT+D+uM/2DyDoOfLw1SjxHgCCn82V/XPBmnYDmzTrW9+cEFXx3Ylx5lx70lse678imiHAEMTqkmnceL+SMMQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ac7cqcZRB25QyYZ/jW83mDW82VFOALuLgG2s32sfBMjNo2W6YQG7jnkglQH8nu6t8dlvIaDkeCeVTjVeZnG8Et0jsq2p9Hc4dYmNFTnkKriSJk89C5yOhrFt0/KeE42NgEOa31yMrt0ySNPgLVW2b2UZIFw/GdR3L1wQG7htcUSDkUBw5DXQ6L+lHTnYYAvv/UB+tqih6fuTZnC4vOB7VF3AGDZW6+pUDXaf/dbofKeFFZ0lu4TL+4M01n8u7nbZAtgvao24QB+tw7038jJv/m6RykFx+vRt2em1FumK88nmxLd3vK96iT44ADnK4NGjWqh//T4D/daSZVIIqDOF9Q==
  • Cc: Stefano Stabellini <sstabellini@xxxxxxxxxx>, "qemu-devel@xxxxxxxxxx" <qemu-devel@xxxxxxxxxx>, David Woodhouse <dwmw@xxxxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Oleksandr Tyshchenko <Oleksandr_Tyshchenko@xxxxxxxx>, Peter Maydell <peter.maydell@xxxxxxxxxx>, Anthony Perard <anthony.perard@xxxxxxxxxx>, Paul Durrant <paul@xxxxxxx>, "open list:ARM TCG CPUs" <qemu-arm@xxxxxxxxxx>, "open list:X86 Xen CPUs" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Thu, 23 Nov 2023 00:11:49 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AQHaHMeJqHnam8LJkECFe490J2r1JLCG8AcAgAASMYCAAAZ1AA==
  • Thread-topic: [PATCH v2 6/6] xen_arm: Add virtual PCIe host bridge support

Hi Vikram,

Vikram Garhwal <vikram.garhwal@xxxxxxx> writes:

> Hi Volodymyr,
> Thank you sharing this patch. I have few comments below
> On Wed, Nov 22, 2023 at 02:39:46PM -0800, Stefano Stabellini wrote:
>> +Vikram
>> 
>> On Tue, 21 Nov 2023, Volodymyr Babchuk wrote:
>> > From: Oleksandr Tyshchenko <oleksandr_tyshchenko@xxxxxxxx>
>> > 
>> > The bridge is needed for virtio-pci support, as QEMU can emulate the
>> > whole bridge with any virtio-pci devices connected to it.
>> > 
>> > This patch provides a flexible way to configure PCIe brige resources
>> > with xenstore. We made this for several reasons:
>> > 
>> > - We don't want to clash with vPCI devices, so we need information
>> >   from Xen toolstack on which PCI bus to use.
>> > - The guest memory layout that describes these resources is not stable
>> >   and may vary between guests, so we cannot rely on static resources
>> >   to be always the same for both ends.
>> > - Also the device-models which run in different domains and serve
>> >   virtio-pci devices for the same guest should use different host
>> >   bridge resources for Xen to distinguish. The rule for the guest
>> >   device-tree generation is one PCI host bridge per backend domain.
>> > 
>> > Signed-off-by: Oleksandr Tyshchenko <oleksandr_tyshchenko@xxxxxxxx>
>> > Signed-off-by: Volodymyr Babchuk <volodymyr_babchuk@xxxxxxxx>
>> 
>> There is still a discussion ongoing on xen-devel if / how to register a
>> PCI Root Complex or individual BDFs. In the meantime a couple of
>> comments.
>> 
>> Typically emulated devices are configured in QEMU via QEMU command line
>> parameters, not xenstore. If you are running QEMU in a domU (instead of
>> Dom0) you can always read config parameters from xenstore from a wrapper
>> bash script (using xenstore-read) and then pass the right command line
>> options to QEMU.
>> 
>> If you need help in adding new QEMU command line options, Vikram (CCed)
>> can help.
>> 
>> 
> I agree with Stefano here. Setting properties would be better and easier.

Okay, I'll look at this.

> I have one questions here:
> 1. If there are multiple QEMU backends, which means xen tools will end up
> creating lot of entries in xenstore and we need to remove those xenstore
> entries when backend goes away. Is this already handled in Xen tools?

Well, this is not a classic PV backend, so common code in Xen Tools does
not handle those entries. I am not sure if tools remove entries right
now, because I am not the original author. But we definitely will remove
them in the final version of patches.

-- 
WBR, Volodymyr


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.