--- busybox-1.11.3/init/init.c.before	2011-05-13 11:36:20.331400412 +0100
+++ busybox-1.11.3/init/init.c	2011-05-13 11:51:20.915537382 +0100
@@ -647,14 +647,18 @@ static void ensure_all_unmounted(void)
 	message(L_CONSOLE, "All filesystems are now unmounted");
 }
 
+#define POWERDOWN_DEVICE "/dev/ttyS1"
+#define POWERDOWN_COMMAND "\nPOWER OFF\n"
+
 static void halt_reboot_pwoff(int sig)
 {
 	const char *m;
 	int rb;
+	int power_fd = -1;
 
 	kill_all_processes();
-	ensure_all_unmounted();
 
+	/* We must open the device before we unmount /dev */
 	m = "halt";
 	rb = RB_HALT_SYSTEM;
 	if (sig == SIGTERM) {
@@ -663,8 +667,17 @@ static void halt_reboot_pwoff(int sig)
 	} else if (sig == SIGUSR2) {
 		m = "poweroff";
 		rb = RB_POWER_OFF;
+		power_fd = device_open(POWERDOWN_DEVICE, O_WRONLY | O_NOCTTY);
+		if (power_fd < 0)
+			bb_error_msg("failed to open power control device: %d", errno);
 	}
+
+	ensure_all_unmounted();
+
 	message(L_CONSOLE | L_LOG, "Requesting system %s", m);
+	if (power_fd >= 0)
+		full_write(power_fd, POWERDOWN_COMMAND, sizeof(POWERDOWN_COMMAND)-1);
+
 	/* allow time for last message to reach serial console */
 	sleep(2);
 	init_reboot(rb);
