Re: Question on pte bits

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 6 Dec 2002, Martin Maletinsky wrote:

> After getting the corresponding page table entry, the function makes a
> check, which I don't quite understand - if write access is requested to
> the page, it not only checks the write permission in the page table
> entry (with pte_write()), but also the dirty bit (with pte_dirty()). Why
> does a page need to be dirty in the case write == 1 (see line 444 in the
> code excerpt below?

If write == 1, then somebody wants to write to the page NOW.
In that case it's more efficient to just set the dirty bit
than to take a trap later on; remember that many CPUs can't
keep track of the dirty bit in hardware but trap to the OS.

Rik
-- 
A: No.
Q: Should I include quotations after my reply?
http://www.surriel.com/		http://guru.conectiva.com/
--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux