]> Joshua Wise's Git repositories - netwatch.git/commitdiff
Merge joshua@nyus.joshuawise.com:/storage/git/netwatch
authorroot <root@moose.intro.cs.cmu.edu>
Mon, 6 Oct 2008 13:43:10 +0000 (09:43 -0400)
committerroot <root@moose.intro.cs.cmu.edu>
Mon, 6 Oct 2008 13:43:10 +0000 (09:43 -0400)
net/net.c

index 46ea9cd75bb9d1ab345eccaebbede9bd20028064..eac5d0e0b4cb0e81285b646be2098340a9cf8c40 100644 (file)
--- a/net/net.c
+++ b/net/net.c
@@ -44,10 +44,14 @@ void handle_command(packet_t * p)
 
        outputf("NIC: Command: 0x%x, %d bytes", p->command, dl);
 
-       if (p->command == 0x42)
-       {
+       switch (p->command) {
+       case 0x42:
                for (i = 0; i < dl; i++)
                        kbd_inject_key(p->data[i]);
+               break;
+       case 0xFE:
+               outb(0xCF9, 0x4);       /* Reboot */
+               break;
        }
 }
 
This page took 0.023893 seconds and 4 git commands to generate.