Stack fault handling
Posted: Sat May 01, 2004 6:01 am
Hi,
I'm a bit confused about stack faults and their handling; I have setup kernel VM with its own heap and stack. I initially decided that I'd start with a single page for the stack and as the need arises add more to it. This, I thought, should be done by catching faults. But what i don't understand is, what is the kind of fault that occurs ? Is it page fault when esp goes beyond the page or is it stack fault. And be it any of the two, how can I handle them ? I mean the interrupt needs to save the values into a stack right ?.. but the stack just faulted :-\. Is this what is referred to as a double fault ? Are there any ways to handle it, or better any method to grow stack as needed ?
Thanks
I'm a bit confused about stack faults and their handling; I have setup kernel VM with its own heap and stack. I initially decided that I'd start with a single page for the stack and as the need arises add more to it. This, I thought, should be done by catching faults. But what i don't understand is, what is the kind of fault that occurs ? Is it page fault when esp goes beyond the page or is it stack fault. And be it any of the two, how can I handle them ? I mean the interrupt needs to save the values into a stack right ?.. but the stack just faulted :-\. Is this what is referred to as a double fault ? Are there any ways to handle it, or better any method to grow stack as needed ?
Thanks