Re: [PATCH] KVM: nVMX: Don't return error on nested bitmap memory allocation failure

2015-04-29 Thread Nadav Amit
Bandan Das b...@redhat.com wrote: If get_free_page() fails for nested bitmap area, it's evident that we are gonna get screwed anyway but returning failure because we failed allocating memory for a nested structure seems like an unnecessary big hammer. Also, save the call for later; after

Re: [PATCH] KVM: nVMX: Don't return error on nested bitmap memory allocation failure

2015-04-29 Thread Paolo Bonzini
On 29/04/2015 09:27, Nadav Amit wrote: free_page appears to check whether the address is zero before it actually frees the page. Perhaps it is better to leverage this behaviour to remove all the outX and simplify the code. Agreed. Regarding this patch, I agree with Jan. Paolo -- To

Re: [PATCH] KVM: nVMX: Don't return error on nested bitmap memory allocation failure

2015-04-29 Thread Jan Kiszka
Am 2015-04-28 um 21:55 schrieb Bandan Das: If get_free_page() fails for nested bitmap area, it's evident that we are gonna get screwed anyway but returning failure because we failed allocating memory for a nested structure seems like an unnecessary big hammer. Also, save the call for later;

Re: [PATCH v2 06/10] KVM: arm64: guest debug, add SW break point support

2015-04-29 Thread Christoffer Dall
On Tue, Apr 28, 2015 at 03:37:01PM +0100, Alex Bennée wrote: Christoffer Dall christoffer.d...@linaro.org writes: On Tue, Apr 28, 2015 at 10:34:12AM +0100, Peter Maydell wrote: On 28 April 2015 at 09:42, Alex Bennée alex.ben...@linaro.org wrote: Peter Maydell peter.mayd...@linaro.org

Re: [PATCH] kvmclock: set scheduler clock stable

2015-04-29 Thread Paolo Bonzini
On 29/04/2015 03:47, Marcelo Tosatti wrote: On Thu, Apr 23, 2015 at 05:12:42PM -0400, Luiz Capitulino wrote: If you try to enable NOHZ_FULL on a guest today, you'll get the following error when the guest tries to deactivate the scheduler tick: WARNING: CPU: 3 PID: 2182 at

Re: [PATCH] KVM: nVMX: Don't return error on nested bitmap memory allocation failure

2015-04-29 Thread Jan Kiszka
Am 2015-04-29 um 14:55 schrieb Bandan Das: Jan Kiszka jan.kis...@siemens.com writes: Am 2015-04-28 um 21:55 schrieb Bandan Das: If get_free_page() fails for nested bitmap area, it's evident that we are gonna get screwed anyway but returning failure because we failed allocating memory for a

Re: [PATCH] context_tracking: avoid extra checks on guest_enter and guest_exit

2015-04-29 Thread Rik van Riel
On 04/29/2015 05:21 AM, Paolo Bonzini wrote: guest_enter and guest_exit must be called with interrupts disabled, since they take the vtime_seqlock with write_seq{lock,unlock}. Therefore, it is not necessary to check for exceptions, nor to save/restore the IRQ state, when context tracking

Re: [PATCH] KVM: nVMX: Don't return error on nested bitmap memory allocation failure

2015-04-29 Thread Bandan Das
Jan Kiszka jan.kis...@siemens.com writes: Am 2015-04-28 um 21:55 schrieb Bandan Das: If get_free_page() fails for nested bitmap area, it's evident that we are gonna get screwed anyway but returning failure because we failed allocating memory for a nested structure seems like an unnecessary

Re: APIC_ID in apic_reg_write()

2015-04-29 Thread Jan Kiszka
Am 2015-04-29 um 20:54 schrieb Bandan Das: Jan Kiszka jan.kis...@siemens.com writes: Am 2015-04-29 um 18:47 schrieb Bandan Das: Why do we allow writes to APIC_ID ? On all _newer_ processors, it's read only. The spec doesn't explicitly mention it though, or atleast I couldn't find it. Does

Re: APIC_ID in apic_reg_write()

2015-04-29 Thread Jan Kiszka
Am 2015-04-29 um 18:47 schrieb Bandan Das: Why do we allow writes to APIC_ID ? On all _newer_ processors, it's read only. The spec doesn't explicitly mention it though, or atleast I couldn't find it. Does userspace have a reason to modify it ? The APIC ID is read-only for x2APIC. It remains

Re: APIC_ID in apic_reg_write()

2015-04-29 Thread Jan Kiszka
Am 2015-04-30 um 00:21 schrieb Bandan Das: Jan Kiszka jan.kis...@siemens.com writes: ... And I can verify on a SandyBridge and Haswell system that it's RO there too. So the APIC just ignores the writes, it doesn't through #GP at least. In fact, that was one of the reasons I had submitted