1/*
2 * Reset a Jazz machine.
3 */
4#include <linux/sched.h>
5#include <asm/jazz.h>
6#include <asm/io.h>
7#include <asm/system.h>
8#include <asm/reboot.h>
9#include <asm/delay.h>
10#include <asm/keyboard.h>
11
12static inline void kb_wait(void)
13{
14	unsigned long start = jiffies;
15
16	do {
17		if (! (kbd_read_status() & 0x02))
18			return;
19	} while (jiffies - start < 50);
20}
21
22void jazz_machine_restart(char *command)
23{
24    while (1) {
25	kb_wait ();
26	kbd_write_command (0xd1);
27	kb_wait ();
28	kbd_write_output (0x00);
29    }
30}
31
32void jazz_machine_halt(void)
33{
34}
35
36void jazz_machine_power_off(void)
37{
38	/* Jazz machines don't have a software power switch */
39}
40