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]
Date:	Sun, 10 Oct 2010 14:47:43 +0200
From:	Avi Kivity <avi@...hat.com>
To:	Gleb Natapov <gleb@...hat.com>
CC:	kvm@...r.kernel.org, linux-mm@...ck.org,
	linux-kernel@...r.kernel.org, mingo@...e.hu,
	a.p.zijlstra@...llo.nl, tglx@...utronix.de, hpa@...or.com,
	riel@...hat.com, cl@...ux-foundation.org, mtosatti@...hat.com
Subject: Re: [PATCH v6 06/12] Add PV MSR to enable asynchronous page faults
 delivery.

  On 10/07/2010 07:53 PM, Gleb Natapov wrote:
> On Thu, Oct 07, 2010 at 02:42:06PM +0200, Avi Kivity wrote:
> >   On 10/04/2010 05:56 PM, Gleb Natapov wrote:
> >  >Guest enables async PF vcpu functionality using this MSR.
> >  >
> >  >   			return NON_PRESENT;
> >  >+
> >  >+MSR_KVM_ASYNC_PF_EN: 0x4b564d02
> >  >+	data: Bits 63-6 hold 64-byte aligned physical address of a 32bit memory
> >
> >  Given that it must be aligned anyway, we can require it to be a
> >  64-byte region and also require that the guest zero it before
> >  writing the MSR.  That will give us a little more flexibility in the
> >  future.
> >
> No code change needed, so OK.

The guest needs to allocate a 64-byte per-cpu entry instead of a 4-byte 
entry.

> >
> >  >+		return 0;
> >  >+	}
> >  >+
> >  >+	if (kvm_gfn_to_hva_cache_init(vcpu->kvm,&vcpu->arch.apf.data, gpa))
> >  >+		return 1;
> >
> >  Note: we need to handle the memory being removed from underneath
> >  kvm_gfn_to_hve_cache().  Given that, we can just make
> >  kvm_gfn_to_hva_cache_init() return void.  "success" means nothing
> >  when future changes can invalidate it.
> >
> I want to catch guest doing stupid things. If guest give us non-existent
> address I want wrmsr to #GP.

Ok.

> >  >+
> >  >+	kvm_async_pf_wakeup_all(vcpu);
> >
> >  Why is this needed?  If all apfs are flushed at disable time, what
> >  do we need to wake up?
> For migration. Destination will rewrite msr and all processes will be
> waked up.

Ok. What happens to apf completions that happen after all vcpus are stopped?

> >
> >  Need to list the MSR for save/restore/reset.
> >
> >
> This patch adds it to msrs_to_save, no?

Yes, missed it somehow.

-- 
error compiling committee.c: too many arguments to function

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ