On Tue, 23 Sep 2008, Benjamin Herrenschmidt wrote:
The powerpc bug whereof you write appears to have been there since ...
linux-2.4.0 or earlier:
entry = ptep_get_and_clear(pte);
set_pte(pte, pte_modify(entry, newprot));
But perhaps powerpc was slightly different back in those days.
It sounds to me like a bug in your current ptep_get_and_clear(),
not checking if already hashed?
Then I hope he will probably send Linus the fix.
Though what we already have falls somewhat short of perfection,
I've much more enthusiasm for fixing its bugs, than for any fancy
redesign introducing its own bugs. Others have more stamina!
Hugh
--