summaryrefslogtreecommitdiff
path: root/src/southbridge/intel/i82801ax/i82801ax_early_lpc.c
diff options
context:
space:
mode:
authorStefan Reinauer <stepan@coresystems.de>2010-02-27 01:50:21 +0000
committerStefan Reinauer <stepan@openbios.org>2010-02-27 01:50:21 +0000
commit138be8315b63b0c8955159580d085e7621882b95 (patch)
treeaabbcab390ea1e522524ff7e98d11ac752a051b5 /src/southbridge/intel/i82801ax/i82801ax_early_lpc.c
parentbe07eb29bc087a97903f72c2253442c285ce5942 (diff)
downloadcoreboot-138be8315b63b0c8955159580d085e7621882b95.tar.xz
This does the following:
cd coreboot/src/southbridge svn mv i82801ca i82801cx svn mv i82801dbm i82801dx svn mv i82801er i82801ex svn copy i82801xx i82801bx svn mv i82801xx i82801ax Plus, fixing up the filenames in these directories and the romstage.c and Kconfig files of the mainboards using those drivers. Plus, switching the thomson ip1000 and rca rm4100 to the i82801dx driver. There's a lot more to be done, like - adding device IDs for the ICH3 and newer drivers that have been kept in i82801xx so far - drop the additional parts support from the ax and bx drivers. Signed-off-by: Stefan Reinauer <stepan@coresystems.de> Acked-by: Uwe Hermann <uwe@hermann-uwe.de> Acked-by: Joseph Smith <joe@settoplinux.org> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@5167 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/southbridge/intel/i82801ax/i82801ax_early_lpc.c')
-rw-r--r--src/southbridge/intel/i82801ax/i82801ax_early_lpc.c40
1 files changed, 40 insertions, 0 deletions
diff --git a/src/southbridge/intel/i82801ax/i82801ax_early_lpc.c b/src/southbridge/intel/i82801ax/i82801ax_early_lpc.c
new file mode 100644
index 0000000000..abcf9c60dc
--- /dev/null
+++ b/src/southbridge/intel/i82801ax/i82801ax_early_lpc.c
@@ -0,0 +1,40 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2008 Joseph Smith <joe@settoplinux.org>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+static void i82801ax_halt_tco_timer(void)
+{
+ device_t dev;
+ uint16_t halt_tco_timer;
+
+ /* Set the LPC device statically. */
+ dev = PCI_DEV(0x0, 0x1f, 0x0);
+
+ /* Temporarily set ACPI base address (I/O space). */
+ pci_write_config32(dev, PMBASE, (PMBASE_ADDR | 1));
+
+ /* Temporarily enable ACPI I/O. */
+ pci_write_config8(dev, ACPI_CNTL, 0x10);
+
+ /* Halt the TCO timer, preventing SMI and automatic reboot */
+ outw(inw(PMBASE_ADDR + TCOBASE + TCO1_CNT) | (1 << 11), PMBASE_ADDR + TCOBASE + TCO1_CNT);
+
+ /* Disable ACPI I/O. */
+ pci_write_config8(dev, ACPI_CNTL, 0x00);
+}