Also, make shutdown_reboot() actually behave that way, by trying to reboot
forever instead of giving up after some number of tries.
void
shutdown_reboot (void)
{
- int i;
-
printf ("Rebooting...\n");
/* See [kbd] for details on how to program the keyboard
* controller. */
- for (i = 0; i < 100; i++)
+ for (;;)
{
- int j;
+ int i;
/* Poll keyboard controller's status byte until
* 'input buffer empty' is reported. */
- for (j = 0; j < 0x10000; j++)
+ for (i = 0; i < 0x10000; i++)
{
if ((inb (CONTROL_REG) & 0x02) == 0)
break;
#ifndef DEVICES_SHUTDOWN_H
#define DEVICES_SHUTDOWN_H
-void shutdown_reboot (void);
-void shutdown_power_off (void);
+#include <debug.h>
+
+void shutdown_reboot (void) NO_RETURN;
+void shutdown_power_off (void) NO_RETURN;
#endif /* devices/shutdown.h */