]> Joshua Wise's Git repositories - netwatch.git/blob - aseg/firstrun.c
put the stack in bss to save space on disk
[netwatch.git] / aseg / firstrun.c
1 #include <io.h>
2
3 void __firstrun_start() {
4 /*
5         puts("Current USB state is: ");
6         puthex(pci_read16(0, 31, 2, 0xC0));
7         puts(" ");
8         puthex(pci_read16(0, 31, 4, 0xC0));
9         puts("\n");
10         puts("Current SMI state is: ");
11         puthex(inl(0x830));
12         puts("\n");
13         puts("Current SMRAMC state is: ");
14         puthex(pci_read8(0, 0, 0, 0x70));
15         puts("\n");
16 */
17
18         /* Try really hard to shut up USB_LEGKEY. */
19         pci_write16(0, 31, 2, 0xC0, pci_read16(0, 31, 2, 0xC0));
20         pci_write16(0, 31, 2, 0xC0, 0);
21         pci_write16(0, 31, 4, 0xC0, pci_read16(0, 31, 4, 0xC0));
22         pci_write16(0, 31, 4, 0xC0, 0);
23
24         /* Turn on the SMIs we want */
25         outb(0x830, inb(0x830) | 0x41);
26 }
27
This page took 0.028518 seconds and 4 git commands to generate.