linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* pgd/pmd/pte and x86 kernel virtual addresses
@ 2000-08-24 23:21 Timur Tabi
  2000-08-24 23:43 ` Benjamin C.R. LaHaise
  0 siblings, 1 reply; 10+ messages in thread
From: Timur Tabi @ 2000-08-24 23:21 UTC (permalink / raw)
  To: Linux MM mailing list

On x86, when running the kernel, all memory is mapped with a simple offset. 
The virtual address is merely an offset from the physical address.

Does that mean that the pgd/pmd/pte tables are still used?  Basically, what I'm
trying to do is find the pte for a given physical page.  That is, I'm looking
for a function that looks like this:

pte_t *find_pte(mem_map_t *mm);

Given a pointer to a mem_map_t, it returns the pointer to the pte_t for that
physical page.  Is there such a function?  I've found things like this:

#define pte_offset(dir, address) ((pte_t *) pmd_page(*(dir)) + \
			__pte_offset(address))

but what value do I use for "dir"?




--
Timur Tabi - ttabi@interactivesi.com
Interactive Silicon - http://www.interactivesi.com

When replying to a mailing-list message, please don't cc: me, because then I'll just get two copies of the same message.
--
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/

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2000-08-29 15:31 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-08-24 23:21 pgd/pmd/pte and x86 kernel virtual addresses Timur Tabi
2000-08-24 23:43 ` Benjamin C.R. LaHaise
2000-08-25 15:25   ` Timur Tabi
2000-08-25 16:45     ` Benjamin C.R. LaHaise
2000-08-25 16:40       ` Timur Tabi
2000-08-25 16:59         ` Benjamin C.R. LaHaise
2000-08-25 18:46           ` Timur Tabi
2000-08-26  3:59             ` Benjamin C.R. LaHaise
2000-08-28 23:09             ` Stephen C. Tweedie
2000-08-29 15:31               ` Timur Tabi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox