From: Ard Biesheuvel Date: Mon, 4 May 2015 01:25:05 +0000 (+0800) Subject: kvm: add a memslot flag for incoherent memory regions X-Git-Tag: v3.18.14~221 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=02f88a7f2ae921317c91f629d61c39e107b9af23;p=thirdparty%2Fkernel%2Fstable.git kvm: add a memslot flag for incoherent memory regions commit 1050dcda3052912984b26fb6d2695a3f41792000 upstream. Memory regions may be incoherent with the caches, typically when the guest has mapped a host system RAM backed memory region as uncached. Add a flag KVM_MEMSLOT_INCOHERENT so that we can tag these memslots and handle them appropriately when mapping them. Signed-off-by: Ard Biesheuvel Signed-off-by: Marc Zyngier Signed-off-by: Shannon Zhao Signed-off-by: Sasha Levin --- diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index a6059bdf7b03b..e4d8f705fecd0 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h @@ -43,6 +43,7 @@ * include/linux/kvm_h. */ #define KVM_MEMSLOT_INVALID (1UL << 16) +#define KVM_MEMSLOT_INCOHERENT (1UL << 17) /* Two fragments for cross MMIO pages. */ #define KVM_MAX_MMIO_FRAGMENTS 2