I tried to use the patches (regardless of PEBS).
When the host uses huge-pages, I get an a oops.
I did not delve into the patch details, but I think there is some mess with the indexes - see below:

On 6/19/14, 2:12 AM, mtosa...@redhat.com wrote:
+
+static bool direct_pin_sptes(struct kvm_vcpu *vcpu, gfn_t gfn)
+{
+       u64 *sptes[4];
+       int r, i, level;
+
+       r = get_sptep_hierarchy(vcpu, gfn << PAGE_SHIFT, sptes);
+       if (!r)
+               return false;
+
+       level = 5 - r;
+       if (!is_last_spte(*sptes[r-1], level))
should be *sptes[level-1]
+               return false;
+       if (!is_shadow_present_pte(*sptes[r-1]))
should be *sptes[level-1]
+               return false;
+
+       for (i = 0; i < r; i++) {
+               u64 *sptep = sptes[i];
should be sptes[3 - i];
+               struct kvm_mmu_page *sp = page_header(__pa(sptep));
+
+               sp->pinned = true;
+               set_bit(SPTE_PINNED_BIT, (unsigned long *)sptep);
+       }
+
+       return true;
+}


Regards,
Nadav
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to