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

Re: Design session PVH dom0


  • To: Juergen Gross <jgross@xxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Mon, 26 Sep 2022 09:53:44 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.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=k62p6jkfsfC26hBs62SH/S2bFQ0x7b7VQkMJ0Tz02ZU=; b=OlnRVNWH2XVMzLdDNGySYQY5Cvuu1ksHOo/AhLdO5BD+aY3M9oMuQkRsDS6wiLN3Tjry/KP0L/NZaGxDfS1P70QysIfAjj4KRSg0S5NOvk3bqMJwvlt4gG24zFreGqMdnBvoBw8TLYlO948mfQ11utoSrAw66bTs122/QvkeP6Juq8NYKwsZdkVREt8sX1wk2Fnw6H27wBrL2C0XKgQkSpKTkCvKiB+3HHhIcPCPH4tuJGZSmbmDOkJi7C6vKKc/eqcWg0r/N70hB3U29VZYt4oxqTSJZRRnY+HBMmlOz48be3lRexdJFHdIvNpf7MZhgtIKm4ssqxewnXgzlUsw9A==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lJAtT5SoD9oYPQI7n1C2OSnKeR8l2yRpHEKM7xkCQDlktfKy3H5n6OiMFo8FxWos1IzoRX0e7SaiLbYZI+eKEdysE3rOoIkC9KXXfK3Wy3zy/4h2C2jngX6rJyzwKciR58vl4XJIk8faObM1Ra+Tx3yUJHCQm1COZgGJB76u0Fz/Zi4r3voD6+VYJt5uBiKZSs96gmfwBuBEN53sZN17q+G1ky30lXtdJj9f1CdofV54OJmtB2mp5/oNu6pwoVvh0QvrFq8WoHCtMy/rI0NtVXjFiC7YbuWO0HECtKalhtAjDTOZnc1NHvOA0Wbmu043/Gn3y8Wo/yUoiSzSqwVkCA==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: Marek Marczykowski-Górecki <marmarek@xxxxxxxxxxxxxxxxxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Mon, 26 Sep 2022 07:53:48 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 23.09.2022 10:20, Juergen Gross wrote:
> On 21.09.22 17:53, Marek Marczykowski-Górecki wrote:
>> Session description (by Jan):
>> In the course of working on an XSA I had to finally get PVH Dom0 work on at 
>> least one of my systems, in a minimal fashion. This had turned up a number 
>> of issues, some of which have since remained pending. Therefore I’d like to 
>> gain understanding on whether there is any future to this mode of Dom0 
>> operation, and if so when it can be expected to be better than tech preview 
>> or even just experimental.
> 
> ...
> 
>> Jürgen: PVH dom0 performance?
>>
>> Roger: it's bad; mostly relevant is qemu interfaces
>>
>> George: only for safety certifications? performance penalty may be okay
>>
>> Jürgen: hypercalls can be improved (virtual buffers?)
> 
> Some more thoughts on this topic: Having hypercall variants with physically
> addressed buffers will help, but there is an additional complexity: what
> about hypercalls with really large buffers (e.g. the bitmap for modified
> pages for guest migration). In order to avoid having to allocate huge
> physically contiguous buffers for those purposes we'd probably need
> something like scatter/gather lists for hypercall buffers.

Not sure. I'd rather see us add new (sub)hypercalls for such non-standard
cases. E.g. the bitmap example you give would be amended by a new flavor
having the caller pass in an array of GFNs (perhaps, as you say, with
further indirection to deal with that array also growing large). I'd
really like to keep the common case simple.

> And those might
> want to be supported in a generic way. Additionally: what if such a SG-list
> would exceed the size of a page? The dirty bitmap of a guest with 64 GB of
> RAM would already need 512 pages, so the SG-list for that bitmap would already
> fill a complete page assuming only 8 byte for one SG-entry (which would limit
> the general usability already).
> 
> My favorite solution would be some kind of buffer address qualifier for each
> buffer (e.g. virtual, physical, SG-list, maybe nested SG-list). So the new
> hypercalls would not mean "physical buffer addresses", but "qualified buffer
> addresses". By requiring a minimum of 4-byte alignment for each buffer (can we
> do that, at least for the new hypercalls?) this would leave the 2 lowest bits
> of a buffer address for the new qualifier. If by any means an unaligned buffer
> is needed sometimes, it could still be achieved via a single-entry SG-list.

While this might be an option, I'm not sure I'd be really happy with such
re-use of the low address bits, nor with the implied further restriction
on buffer alignment (most struct-s we use are 4-byte aligned at least,
but I don't think it's all of them, plus we also have guest handles to
e.g. arrays of char).

Jan



 


Rackspace

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