2018-07-20 15:41:58 +02:00
|
|
|
#pragma once
|
2018-08-06 21:00:58 +02:00
|
|
|
#include "stdarg.h"
|
2021-10-07 23:11:17 +02:00
|
|
|
#include "cpu_context.h"
|
2018-07-20 15:41:58 +02:00
|
|
|
|
2020-04-22 16:52:54 +02:00
|
|
|
// c.f. intel software-developer-vol-1 6.4.1
|
|
|
|
struct interrupt_frame {
|
2021-10-07 23:11:17 +02:00
|
|
|
/* Stacked by the CPU */
|
2020-04-27 00:14:37 +02:00
|
|
|
uint32_t eip;
|
|
|
|
uint32_t cs;
|
|
|
|
uint32_t eflags;
|
2021-10-07 21:53:25 +02:00
|
|
|
} __attribute__((packed));
|
2020-04-22 16:52:54 +02:00
|
|
|
|
|
|
|
// IRQ
|
2020-04-23 00:49:09 +02:00
|
|
|
void pit_handler(struct interrupt_frame *frame);
|