summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYinghai Lu <yinghailu@gmail.com>2005-01-19 01:21:05 +0000
committerYinghai Lu <yinghailu@gmail.com>2005-01-19 01:21:05 +0000
commit26b2922f1cf61a5076ea81fcd764cce94fc5900f (patch)
treef34b142a9ce65949df274d089172772171734843
parentcd915e9672ea555fb1602b2d2d1ec85452fc7efd (diff)
downloadcoreboot-26b2922f1cf61a5076ea81fcd764cce94fc5900f.tar.xz
linkb_to_host
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@1885 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
-rw-r--r--src/devices/hypertransport.c2
-rw-r--r--src/northbridge/amd/amdk8/incoherent_ht.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/devices/hypertransport.c b/src/devices/hypertransport.c
index a75550cdae..411e7542c0 100644
--- a/src/devices/hypertransport.c
+++ b/src/devices/hypertransport.c
@@ -71,7 +71,7 @@ static int ht_setup_link(struct prev_link *prev, device_t dev, unsigned pos)
/* Set the hypertransport link width and frequency */
reset_needed = 0;
- linkb_to_host = pci_read_config16(dev, pos + PCI_CAP_FLAGS) & (1<<10);
+ linkb_to_host = (pci_read_config16(dev, pos + PCI_CAP_FLAGS) >> 10) & 1;
/* Read the capabilities */
present_freq_cap = ht_read_freq_cap(dev, pos + (linkb_to_host ? PCI_HT_CAP_SLAVE_FREQ_CAP1: PCI_HT_CAP_SLAVE_FREQ_CAP0));
diff --git a/src/northbridge/amd/amdk8/incoherent_ht.c b/src/northbridge/amd/amdk8/incoherent_ht.c
index e348b67286..f5cd5aa70f 100644
--- a/src/northbridge/amd/amdk8/incoherent_ht.c
+++ b/src/northbridge/amd/amdk8/incoherent_ht.c
@@ -242,7 +242,7 @@ static int ht_setup_chain(device_t udev, uint8_t upos)
}
/* get ht direction */
- offs = (pci_read_config16(dev, pos + PCI_CAP_FLAGS) & (1<<10)) ? PCI_HT_SLAVE1_OFFS : PCI_HT_SLAVE0_OFFS;
+ offs = ( (pci_read_config16(dev, pos + PCI_CAP_FLAGS) >> 10) & 1) ? PCI_HT_SLAVE1_OFFS : PCI_HT_SLAVE0_OFFS;
/* Setup the Hypertransport link */
reset_needed |= ht_optimize_link(udev, upos, uoffs, dev, pos, offs);