* How to make every page of a process in the page table present?
@ 2010-07-28 17:49 Gu, Zhongshu
2010-07-28 20:13 ` Michal Nazarewicz
2010-07-29 10:23 ` Glynn Clements
0 siblings, 2 replies; 3+ messages in thread
From: Gu, Zhongshu @ 2010-07-28 17:49 UTC (permalink / raw)
To: kernelnewbies, linux-c-programming
Hi all:
i compiled a static program using gcc on linux and run it under kvm. I
checked every page table entry of this process in guest memory and
found that some pages have been mapped and some ones are not. Is this
the feature of on-demand paging?
My question is whether there is a solution to make all the pte present
and mapped in the page table?
E.g. i fork a new process and load a new elf binary, how to make every
page mapped in the page table of this new process.
Thanks
--
Zhongshu
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: How to make every page of a process in the page table present?
2010-07-28 17:49 How to make every page of a process in the page table present? Gu, Zhongshu
@ 2010-07-28 20:13 ` Michal Nazarewicz
2010-07-29 10:23 ` Glynn Clements
1 sibling, 0 replies; 3+ messages in thread
From: Michal Nazarewicz @ 2010-07-28 20:13 UTC (permalink / raw)
To: Gu, Zhongshu; +Cc: kernelnewbies, linux-c-programming
"Gu, Zhongshu" <gzs715@gmail.com> writes:
> i compiled a static program using gcc on linux and run it under kvm. I
> checked every page table entry of this process in guest memory and
> found that some pages have been mapped and some ones are not. Is this
> the feature of on-demand paging?
> My question is whether there is a solution to make all the pte present
> and mapped in the page table?
> E.g. i fork a new process and load a new elf binary, how to make every
> page mapped in the page table of this new process.
Read a byte from each page?
Why do you need such a thing?
--
Best regards, _ _
.o. | Liege of Serenly Enlightened Majesty of o' \,=./ `o
..o | Computer Science, Michal "mina86" Nazarewicz (o o)
ooo +--<mina86-tlen.pl>--<jid:mina86-jabber.org>--ooO--(_)--Ooo--
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: How to make every page of a process in the page table present?
2010-07-28 17:49 How to make every page of a process in the page table present? Gu, Zhongshu
2010-07-28 20:13 ` Michal Nazarewicz
@ 2010-07-29 10:23 ` Glynn Clements
1 sibling, 0 replies; 3+ messages in thread
From: Glynn Clements @ 2010-07-29 10:23 UTC (permalink / raw)
To: Gu, Zhongshu; +Cc: kernelnewbies, linux-c-programming
Gu, Zhongshu wrote:
> i compiled a static program using gcc on linux and run it under kvm. I
> checked every page table entry of this process in guest memory and
> found that some pages have been mapped and some ones are not. Is this
> the feature of on-demand paging?
Yes.
> My question is whether there is a solution to make all the pte present
> and mapped in the page table?
> E.g. i fork a new process and load a new elf binary, how to make every
> page mapped in the page table of this new process.
mlockall().
--
Glynn Clements <glynn@gclements.plus.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-07-29 10:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-28 17:49 How to make every page of a process in the page table present? Gu, Zhongshu
2010-07-28 20:13 ` Michal Nazarewicz
2010-07-29 10:23 ` Glynn Clements
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).