1
0
mirror of https://github.com/0xAX/linux-insides.git synced 2024-12-23 07:08:11 +00:00

Update interrupts-5.md

This commit is contained in:
0xAX 2015-10-25 18:39:39 +06:00
parent 474ef13229
commit 349aa9792b

View File

@ -299,7 +299,7 @@ static const char str[] = "double fault";
struct task_struct *tsk = current; struct task_struct *tsk = current;
``` ```
The handler of the double fault exception splitted on two parts. The first part is the check which checks that a fault is a `non-IST` fault on the `espfix64` stack. Actually the `iret` instruction restores only the bottom `16` bits when returning to a `16` bit segment. The `espfix` feature solves this problem. So if the `non-IST` fault on the espfix64 stack we modify the stack to make it look like `General Protection Fault`: The handler of the double fault exception split on two parts. The first part is the check which checks that a fault is a `non-IST` fault on the `espfix64` stack. Actually the `iret` instruction restores only the bottom `16` bits when returning to a `16` bit segment. The `espfix` feature solves this problem. So if the `non-IST` fault on the espfix64 stack we modify the stack to make it look like `General Protection Fault`:
```C ```C
struct pt_regs *normal_regs = task_pt_regs(current); struct pt_regs *normal_regs = task_pt_regs(current);