David Gibson <dwg@xxxxxxxxxxx> writes: > On Fri, May 03, 2013 at 06:19:03PM +1000, Benjamin Herrenschmidt wrote: >> On Fri, 2013-05-03 at 14:52 +1000, David Gibson wrote: >> > Here, specifically, the fact that PAGE_BUSY is in PAGE_THP_HPTEFLAGS >> > is likely to be bad. If the page is busy, it's in the middle of >> > update so can't stably be considered the same as anything. >> >> _PAGE_BUSY is more like a read lock. It means it's being hashed, so what >> is not stable is _PAGE_HASHPTE, slot index, _ACCESSED and _DIRTY. The >> rest is stable and usually is what pmd_same looks at (though I have a >> small doubt vs. _ACCESSED and _DIRTY but at least x86 doesn't care since >> they are updated by HW). > > Ok. It still seems very odd to me that _PAGE_BUSY would be in the THP > version of _PAGE_HASHPTE, but not the normal one. > 64-4k definition: /* PTE flags to conserve for HPTE identification */ #define _PAGE_HPTEFLAGS (_PAGE_BUSY | _PAGE_HASHPTE | \ _PAGE_SECONDARY | _PAGE_GROUP_IX) 64-64K definition: /* PTE flags to conserve for HPTE identification */ #define _PAGE_HPTEFLAGS (_PAGE_BUSY | _PAGE_HASHPTE | _PAGE_COMBO) BTW I have dropped that change in my current patch. I dropped the usage of _PAGE_COMBO and instead started using _PAGE_4K_PFN for identifying THP.That enabled me to use _PAGE_HPTEFLAGS as it is. -aneesh -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>