Re: [PATCH 1/7] KVM: MMU: optimize pte write path if don't have protectedsp

From: Avi Kivity
Date: Sun May 15 2011 - 04:38:43 EST


On 05/15/2011 11:33 AM, Xiao Guangrong wrote:
>
> These atomic ops are always called from within the spinlock, so we don't need an atomic_t here.
>
> Sorry, I should have noticed this on the first version.

We read indirect_shadow_pages atomically on pte write path, that is allowed out of mmu_lock

Reading is fine:

#define atomic_read(v) (*(volatile int *)&(v)->counter)

--
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@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/