From: Anthony Liguori Date: Mon, 29 Oct 2007 20:15:20 +0000 (-0500) Subject: KVM: Fix gfn_to_page() acquiring mmap_sem twice X-Git-Tag: v2.6.25-rc1~1138^2~176 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aab61cc0d28f6fab0c2c9137d95dea54c7dbcf46;p=pandora-kernel.git KVM: Fix gfn_to_page() acquiring mmap_sem twice KVM's nopage handler calls gfn_to_page() which acquires the mmap_sem when calling out to get_user_pages(). nopage handlers are already invoked with the mmap_sem held though. Introduce a __gfn_to_page() for use by the nopage handler which requires the lock to already be held. This was noticed by tglx. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity --- Reading git-diff-tree failed