aboutsummaryrefslogtreecommitdiff
path: root/src/arm/PL1/kernel/interrupts.c
diff options
context:
space:
mode:
authorvetch <vetch97@gmail.com>2020-01-18 19:13:17 +0100
committervetch <vetch97@gmail.com>2020-01-18 19:13:17 +0100
commitf540834c09905f848139371005d077577eabdd57 (patch)
tree7420a43e63be72a0c860f325ea65aed603aee65f /src/arm/PL1/kernel/interrupts.c
parentdfd6177fea6769a0e7dcd2d2205e5a795bba3553 (diff)
parentf5c83b679ced1d1900613e049c31ad56cf903c1e (diff)
downloadrpi-MMU-example-f540834c09905f848139371005d077577eabdd57.tar.gz
rpi-MMU-example-f540834c09905f848139371005d077577eabdd57.zip
Merge branch 'bob' of https://repo.or.cz/RPi-MMU-example into alice
Diffstat (limited to 'src/arm/PL1/kernel/interrupts.c')
-rw-r--r--src/arm/PL1/kernel/interrupts.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/src/arm/PL1/kernel/interrupts.c b/src/arm/PL1/kernel/interrupts.c
index 5695e6f..6f61615 100644
--- a/src/arm/PL1/kernel/interrupts.c
+++ b/src/arm/PL1/kernel/interrupts.c
@@ -4,17 +4,6 @@
#include "armclock.h"
#include "scheduler.h"
-// defined in setup.c
-void __attribute__((noreturn)) setup(void);
-
-// from what I've heard, reset is never used on the Pi;
-// in our case it should run once - when stage1 of the kernel
-// jumps to stage2
-void reset_handler(void)
-{
- setup();
-}
-
void undefined_instruction_vector(void)
{
error("Undefined instruction occured");
@@ -85,6 +74,7 @@ void irq_handler(uint32_t regs[14])
if (read_SPSR().fields.PSR_MODE_4_0 != MODE_USER)
{
+ // TODO set supervisor mode's stack pointer
write_SPSR(PL1_PSR);
asm volatile("mov lr, %0\n\r"
"subs pc, lr, #0" ::