aboutsummaryrefslogtreecommitdiff
path: root/setup.c
diff options
context:
space:
mode:
Diffstat (limited to 'setup.c')
-rw-r--r--setup.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/setup.c b/setup.c
index 3542043..be71547 100644
--- a/setup.c
+++ b/setup.c
@@ -3,17 +3,28 @@
#include "demo_functionality.h"
#include "paging.h"
-void setup(void)
+void setup(uint32_t r0, uint32_t machine_type,
+ uint32_t atags)
{
uart_init();
// When we attach screen session after loading kernel with socat
// we miss kernel's greeting... So we'll make the kernel wait for
// one char we're going to send from within screen
- getchar();
+ //getchar();
puts("Hello, kernel World!");
+ prints("ARM machine type: 0x"); printhext(machine_type); puts("");
+
+ // value 3 introduced by stage1 code, means no atags was found
+ if (r0 == 3)
+ puts("No ATAGS was found!");
+ else
+ {
+ prints("ATAGS copied to 0x"); printhex(atags); puts("");
+ }
+
// prints some info
demo_paging_support();