summaryrefslogtreecommitdiff
path: root/src/southbridge/amd/amd8111/amd8111.c
diff options
context:
space:
mode:
authorYinghai Lu <yinghailu@gmail.com>2004-10-21 01:52:21 +0000
committerYinghai Lu <yinghailu@gmail.com>2004-10-21 01:52:21 +0000
commitf19e2c766ac602f51882cf3c1c28c90d12f21c8d (patch)
tree40914b9072597944a823f9eaf51c69e0d2093112 /src/southbridge/amd/amd8111/amd8111.c
parent6014983babe46d025cdcfb76bc20ff009eb27817 (diff)
downloadcoreboot-f19e2c766ac602f51882cf3c1c28c90d12f21c8d.tar.xz
better support enable_dev for amd8111
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@1695 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/southbridge/amd/amd8111/amd8111.c')
-rw-r--r--src/southbridge/amd/amd8111/amd8111.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/southbridge/amd/amd8111/amd8111.c b/src/southbridge/amd/amd8111/amd8111.c
index afb02f1fec..a9b132cdaf 100644
--- a/src/southbridge/amd/amd8111/amd8111.c
+++ b/src/southbridge/amd/amd8111/amd8111.c
@@ -9,9 +9,11 @@ void amd8111_enable(device_t dev)
device_t lpc_dev;
device_t bus_dev;
unsigned index;
+ uint32_t dword;
uint16_t reg_old, reg;
uint8_t byte;
+
/* See if we are on the behind the amd8111 pci bridge */
bus_dev = dev->bus->dev;
if ((bus_dev->vendor == PCI_VENDOR_ID_AMD) &&
@@ -39,8 +41,13 @@ void amd8111_enable(device_t dev)
}
}
- if ((dev->vendor == PCI_VENDOR_ID_AMD) &&
- (dev->device == PCI_DEVICE_ID_AMD_8111_USB2)) {
+ /* Now read the vendor and device id */
+ dword= pci_read_config32(dev, PCI_VENDOR_ID);
+#if 0
+ printk_debug(" %s dev->vendor= %04x, dev->device= %04x, id = %08x\n", dev_path(dev), dev->vendor, dev->device, dword);
+#endif
+
+ if (dword == (PCI_VENDOR_ID_AMD | (PCI_DEVICE_ID_AMD_8111_USB2 << 16))) {
if(!dev->enabled) {
byte = pci_read_config8(lpc_dev, 0x47);
byte |= (1<<7);