Alan Cox writes:
> Use pte_clear. That is the only valid way to do it. Im not sure I follow why
> you cant use pte_clear in this case
pte_clear has other side effects on ARM, since we don't have enough bits in the
page tables to store all the bits that Linux needs. In fact, there are NO bits
in the page table entries which are not CPU defined.
Therefore, we have to store the CPU's version of the page pointers at ptep[0]
through to ptep[1023], and the kernel's version with all the associated flags
in ptep[-1024] through to ptep[-1].
pte_alloc and friends are aware of this because they are allocating page tables,
and pte_clear is supposed to be used on page tables.
SHM uses it on *pages* allocated from __get_free_page() and kmalloc, which are
not page tables.
Therefore, really SHM's use of pte_clear is a hack in the extreme, breaking the
architecture independence of the page table macros.
_____
|_____| ------------------------------------------------- ---+---+-
| | Russell King rmk@arm.linux.org.uk --- ---
| | | | http://www.arm.linux.org.uk/~rmk/aboutme.html / / |
| +-+-+ --- -+-
/ | THE developer of ARM Linux |+| /|\
/ | | | --- |
+-+-+ ------------------------------------------------- /\\\ |
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Wed May 31 2000 - 21:00:14 EST