aboutsummaryrefslogtreecommitdiff
path: root/src/exceptions
diff options
context:
space:
mode:
authorChristian Cunningham <cc@localhost>2022-02-13 13:22:43 -0700
committerChristian Cunningham <cc@localhost>2022-02-13 13:23:01 -0700
commit921398936d989aef06be8d869d9162e3d9b294b3 (patch)
tree62e1c575a2df812bfd2c5a7edaf13ed0528d1f4d /src/exceptions
parent5643e3587507f3351a2ebeb44a5d95d13470741d (diff)
Output the count of the task stacks
Diffstat (limited to 'src/exceptions')
-rw-r--r--src/exceptions/svc.S4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/exceptions/svc.S b/src/exceptions/svc.S
index bebc417..dc1a351 100644
--- a/src/exceptions/svc.S
+++ b/src/exceptions/svc.S
@@ -45,6 +45,10 @@ svc_000003: // Clean task stack
// Free the thread after freeing the stack
mov r0, r2
bl kfree
+ ldr r3, =sched_stack_count
+ ldr r2, [r3]
+ sub r2, #1
+ str r2, [r3]
b svc_exit
svc_000004: // Lock Mutex (usr_r0 = struct Mutex*)
ldr r3, =scheduler