summaryrefslogtreecommitdiffstats
path: root/src/mainboard
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard')
-rw-r--r--src/mainboard/aopen/dxplplusu/acpi_tables.c4
-rw-r--r--src/mainboard/emulation/qemu-i440fx/northbridge.c2
-rw-r--r--src/mainboard/google/brox/mainboard.c4
-rw-r--r--src/mainboard/google/brya/mainboard.c4
-rw-r--r--src/mainboard/google/kahlee/variants/careena/mainboard.c2
-rw-r--r--src/mainboard/google/kahlee/variants/treeya/audio.c2
-rw-r--r--src/mainboard/google/octopus/mainboard.c2
-rw-r--r--src/mainboard/google/rex/mainboard.c2
-rw-r--r--src/mainboard/google/zork/variants/baseboard/ramstage_common.c2
-rw-r--r--src/mainboard/ibase/mb899/mptable.c4
-rw-r--r--src/mainboard/kontron/986lcd-m/mptable.c4
-rw-r--r--src/mainboard/pcengines/apu2/mainboard.c2
-rw-r--r--src/mainboard/roda/rk9/ti_pci7xx1.c2
-rw-r--r--src/mainboard/siemens/fa_ehl/mainboard.c6
-rw-r--r--src/mainboard/siemens/mc_apl1/mainboard.c6
-rw-r--r--src/mainboard/siemens/mc_apl1/variants/mc_apl3/mainboard.c4
-rw-r--r--src/mainboard/siemens/mc_apl1/variants/mc_apl5/mainboard.c4
-rw-r--r--src/mainboard/siemens/mc_apl1/variants/mc_apl6/mainboard.c4
-rw-r--r--src/mainboard/siemens/mc_ehl/mainboard.c6
19 files changed, 33 insertions, 33 deletions
diff --git a/src/mainboard/aopen/dxplplusu/acpi_tables.c b/src/mainboard/aopen/dxplplusu/acpi_tables.c
index e22b454ab5f1..114068fc4164 100644
--- a/src/mainboard/aopen/dxplplusu/acpi_tables.c
+++ b/src/mainboard/aopen/dxplplusu/acpi_tables.c
@@ -11,7 +11,7 @@ unsigned long acpi_fill_madt(unsigned long current)
bdev = pcidev_on_root(2, 0);
/* P64H2 Bus B IOAPIC */
if (bdev)
- dev = pcidev_path_behind(bdev->link_list, PCI_DEVFN(28, 0));
+ dev = pcidev_path_behind(bdev->downstream, PCI_DEVFN(28, 0));
if (dev) {
res = find_resource(dev, PCI_BASE_ADDRESS_0);
current += acpi_create_madt_ioapic_from_hw((acpi_madt_ioapic_t *)current, res->base);
@@ -19,7 +19,7 @@ unsigned long acpi_fill_madt(unsigned long current)
/* P64H2 Bus A IOAPIC */
if (bdev)
- dev = pcidev_path_behind(bdev->link_list, PCI_DEVFN(30, 0));
+ dev = pcidev_path_behind(bdev->downstream, PCI_DEVFN(30, 0));
if (dev) {
res = find_resource(dev, PCI_BASE_ADDRESS_0);
current += acpi_create_madt_ioapic_from_hw((acpi_madt_ioapic_t *)current, res->base);
diff --git a/src/mainboard/emulation/qemu-i440fx/northbridge.c b/src/mainboard/emulation/qemu-i440fx/northbridge.c
index 6c26366ad732..609e38989965 100644
--- a/src/mainboard/emulation/qemu-i440fx/northbridge.c
+++ b/src/mainboard/emulation/qemu-i440fx/northbridge.c
@@ -39,7 +39,7 @@ static void qemu_reserve_ports(struct device *dev, unsigned int idx,
static void cpu_pci_domain_set_resources(struct device *dev)
{
- assign_resources(dev->link_list);
+ assign_resources(dev->downstream);
}
static void cpu_pci_domain_read_resources(struct device *dev)
diff --git a/src/mainboard/google/brox/mainboard.c b/src/mainboard/google/brox/mainboard.c
index f892099be88d..5820805a97e5 100644
--- a/src/mainboard/google/brox/mainboard.c
+++ b/src/mainboard/google/brox/mainboard.c
@@ -106,7 +106,7 @@ static void mainboard_dev_init(struct device *dev)
static void mainboard_generate_wwan_shutdown(const struct device *dev)
{
const struct drivers_wwan_fm_config *config = config_of(dev);
- const struct device *parent = dev->bus->dev;
+ const struct device *parent = dev->upstream->dev;
if (!config)
return;
@@ -126,7 +126,7 @@ static void mainboard_generate_wwan_shutdown(const struct device *dev)
static void mainboard_generate_dgpu_shutdown(const struct device *dev)
{
/* Call `_OFF` from the Power Resource associated with the dGPU's PEG port. */
- const struct device *parent = dev->bus->dev;
+ const struct device *parent = dev->upstream->dev;
if (parent)
acpigen_emit_namestring(acpi_device_path_join(parent, "PGPR._OFF"));
diff --git a/src/mainboard/google/brya/mainboard.c b/src/mainboard/google/brya/mainboard.c
index aa332cd80683..9cf56b2402fb 100644
--- a/src/mainboard/google/brya/mainboard.c
+++ b/src/mainboard/google/brya/mainboard.c
@@ -106,7 +106,7 @@ static void mainboard_dev_init(struct device *dev)
static void mainboard_generate_wwan_shutdown(const struct device *dev)
{
const struct drivers_wwan_fm_config *config = config_of(dev);
- const struct device *parent = dev->bus->dev;
+ const struct device *parent = dev->upstream->dev;
if (!config)
return;
@@ -126,7 +126,7 @@ static void mainboard_generate_wwan_shutdown(const struct device *dev)
static void mainboard_generate_dgpu_shutdown(const struct device *dev)
{
/* Call `_OFF` from the Power Resource associated with the dGPU's PEG port. */
- const struct device *parent = dev->bus->dev;
+ const struct device *parent = dev->upstream->dev;
if (parent)
acpigen_emit_namestring(acpi_device_path_join(parent, "PGPR._OFF"));
diff --git a/src/mainboard/google/kahlee/variants/careena/mainboard.c b/src/mainboard/google/kahlee/variants/careena/mainboard.c
index 937a4113ceb7..c54b5303a5f1 100644
--- a/src/mainboard/google/kahlee/variants/careena/mainboard.c
+++ b/src/mainboard/google/kahlee/variants/careena/mainboard.c
@@ -26,7 +26,7 @@ void variant_devtree_update(void)
if (mmio_dev == NULL)
return;
- while ((child = dev_bus_each_child(mmio_dev->link_list, child)) != NULL) {
+ while ((child = dev_bus_each_child(mmio_dev->downstream, child)) != NULL) {
if (child->path.type != DEVICE_PATH_I2C)
continue;
if (child->path.i2c.device != 0x1a)
diff --git a/src/mainboard/google/kahlee/variants/treeya/audio.c b/src/mainboard/google/kahlee/variants/treeya/audio.c
index ac7f7a27294d..e7a20ea41474 100644
--- a/src/mainboard/google/kahlee/variants/treeya/audio.c
+++ b/src/mainboard/google/kahlee/variants/treeya/audio.c
@@ -25,7 +25,7 @@ void variant_devtree_update(void)
}
} while (mmio_dev->path.mmio.addr != APU_I2C0_BASE);
- while ((child = dev_bus_each_child(mmio_dev->link_list, child)) != NULL) {
+ while ((child = dev_bus_each_child(mmio_dev->downstream, child)) != NULL) {
if (child->path.type != DEVICE_PATH_I2C)
continue;
if (child->path.i2c.device != RT58_I2C_ADDRESS)
diff --git a/src/mainboard/google/octopus/mainboard.c b/src/mainboard/google/octopus/mainboard.c
index 92b107479d35..3392a3c990dd 100644
--- a/src/mainboard/google/octopus/mainboard.c
+++ b/src/mainboard/google/octopus/mainboard.c
@@ -179,7 +179,7 @@ static void audio_codec_device_update(void)
{
struct device *audio_dev = NULL;
struct bus *audio_i2c_bus =
- pcidev_path_on_root(PCH_DEVFN_I2C5)->link_list;
+ pcidev_path_on_root(PCH_DEVFN_I2C5)->downstream;
enum ssfc_audio_codec codec = ssfc_get_audio_codec();
while ((audio_dev = dev_bus_each_child(audio_i2c_bus, audio_dev))) {
diff --git a/src/mainboard/google/rex/mainboard.c b/src/mainboard/google/rex/mainboard.c
index 3ca85ff77c3f..bf489ff52831 100644
--- a/src/mainboard/google/rex/mainboard.c
+++ b/src/mainboard/google/rex/mainboard.c
@@ -82,7 +82,7 @@ static void mainboard_generate_s0ix_hook(void)
static void mainboard_generate_wwan_shutdown(const struct device *dev)
{
const struct drivers_wwan_fm_config *config = config_of(dev);
- const struct device *parent = dev->bus->dev;
+ const struct device *parent = dev->upstream->dev;
if (!config)
return;
diff --git a/src/mainboard/google/zork/variants/baseboard/ramstage_common.c b/src/mainboard/google/zork/variants/baseboard/ramstage_common.c
index 3c203f54422a..a54454896152 100644
--- a/src/mainboard/google/zork/variants/baseboard/ramstage_common.c
+++ b/src/mainboard/google/zork/variants/baseboard/ramstage_common.c
@@ -115,7 +115,7 @@ void variant_touchscreen_update(void)
if (variant_uses_v3_6_schematics())
return;
- while ((child = dev_bus_each_child(mmio_dev->link_list, child)) != NULL) {
+ while ((child = dev_bus_each_child(mmio_dev->downstream, child)) != NULL) {
struct drivers_i2c_generic_config *cfg;
if (child->chip_ops == &drivers_i2c_generic_ops) {
diff --git a/src/mainboard/ibase/mb899/mptable.c b/src/mainboard/ibase/mb899/mptable.c
index 4ec578a7f2fc..a9ad7c763e8f 100644
--- a/src/mainboard/ibase/mb899/mptable.c
+++ b/src/mainboard/ibase/mb899/mptable.c
@@ -19,7 +19,7 @@ static void *smp_write_config_table(void *v)
firewire = dev_find_device(0x104c, 0x8023, 0);
if (firewire) {
- firewire_bus = firewire->bus->secondary;
+ firewire_bus = firewire->upstream->secondary;
printk(BIOS_SPEW, "Firewire device is on bus %x\n",
firewire_bus);
}
@@ -30,7 +30,7 @@ static void *smp_write_config_table(void *v)
if (!riser)
riser = dev_find_device(0x3388, 0x0022, 0);
if (riser) {
- riser_bus = riser->link_list->secondary;
+ riser_bus = riser->downstream->secondary;
printk(BIOS_SPEW, "Riser bus is %x\n", riser_bus);
}
diff --git a/src/mainboard/kontron/986lcd-m/mptable.c b/src/mainboard/kontron/986lcd-m/mptable.c
index 605b8d700d13..b0bfbe71c5b1 100644
--- a/src/mainboard/kontron/986lcd-m/mptable.c
+++ b/src/mainboard/kontron/986lcd-m/mptable.c
@@ -18,7 +18,7 @@ static void *smp_write_config_table(void *v)
firewire = dev_find_device(0x104c, 0x8023, 0);
if (firewire) {
- firewire_bus = firewire->bus->secondary;
+ firewire_bus = firewire->upstream->secondary;
}
/* If a riser card is used, this riser is detected on bus 4, so its secondary bus is the */
@@ -27,7 +27,7 @@ static void *smp_write_config_table(void *v)
if (!riser)
riser = dev_find_device(0x3388, 0x0022, 0);
if (riser) {
- riser_bus = riser->link_list->secondary;
+ riser_bus = riser->downstream->secondary;
}
mptable_write_buses(mc, NULL, &isa_bus);
diff --git a/src/mainboard/pcengines/apu2/mainboard.c b/src/mainboard/pcengines/apu2/mainboard.c
index a09fa66ee0b3..ac5c92871f88 100644
--- a/src/mainboard/pcengines/apu2/mainboard.c
+++ b/src/mainboard/pcengines/apu2/mainboard.c
@@ -277,7 +277,7 @@ const char *smbios_mainboard_serial_number(void)
dev = pcidev_on_root(2, 2);
if (dev)
- dev = pcidev_path_behind(dev->link_list, PCI_DEVFN(0, 0));
+ dev = pcidev_path_behind(dev->downstream, PCI_DEVFN(0, 0));
if (!dev)
return serial;
diff --git a/src/mainboard/roda/rk9/ti_pci7xx1.c b/src/mainboard/roda/rk9/ti_pci7xx1.c
index 3ff339ce00da..970e83d8182f 100644
--- a/src/mainboard/roda/rk9/ti_pci7xx1.c
+++ b/src/mainboard/roda/rk9/ti_pci7xx1.c
@@ -19,7 +19,7 @@ static void pci7xx1_enable(struct device *const dev)
u16 gcr = pci_read_config16(dev, 0x86);
for (fn = 5; fn > 0; --fn) {
const struct device *const d =
- pcidev_path_behind(dev->bus, PCI_DEVFN(slot, fn));
+ pcidev_path_behind(dev->upstream, PCI_DEVFN(slot, fn));
if (!d || d->enabled) continue;
printk(BIOS_DEBUG,
"%s: Hiding function #%d.\n", __func__, fn);
diff --git a/src/mainboard/siemens/fa_ehl/mainboard.c b/src/mainboard/siemens/fa_ehl/mainboard.c
index 7aa0d8645386..ac16346f2a14 100644
--- a/src/mainboard/siemens/fa_ehl/mainboard.c
+++ b/src/mainboard/siemens/fa_ehl/mainboard.c
@@ -42,7 +42,7 @@ static uint8_t is_mac_adr_valid(uint8_t mac[MAC_ADDR_LEN])
*/
enum cb_err mainboard_get_mac_address(struct device *dev, uint8_t mac[MAC_ADDR_LEN])
{
- struct bus *parent = dev->bus;
+ struct bus *parent = dev->upstream;
uint8_t buf[16], mapping[16], i = 0, chain_len = 0;
memset(buf, 0, sizeof(buf));
@@ -51,10 +51,10 @@ enum cb_err mainboard_get_mac_address(struct device *dev, uint8_t mac[MAC_ADDR_L
/* The first entry in the tree is the device itself. */
buf[0] = dev->path.pci.devfn;
chain_len = 1;
- for (i = 1; i < MAX_PATH_DEPTH && parent->dev->bus->subordinate; i++) {
+ for (i = 1; i < MAX_PATH_DEPTH && parent->dev->upstream->subordinate; i++) {
buf[i] = parent->dev->path.pci.devfn;
chain_len++;
- parent = parent->dev->bus;
+ parent = parent->dev->upstream;
}
if (i == MAX_PATH_DEPTH) {
/* The path is deeper than MAX_PATH_DEPTH devices, error. */
diff --git a/src/mainboard/siemens/mc_apl1/mainboard.c b/src/mainboard/siemens/mc_apl1/mainboard.c
index 0593797b11af..51427be49efa 100644
--- a/src/mainboard/siemens/mc_apl1/mainboard.c
+++ b/src/mainboard/siemens/mc_apl1/mainboard.c
@@ -55,7 +55,7 @@ static uint8_t is_mac_adr_valid(uint8_t mac[MAC_ADDR_LEN])
*/
enum cb_err mainboard_get_mac_address(struct device *dev, uint8_t mac[MAC_ADDR_LEN])
{
- struct bus *parent = dev->bus;
+ struct bus *parent = dev->upstream;
uint8_t buf[16], mapping[16], i = 0, chain_len = 0;
memset(buf, 0, sizeof(buf));
@@ -64,10 +64,10 @@ enum cb_err mainboard_get_mac_address(struct device *dev, uint8_t mac[MAC_ADDR_L
/* The first entry in the tree is the device itself. */
buf[0] = dev->path.pci.devfn;
chain_len = 1;
- for (i = 1; i < MAX_PATH_DEPTH && parent->dev->bus->subordinate; i++) {
+ for (i = 1; i < MAX_PATH_DEPTH && parent->dev->upstream->subordinate; i++) {
buf[i] = parent->dev->path.pci.devfn;
chain_len++;
- parent = parent->dev->bus;
+ parent = parent->dev->upstream;
}
if (i == MAX_PATH_DEPTH) {
/* The path is deeper than MAX_PATH_DEPTH devices, error. */
diff --git a/src/mainboard/siemens/mc_apl1/variants/mc_apl3/mainboard.c b/src/mainboard/siemens/mc_apl1/variants/mc_apl3/mainboard.c
index b61f32df49ce..c6beff65e538 100644
--- a/src/mainboard/siemens/mc_apl1/variants/mc_apl3/mainboard.c
+++ b/src/mainboard/siemens/mc_apl1/variants/mc_apl3/mainboard.c
@@ -41,7 +41,7 @@ void variant_mainboard_final(void)
/* Disable clock outputs 0 and 2-4 (CLKOUT) for upstream XIO2001 PCIe to PCI
Bridge. */
- struct device *parent = dev->bus->dev;
+ struct device *parent = dev->upstream->dev;
if (parent && parent->device == PCI_DID_TI_XIO2001)
pci_write_config8(parent, 0xd8, 0x1d);
}
@@ -50,7 +50,7 @@ void variant_mainboard_final(void)
mainboard. */
dev = dev_find_device(PCI_VID_SIEMENS, 0x403f, 0);
if (dev) {
- struct device *parent = dev->bus->dev;
+ struct device *parent = dev->upstream->dev;
if (parent && parent->device == PCI_DID_TI_XIO2001)
pci_write_config8(parent, 0xd8, 0x3c);
}
diff --git a/src/mainboard/siemens/mc_apl1/variants/mc_apl5/mainboard.c b/src/mainboard/siemens/mc_apl1/variants/mc_apl5/mainboard.c
index 8eedce6d6ca3..eda4b1bf749c 100644
--- a/src/mainboard/siemens/mc_apl1/variants/mc_apl5/mainboard.c
+++ b/src/mainboard/siemens/mc_apl1/variants/mc_apl5/mainboard.c
@@ -51,7 +51,7 @@ void variant_mainboard_final(void)
/* Disable clock outputs 0-3 (CLKOUT) for upstream XIO2001 PCIe to PCI
Bridge. */
- struct device *parent = dev->bus->dev;
+ struct device *parent = dev->upstream->dev;
if (parent && parent->device == PCI_DID_TI_XIO2001)
pci_write_config8(parent, 0xd8, 0x0f);
}
@@ -60,7 +60,7 @@ void variant_mainboard_final(void)
mainboard. */
dev = dev_find_device(PCI_VID_SIEMENS, 0x403f, 0);
if (dev) {
- struct device *parent = dev->bus->dev;
+ struct device *parent = dev->upstream->dev;
if (parent && parent->device == PCI_DID_TI_XIO2001)
pci_write_config8(parent, 0xd8, 0x3e);
}
diff --git a/src/mainboard/siemens/mc_apl1/variants/mc_apl6/mainboard.c b/src/mainboard/siemens/mc_apl1/variants/mc_apl6/mainboard.c
index 1856a35b3c93..a5fe3d7e03bb 100644
--- a/src/mainboard/siemens/mc_apl1/variants/mc_apl6/mainboard.c
+++ b/src/mainboard/siemens/mc_apl1/variants/mc_apl6/mainboard.c
@@ -41,7 +41,7 @@ void variant_mainboard_final(void)
/* Disable clock outputs 0-3 (CLKOUT) for upstream XIO2001 PCIe to PCI
Bridge. */
- struct device *parent = dev->bus->dev;
+ struct device *parent = dev->upstream->dev;
if (parent && parent->device == PCI_DID_TI_XIO2001)
pci_write_config8(parent, 0xd8, 0x0F);
}
@@ -50,7 +50,7 @@ void variant_mainboard_final(void)
mainboard. */
dev = dev_find_device(PCI_VID_SIEMENS, 0x403f, 0);
if (dev) {
- struct device *parent = dev->bus->dev;
+ struct device *parent = dev->upstream->dev;
if (parent && parent->device == PCI_DID_TI_XIO2001)
pci_write_config8(parent, 0xd8, 0x3c);
}
diff --git a/src/mainboard/siemens/mc_ehl/mainboard.c b/src/mainboard/siemens/mc_ehl/mainboard.c
index 7aa0d8645386..ac16346f2a14 100644
--- a/src/mainboard/siemens/mc_ehl/mainboard.c
+++ b/src/mainboard/siemens/mc_ehl/mainboard.c
@@ -42,7 +42,7 @@ static uint8_t is_mac_adr_valid(uint8_t mac[MAC_ADDR_LEN])
*/
enum cb_err mainboard_get_mac_address(struct device *dev, uint8_t mac[MAC_ADDR_LEN])
{
- struct bus *parent = dev->bus;
+ struct bus *parent = dev->upstream;
uint8_t buf[16], mapping[16], i = 0, chain_len = 0;
memset(buf, 0, sizeof(buf));
@@ -51,10 +51,10 @@ enum cb_err mainboard_get_mac_address(struct device *dev, uint8_t mac[MAC_ADDR_L
/* The first entry in the tree is the device itself. */
buf[0] = dev->path.pci.devfn;
chain_len = 1;
- for (i = 1; i < MAX_PATH_DEPTH && parent->dev->bus->subordinate; i++) {
+ for (i = 1; i < MAX_PATH_DEPTH && parent->dev->upstream->subordinate; i++) {
buf[i] = parent->dev->path.pci.devfn;
chain_len++;
- parent = parent->dev->bus;
+ parent = parent->dev->upstream;
}
if (i == MAX_PATH_DEPTH) {
/* The path is deeper than MAX_PATH_DEPTH devices, error. */