/*
 * Die while blinking LEDs
 */

#include "fw.h"
#include "io.h"

void _die(void)
{
    unsigned int led = 2;

    while (1) {
	set_leds(led);
	led ^= 7;
	udelay(250000);
    }
}

/* We never exit, so don't bother carrying a bunch of crap with it */
#pragma GCC diagnostic ignored "-Wattribute-alias"
void _exit(int) __attribute__((alias("_die")));
void exit(int) __attribute__((alias("_die")));
void _irq(void) __attribute__((weak,alias("_die")));
