Re: [PATCH] kvm: allow RO page when atomic !write_fault

2011-02-22 Thread Lai Jiangshan
On 02/21/2011 05:47 PM, Gleb Natapov wrote: On Mon, Feb 21, 2011 at 11:47:36AM +0800, Lai Jiangshan wrote: Atomic-able hva_to_pfn() patches and allow-read-only-page patches are merged almost the same time. But hva_to_pfn() does not handle these two issues well together. When @atomic

Re: [PATCH] kvm: allow RO page when atomic !write_fault

2011-02-22 Thread Marcelo Tosatti
On Mon, Feb 21, 2011 at 11:47:36AM +0800, Lai Jiangshan wrote: Atomic-able hva_to_pfn() patches and allow-read-only-page patches are merged almost the same time. But hva_to_pfn() does not handle these two issues well together. When @atomic !@write_fault host-is-read-only-page-mapped the

Re: [PATCH] kvm: allow RO page when atomic !write_fault

2011-02-21 Thread Gleb Natapov
On Mon, Feb 21, 2011 at 11:47:36AM +0800, Lai Jiangshan wrote: Atomic-able hva_to_pfn() patches and allow-read-only-page patches are merged almost the same time. But hva_to_pfn() does not handle these two issues well together. When @atomic !@write_fault host-is-read-only-page-mapped the

[PATCH] kvm: allow RO page when atomic !write_fault

2011-02-20 Thread Lai Jiangshan
Atomic-able hva_to_pfn() patches and allow-read-only-page patches are merged almost the same time. But hva_to_pfn() does not handle these two issues well together. When @atomic !@write_fault host-is-read-only-page-mapped the code will return fault_page, actually, it will be better if we return