aboutsummaryrefslogtreecommitdiff
path: root/dummy_payload/dummy_entry.S
blob: 46c0b7fcaf6391a2c7e0b340cb22277a150e3b94 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include "mcall.h"

  .section ".text.init"
  .globl _start
_start:
  la s0, str
1:
  lbu a0, (s0)
  beqz a0, 1f
  li a7, MCALL_CONSOLE_PUTCHAR
  ecall
  add s0, s0, 1
  j 1b

1:
  li a7, MCALL_SHUTDOWN
  ecall

  .data
str:
  .asciz "This is bbl's dummy_payload.  To boot a real kernel, reconfigure\n\
bbl with the flag --with-payload=PATH, then rebuild bbl.\n"