9os

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 2815e0853b7d3938a0776b3edb9834ea27c664c1
parent 03afa40b9b8eae21c7fd5c1efe4342bee85717d1
Author: Dimitris Papastamos <dimitris.papastamos@arm.com>
Date:   Wed, 17 Oct 2018 14:14:42 +0100

[amd64] Fix halt() and add dopanic()

Change-Id: I63594356f553eae76ba2e2dc32f91909589e1f46
Signed-off-by: Dimitris Papastamos <dimitris.papastamos@arm.com>

Diffstat:
March/amd64/arch.c | 13+++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/arch/amd64/arch.c b/arch/amd64/arch.c @@ -1,10 +1,12 @@ +#include <stdio.h> +#include <stdlib.h> + #include <rcode.h> void halt(void) { - for (;;) - ; + abort(); } void @@ -12,3 +14,10 @@ swtch(struct trapframe *fp) { panic("swtch() not implemented"); } + +void +dopanic(void) +{ + printf("%s\n", bss->errstr); + halt(); +}