lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f75f1a112c58e072d05ca671100438587295e089.camel@infradead.org>
Date:   Mon, 18 Sep 2023 14:30:05 +0100
From:   David Woodhouse <dwmw2@...radead.org>
To:     paul@....org, kvm@...r.kernel.org, linux-kernel@...r.kernel.org
Cc:     Paul Durrant <pdurrant@...zon.com>,
        Sean Christopherson <seanjc@...gle.com>,
        Paolo Bonzini <pbonzini@...hat.com>
Subject: Re: [PATCH v2 10/12] KVM: selftests / xen: map shared_info using
 HVA rather than GFN

On Mon, 2023-09-18 at 14:24 +0100, Paul Durrant wrote:
> On 18/09/2023 14:19, David Woodhouse wrote:
> > On Mon, 2023-09-18 at 11:21 +0000, Paul Durrant wrote:
> > > 
> > > -                               ret = pthread_create(&thread, NULL, &juggle_shinfo_state, (void *)vm);
> > > +                               if (has_shinfo_hva)
> > > +                                       ret = pthread_create(&thread, NULL,
> > > +                                                            &juggle_shinfo_state_hva, (void *)vm);
> > > +                               else
> > > +                                       ret = pthread_create(&thread, NULL,
> > > +                                                            &juggle_shinfo_state_gfn, (void *)vm);
> > >                                  TEST_ASSERT(ret == 0, "pthread_create() failed: %s", strerror(ret));
> > >   
> > 
> > 
> > This means you don't exercise the GFN-based path (which all current VMM
> > implementations use) on newer kernels. Could you have a single
> > juggle_shinfo_state() function as before, but make it repeatedly set
> > and clear the shinfo using *both* HVA and GFN (if the former is
> > available, of course).
> 
> The guidance is to use HVA if the feature is available; a VMM should not 
> really be mixing and matching. That said, setting it either way should 
> be equivalent.

Sure, but this isn't really a VMM; it's a test harness to exercise a
bunch of ioctls. One of which it no longer bothers to test now, if the
new variant exists.

If we're going to keep the old API we should also continue to *test*
the old API. (And we should).


Download attachment "smime.p7s" of type "application/pkcs7-signature" (5965 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ