Anthony Liguori
Tue, 28 Jul 2009 18:27:32 -0700
Izik Eidus wrote:
You mean: when we later call for other madvise calls, if it will remove the MADV_MERGEABLE from that memory? if yes, the answer is no, it should be still l left in the vma->vm_flags...
Excellent.
I'd suggest doing the following in osdep.h too: #if !defined(MADV_MERGABLE) #define MADV_MERGABLE MADV_NORMAL #endif To avoid #ifdefs in .c files.I tried to follow the way DONTFORK madvise is working... So you say, just to throw this thing into osdep.h instead of that c file?
Yes.I think the DONTFORK thing is a bit odd. Of course we have MADV_DONTFORK if we're running KVM. I'm not sure why that is there.
I also think that we could get away with getting rid of any checks for !sync_mmu() since that was introduced in 2.6.27.
Otherwise, you should technically avoid doing madvise() unless we have sync_mmu().
Regards, Anthony Liguori -- 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