From: Joerg Roedel Date: Fri, 19 Feb 2010 15:23:04 +0000 (+0100) Subject: KVM: SVM: Annotate nested_svm_map with might_sleep() X-Git-Tag: v2.6.35-rc1~436^2~260 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;ds=sidebyside;h=6c3bd3d7660c35a703073b81eccfd5a3b7c15295;p=pandora-kernel.git KVM: SVM: Annotate nested_svm_map with might_sleep() The nested_svm_map() function can sleep and must not be called from atomic context. So annotate that function. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity --- diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c index 02f8d491d15a..4bc018333d76 100644 --- a/arch/x86/kvm/svm.c +++ b/arch/x86/kvm/svm.c @@ -1434,6 +1434,8 @@ static void *nested_svm_map(struct vcpu_svm *svm, u64 gpa, struct page **_page) { struct page *page; + might_sleep(); + page = gfn_to_page(svm->vcpu.kvm, gpa >> PAGE_SHIFT); if (is_error_page(page)) goto error;