Re: how to get physical memory address from virtual memory address
- From: Tim Roberts <timr@xxxxxxxxx>
- Date: Fri, 01 Sep 2006 05:22:54 GMT
"David Schwartz" <davids@xxxxxxxxxxxxx> wrote:
Hari wrote:
Hi ,
I am using Linux 2.4.20 Kernel. I am runing an application which will
malloc and returns a virtual memory address. I need to get the physical
memory address for that virtual memory address. How can I get that?
There isn't one. You haven't allocated any physical memory, so the
kernel doesn't give you any.
What?? This is entirely incorrect. EVERY valid virtual address has an
associated physical address. In the case of malloc-ed memory, that
physical address will be in physical memory.
Addressing the OP, while you are in user mode, the physical address can
change at any time. The only reliable way to get the physical address is
within a kernel driver.
--
- Tim Roberts, timr@xxxxxxxxx
Providenza & Boekelheide, Inc.
.
- Follow-Ups:
- Re: how to get physical memory address from virtual memory address
- From: Kaz Kylheku
- Re: how to get physical memory address from virtual memory address
- From: David Schwartz
- Re: how to get physical memory address from virtual memory address
- From: David Schwartz
- Re: how to get physical memory address from virtual memory address
- From: Nikolaos D. Bougalis
- Re: how to get physical memory address from virtual memory address
- From: Joe Pfeiffer
- Re: how to get physical memory address from virtual memory address
- From: Lew Pitcher
- Re: how to get physical memory address from virtual memory address
- From: Douglas O'Neal
- Re: how to get physical memory address from virtual memory address
- From: Jiri Kosina
- Re: how to get physical memory address from virtual memory address
- From: Tauno Voipio
- Re: how to get physical memory address from virtual memory address
- Prev by Date: Re: block size more than 4096 in ext2/3
- Next by Date: Re: how to get physical memory address from virtual memory address
- Previous by thread: Re: block size more than 4096 in ext2/3
- Next by thread: Re: how to get physical memory address from virtual memory address
- Index(es):
Relevant Pages
|