Page 1 of 1

[Solved] Questions:Paging

Posted: Mon Nov 08, 2010 2:38 pm
by LegendDairy
Hi,

I was reading about paging (the tutorial) but now I still have some questions.

When they explained attributes: present, dirty, R/W... They didn't very well explained every attribute.

-Now I was wondering what's the difference between available and present? Does present mean there is a an adress in a phisical memory and available that it is not used by an other program? But then why do they set the attributes in the tutorial to 011(supervisor,R/W,present) and not to 111 00 0 0 00 0 1 1 (available,supervisor,R/W,present)?

-And what does "dirty" mean?

Ty.

Re: Questions:Paging

Posted: Mon Nov 08, 2010 2:48 pm
by Artlav
Legendmythe wrote:-Now I was wondering what's the difference between available and present?
Available as in availale for the OS to use as it pleases. That article mentions it, btw.
Legendmythe wrote:-And what does "dirty" mean?
In short, means that the page have been written to.

More verbose explanations can be found in the OSDev wiki:
http://wiki.osdev.org/Paging

Re: Questions:Paging

Posted: Mon Nov 08, 2010 3:05 pm
by LegendDairy
Artlav wrote:
Legendmythe wrote:-Now I was wondering what's the difference between available and present?
Available as in availale for the OS to use as it pleases. That article mentions it, btw.
Legendmythe wrote:-And what does "dirty" mean?
In short, means that the page have been written to.

More verbose explanations can be found in the OSDev wiki:
http://wiki.osdev.org/Paging
Oke thanks but i got 1 last question so if I would enable multitasking and in the kernel I say these pages are your and are RW and in the first program I say the kernel pages are only R but these pages you can use. Would that prevent them from messing around in the wrong memory or would it just not work at all?

Re: Questions:Paging

Posted: Tue Nov 09, 2010 1:07 am
by rdos
Legendmythe wrote:Oke thanks but i got 1 last question so if I would enable multitasking and in the kernel I say these pages are your and are RW and in the first program I say the kernel pages are only R but these pages you can use. Would that prevent them from messing around in the wrong memory or would it just not work at all?
The pagefault handler. It is invoked when code references a page that is not present, or if an R/W (or user/kernel) violation is made. Read the section in the Intel manual about it. It covers it in-depth.

Re: Questions:Paging

Posted: Tue Nov 09, 2010 11:09 am
by LegendDairy
rdos wrote:
Legendmythe wrote:Oke thanks but i got 1 last question so if I would enable multitasking and in the kernel I say these pages are your and are RW and in the first program I say the kernel pages are only R but these pages you can use. Would that prevent them from messing around in the wrong memory or would it just not work at all?
The pagefault handler. It is invoked when code references a page that is not present, or if an R/W (or user/kernel) violation is made. Read the section in the Intel manual about it. It covers it in-depth.
K ty.