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

Re: [PATCH for-4.15 v2] VMX: use a single, global APIC access page


  • To: Jan Beulich <jbeulich@xxxxxxxx>
  • From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Date: Mon, 22 Feb 2021 11:09:28 +0100
  • 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-SenderADCheck; bh=Pqfrxr549WpMuPY429Zzbo+E3Xzkh0J3wI+EMwusg4A=; b=jzyslptbbd+MVlf4/Ctoc1mc7Gdyc1VUt916FrWrKeNICjky9AFJmY6LBm05t/DkX8fnmZCuY9YnZqmhFRGFkxBk8CclvbX69qlPJyFpeshUteGMyIzOSPerqffnHgh1mNml2cJrInIEVuRf8hSNlNYhpRxVusj5s4DOvsovJm6YKA894yyNNG11bgTLbpdG+j4BCYFWW+VoH7fncPq6ZKhlSIem1TWYE6gmMqKwMj0vN3BneLwCsxbJLu/7p/2dlr7CdgsC+tjIrMaRahwqVx+yJBEd5Fffs2BI8PdEogWsTU7XWhd31ezG33ZQs28Xskp4X782cyAY74mOiED/Gg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RtMWGve/Vz4B9/a8sIvCK3qjQU0l+GiPb25J89JRQS3XZs0vvx2b2GxmMxJXJ+4HrwjOKtRIuwmzyS32lnp4V1jsOsZ+icEaEiEHNDsFj9Sqz0KAoWDJr8F60eryfgW7fPYPGN3jhsE/1HsPZwpRTmoaQC4nHr842GadwXrgp3WtPmA68x2J+H7EtEavr53uhMd/FftPb2uFV1cONh8VLu+sf+gzkEXlxR/LmluX5VExuvuwk/mVBjW1CS90G9ZBI02k3HNqH2R+F1ZE7FHPnKZfUkNQdz03RATzciPKc/DVlvkq/E+f1Ve45BaeyholhI1MH21bg6ex58rtKfnjpQ==
  • Authentication-results: esa3.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: Ian Jackson <iwj@xxxxxxxxxxxxxx>, George Dunlap <George.Dunlap@xxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Kevin Tian <kevin.tian@xxxxxxxxx>, "Julien Grall" <julien@xxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Mon, 22 Feb 2021 10:10:32 +0000
  • Ironport-sdr: 4y5Hl5XxpXt/lYh8cLweGUY8vq5Ckz+EXFhHagFTp59TwNvf60G64oYr73x2mdNMUO0Yooa191 L23sh8wZhgStQcc+NRD6NTQiaH9WLvNQd5oYGF7psAYd6xKXyp0n9Cj9eUkEIm+MwVDaHHsYBS q0qfkwSyjMc9B9tCg1ccBj38cebrr1PpoumdOsbzSxwyRvvTdwAnc5GJDtnhQLZ6U8MD37w7qy OfIcxyXZrWpniUU3vLoiwpJzlHdS4iQrhZgUwLjuQ3dGDy+I5uOQWyhX3T7grpGhY6SlBtMPA8 +po=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On Mon, Feb 22, 2021 at 08:51:59AM +0100, Jan Beulich wrote:
> On 19.02.2021 18:05, Ian Jackson wrote:
> > Jan Beulich writes ("Re: [PATCH v2] VMX: use a single, global APIC access 
> > page"):
> >> While this patch was triggered not just by Julien's observation of
> >> the early p2m insertion being a problem, but also many earlier
> >> times of running into this odd code, it is - especially at this
> >> stage - perhaps a possible option to split the change into just
> >> the movement of the set_mmio_p2m_entry() invocation and all the
> >> rest, in order to defer that rest until after 4.15.
> > 
> > I infer that this contains a bugfix, but perhaps other
> > changes/improvements too.
> > 
> > George, I think you're our expert on this refcounting stuff - what do
> > you think of this ?
> > 
> > I guess my key question is whether this change will introduce risk by
> > messing with the complex refcounting machineryt - or remove it by
> > removing an interaction with the refcounting.
> 
> If anything, then the latter, but largely neither afaict - there's no
> change in this regard here at all as far as the guest could affect
> behavior, due to the page getting inserted as p2m_mmio_direct, and
> guest_remove_page() having
> 
>     if ( p2mt == p2m_mmio_direct )
>     {
>         rc = clear_mmio_p2m_entry(d, gmfn, mfn, PAGE_ORDER_4K);
>         goto out_put_gfn;
>     }
> 
> before any refcounting logic is reached. The removal of interaction
> is because now the page doesn't get associated with a domain (and
> hence doesn't become subject to refcounting) at all.
> 
> The risk of the change stems from going from using a per-domain
> page to using a single, system-wide one, which indeed was the subject
> of v1 discussion. In any event the consideration towards splitting
> the change would cover either concern. Perhaps I should really do so
> and submit as v3 ...

I agree it would be less risky to keep using a per-domain page, and
switch to a global one after the release. From the discussion in v1 I
don't think we where able to spot any specific issues apart from
guests possibly being able to access shared data in this page from
passthrough devices. I would at least feel more confortable with
that approach given the point we are in the release process.

Thanks, Roger.



 


Rackspace

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