Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added a timerhalt() function #176

Open
wants to merge 1 commit into
base: riscv
Choose a base branch
from
Open

Commits on Mar 31, 2023

  1. added a timerhalt() function

    The virt QEMU board integrates a "test finisher" device.
    Writing FINISHER_PASS(=0x5555) to its address which
    is VIRT_TEST(=0x100000), will halt virt machine.
    
    Since this should be done in machine mode, a new flag
    is set by timerhalt() in supervisor mode. Later timervec()
    will check this flag, which is at the end of timer scratch
    area. If the halt flag is not zero, it will branch to halt.
    
    It can be used to halt when kernel panics in printf.c
    It can be triggered in user mode by killing init process,
    using the following command at shell:
    kill 1
    meighti committed Mar 31, 2023
    Configuration menu
    Copy the full SHA
    704e2d4 View commit details
    Browse the repository at this point in the history