"David S. Miller" wrote:
>
> From: Ingo Molnar <mingo@elte.hu>
> Date: Mon, 26 Nov 2001 22:09:02 +0100 (CET)
>
> something like this:
>
> - #define SetPageReferenced(page) set_bit(PG_referenced, &(page)->flags)
> + #define SetPageReferenced(page) \
> + if (!test_bit(PG_referenced), &(page)->flags) \
> + set_bit(PG_referenced, &(page)->flags)
>
> On some platforms all the {test_,}{clear,change,set}_bit() ops give
> you this cache behavior. How hard would it be to make ix86 act
> similarly?
It would be nice to have a full complement of non-atomic
bitops. At present we have __set_bit, but no __clear_bit, etc.
So we often do buslocked RMW's in places where it's not needed.
-
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Fri Nov 30 2001 - 21:00:23 EST