[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: x86 ptep_get_and_clear question
On Thu, 15 Feb 2001, Jamie Lokier wrote:
> Ben LaHaise wrote:
> > x86 hardware goes back to the page tables whenever there is an attempt to
> > change the access it has to the pte. Ie, if it originally accessed the
> > page table for reading, it will go back to the page tables on write. I
> > believe most hardware that performs accessed/dirty bit updates in hardware
> > behaves the same way.
>
> I think the scenario in question is this:
>
> Processor 2 has recently done some writes, so the dirty bit is set in
> processor 2's TLB.
>
> Processor 1 clears the dirty bit atomically.
>
> Processor 2 does some more writes, and does not check the page table
> because the page is already dirty in its TLB.
>
> Result: The later writes on processor 2 do not mark the page dirty.
Yeah, but the tlb is flushed in those cases (look for flush_tlb_page in
try_to_swap_out).
-ben
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux.eu.org/Linux-MM/