- Update abuild.sh so it will rebuild successfull builds
[coreboot.git] / src / mainboard / via / epia-m / mainboard.c
1 #include <console/console.h>
2 #include <device/device.h>
3 #include <device/pci.h>
4 #include <device/pci_ids.h>
5 #include <device/pci_ops.h>
6 #include <arch/io.h>
7 #include "chip.h"
8
9 void vga_enable_console();
10
11
12 static void vga_fixup(void) {
13         // we do this right here because:
14         // - all the hardware is working, and some VGA bioses seem to need
15         //   that
16         // - we need page 0 below for linuxbios tables.
17
18         printk_debug("INSTALL REAL-MODE IDT\n");
19         setup_realmode_idt();
20         printk_debug("DO THE VGA BIOS\n");
21         do_vgabios();
22         post_code(0x93);
23         vga_enable_console();
24
25
26 }
27  
28 static void write_protect_vgabios(void)
29 {
30         device_t dev;
31  
32         printk_info("write_protect_vgabios\n");
33         dev = dev_find_device(PCI_VENDOR_ID_VIA, 0x3123, 0);
34         if(dev)
35                 pci_write_config8(dev, 0x61, 0xaa);
36 }
37
38 struct chip_operations mainboard_via_epia_m_ops = {
39         CHIP_NAME("VIA EPIA-M mainboard ")
40 };
41