Rev 9976 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 9976 | Rev 10002 | ||
---|---|---|---|
Line 3... | Line 3... | ||
3 | ;; Copyright (C) KolibriOS team 2004-2022. All rights reserved. ;; |
3 | ;; Copyright (C) KolibriOS team 2004-2022. All rights reserved. ;; |
4 | ;; Distributed under terms of the GNU General Public License. ;; |
4 | ;; Distributed under terms of the GNU General Public License. ;; |
5 | ;; ;; |
5 | ;; ;; |
6 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
6 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
Line 7... | Line 7... | ||
7 | 7 | ||
Line 8... | Line 8... | ||
8 | $Revision: 9976 $ |
8 | $Revision: 10002 $ |
9 | 9 | ||
10 | struct EXCEPT_STACK |
10 | struct EXCEPT_STACK |
11 | RegEIP dd ? |
11 | RegEIP dd ? |
Line 112... | Line 112... | ||
112 | pf_err_code dd ? |
112 | pf_err_code dd ? |
113 | endg |
113 | endg |
Line 114... | Line 114... | ||
114 | 114 | ||
115 | page_fault_exc: ; foolproof: selectors are clobbered ... |
115 | page_fault_exc: ; foolproof: selectors are clobbered ... |
- | 116 | pop [ss:pf_err_code] ; actually, until the next #PF |
|
- | 117 | ||
- | 118 | cmp edi, CONTROL_EXCEPTION ; equ 'EXPT' |
|
- | 119 | jne .no_ctrl_exc |
|
- | 120 | bt dword [esp], 31 |
|
- | 121 | jc .setret |
|
- | 122 | test esi, esi |
|
- | 123 | jl .no_ctrl_exc |
|
- | 124 | .setret: |
|
- | 125 | mov [esp], esi |
|
- | 126 | iret |
|
- | 127 | ||
116 | pop [ss:pf_err_code] ; actually, until the next #PF |
128 | .no_ctrl_exc: |
117 | save_ring3_context |
129 | save_ring3_context |
Line 118... | Line 130... | ||
118 | mov bl, 14 |
130 | mov bl, 14 |
119 | 131 | ||
Line 209... | Line 221... | ||
209 | sub ecx, [reg_esp3] |
221 | sub ecx, [reg_esp3] |
210 | jg .nostack |
222 | jg .nostack |
211 | add ecx, 1000h |
223 | add ecx, 1000h |
212 | jl .nostack |
224 | jl .nostack |
213 | .ex_stack: |
225 | .ex_stack: |
214 | xor ecx, ecx |
- | |
215 | mov ecx, [ecx+APP_HEADER_01_.except_stack_top] |
226 | mov ecx, [esi+APPDATA.exc_reserve_stack] |
216 | test ecx, ecx |
227 | test ecx, ecx |
217 | jle .nostack |
228 | jle .nostack |
218 | xchg edi, eax |
229 | xchg edi, eax |
219 | sub ecx, sizeof.EXCEPT_STACK |
230 | sub ecx, sizeof.EXCEPT_STACK |
220 | push ebx |
231 | push ebx |