summaryrefslogtreecommitdiff
path: root/src/mainboard/amd/serenade/mainboard.c
diff options
context:
space:
mode:
authorLi-Ta Lo <ollie@lanl.gov>2004-06-15 23:37:34 +0000
committerLi-Ta Lo <ollie@lanl.gov>2004-06-15 23:37:34 +0000
commit6ae2ac37396e555041c382bef9d6ee060d2df542 (patch)
treef583bc51c0365bac827ef6575e995f997a78e8d8 /src/mainboard/amd/serenade/mainboard.c
parent9b1a2ff96f4cc6129ba9bfab227b0dbe4af30593 (diff)
add support for AMD Serenade mainboard, why we have phantom devices here?
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@1606 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/mainboard/amd/serenade/mainboard.c')
-rw-r--r--src/mainboard/amd/serenade/mainboard.c45
1 files changed, 45 insertions, 0 deletions
diff --git a/src/mainboard/amd/serenade/mainboard.c b/src/mainboard/amd/serenade/mainboard.c
new file mode 100644
index 0000000000..27146e79b0
--- /dev/null
+++ b/src/mainboard/amd/serenade/mainboard.c
@@ -0,0 +1,45 @@
+#include <console/console.h>
+#include <device/device.h>
+#include <device/pci.h>
+#include <device/pci_ids.h>
+#include <device/pci_ops.h>
+
+#include <arch/io.h>
+#include <device/chip.h>
+#include "../../../northbridge/amd/amdk8/northbridge.h"
+#include "chip.h"
+
+unsigned long initial_apicid[CONFIG_MAX_CPUS] =
+{
+ 0, 1,
+};
+
+static struct device_operations mainboard_operations = {
+ .read_resources = root_dev_read_resources,
+ .set_resources = root_dev_set_resources,
+ .enable_resources = enable_childrens_resources,
+ .init = 0,
+ .scan_bus = amdk8_scan_root_bus,
+ .enable = 0,
+};
+
+static void enumerate(struct chip *chip)
+{
+ struct chip *child;
+
+ if (chip->control && chip->control->name) {
+ printk_debug("Enumerating: %s\n", chip->control->name);
+ }
+
+ dev_root.ops = &mainboard_operations;
+ chip->dev = &dev_root;
+ chip->bus = 0;
+ for (child = chip->children; child; child = child->next) {
+ child->bus = &dev_root.link[0];
+ }
+}
+
+struct chip_control mainboard_amd_serenade_control = {
+ .enumerate = enumerate,
+ .name = "AMD Serenade mainboard ",
+};