summaryrefslogtreecommitdiff
path: root/src/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'src/drivers')
-rw-r--r--src/drivers/i2c/ptn3460/ptn3460.c4
-rw-r--r--src/drivers/intel/dptf/dptf.c2
-rw-r--r--src/drivers/intel/ish/ish.c2
-rw-r--r--src/drivers/intel/mipi_camera/camera.c8
-rw-r--r--src/drivers/intel/soundwire/soundwire.c2
-rw-r--r--src/drivers/net/phy/m88e1512/m88e1512.c10
-rw-r--r--src/drivers/net/r8168.c2
-rw-r--r--src/drivers/nxp/uwb/uwb.c4
-rw-r--r--src/drivers/pcie/generic/generic.c4
-rw-r--r--src/drivers/spi/acpi/acpi.c4
-rw-r--r--src/drivers/usb/hub/acpi.c2
-rw-r--r--src/drivers/usb/pci_xhci/pci_xhci.c2
-rw-r--r--src/drivers/wifi/generic/acpi.c2
-rw-r--r--src/drivers/wifi/generic/smbios.c2
-rw-r--r--src/drivers/wwan/fm/acpi_fm350gl.c2
15 files changed, 26 insertions, 26 deletions
diff --git a/src/drivers/i2c/ptn3460/ptn3460.c b/src/drivers/i2c/ptn3460/ptn3460.c
index 93acb1834e..76b3bc813b 100644
--- a/src/drivers/i2c/ptn3460/ptn3460.c
+++ b/src/drivers/i2c/ptn3460/ptn3460.c
@@ -172,8 +172,8 @@ static void ptn3460_early_init(void *unused)
return;
}
/* Initialize the I2C controller before it is used. */
- if (ptn_dev->bus && ptn_dev->bus->dev->ops && ptn_dev->bus->dev->ops->init)
- ptn_dev->bus->dev->ops->init(ptn_dev->bus->dev);
+ if (ptn_dev->upstream && ptn_dev->upstream->dev->ops && ptn_dev->upstream->dev->ops->init)
+ ptn_dev->upstream->dev->ops->init(ptn_dev->upstream->dev);
ptn3460_init(ptn_dev);
}
diff --git a/src/drivers/intel/dptf/dptf.c b/src/drivers/intel/dptf/dptf.c
index bceb0dea4a..f313540d59 100644
--- a/src/drivers/intel/dptf/dptf.c
+++ b/src/drivers/intel/dptf/dptf.c
@@ -503,7 +503,7 @@ static void write_device_definitions(const struct device *dev)
enum dptf_participant p;
/* The CPU device gets an _ADR that matches the ACPI PCI address for 00:04.00 */
- parent = dev && dev->bus ? dev->bus->dev : NULL;
+ parent = dev && dev->upstream ? dev->upstream->dev : NULL;
if (!parent || parent->path.type != DEVICE_PATH_PCI) {
printk(BIOS_ERR, "%s: DPTF objects must live under 00:04.0 PCI device\n",
__func__);
diff --git a/src/drivers/intel/ish/ish.c b/src/drivers/intel/ish/ish.c
index 6dba46adc7..0ad0bb86d0 100644
--- a/src/drivers/intel/ish/ish.c
+++ b/src/drivers/intel/ish/ish.c
@@ -12,7 +12,7 @@
static void ish_fill_ssdt_generator(const struct device *dev)
{
struct drivers_intel_ish_config *config = dev->chip_info;
- struct device *root = dev->bus->dev;
+ struct device *root = dev->upstream->dev;
struct acpi_dp *dsd;
if (!config)
diff --git a/src/drivers/intel/mipi_camera/camera.c b/src/drivers/intel/mipi_camera/camera.c
index 77c86eaeb6..4044a26896 100644
--- a/src/drivers/intel/mipi_camera/camera.c
+++ b/src/drivers/intel/mipi_camera/camera.c
@@ -199,7 +199,7 @@ static void camera_generate_pld(const struct device *dev)
static uint32_t address_for_dev_type(const struct device *dev, uint8_t dev_type)
{
struct drivers_intel_mipi_camera_config *config = dev->chip_info;
- uint16_t i2c_bus = dev->bus ? dev->bus->secondary : 0xFFFF;
+ uint16_t i2c_bus = dev->upstream ? dev->upstream->secondary : 0xFFFF;
uint16_t i2c_addr;
switch (dev_type) {
@@ -416,7 +416,7 @@ static void camera_fill_sensor(const struct device *dev)
.type = DEVICE_PATH_I2C,
.i2c.device = config->vcm_address,
};
- struct device *vcm_dev = find_dev_path(dev->bus, &path);
+ struct device *vcm_dev = find_dev_path(dev->upstream, &path);
struct drivers_intel_mipi_camera_config *vcm_config;
vcm_config = vcm_dev ? vcm_dev->chip_info : NULL;
@@ -927,7 +927,7 @@ static void camera_fill_ssdt(const struct device *dev)
const struct device *pdev;
if (config->has_power_resource) {
- pdev = dev->bus->dev;
+ pdev = dev->upstream->dev;
if (!pdev || !pdev->enabled)
return;
@@ -951,7 +951,7 @@ static void camera_fill_ssdt(const struct device *dev)
write_i2c_camera_device(dev, scope);
break;
case DEVICE_PATH_GENERIC:
- pdev = dev->bus->dev;
+ pdev = dev->upstream->dev;
scope = acpi_device_scope(pdev);
if (!scope)
return;
diff --git a/src/drivers/intel/soundwire/soundwire.c b/src/drivers/intel/soundwire/soundwire.c
index f9421fc81c..0137dad5b4 100644
--- a/src/drivers/intel/soundwire/soundwire.c
+++ b/src/drivers/intel/soundwire/soundwire.c
@@ -21,7 +21,7 @@ static bool link_enabled(const struct device *dev, unsigned int link)
{
struct device *child;
- for (child = dev->link_list->children; child; child = child->sibling) {
+ for (child = dev->downstream->children; child; child = child->sibling) {
if (child->enabled && child->path.type == DEVICE_PATH_GENERIC &&
child->path.generic.id == link)
return true;
diff --git a/src/drivers/net/phy/m88e1512/m88e1512.c b/src/drivers/net/phy/m88e1512/m88e1512.c
index 07110c630e..7e675001ec 100644
--- a/src/drivers/net/phy/m88e1512/m88e1512.c
+++ b/src/drivers/net/phy/m88e1512/m88e1512.c
@@ -21,10 +21,10 @@ static void m88e1512_init(struct device *dev)
if (config->downshift_cnt) {
if (config->downshift_cnt > DOWNSHIFT_CNT_MAX) {
printk(BIOS_INFO, "%s: Downshift counter for %s is too large.\n",
- dev_path(dev->bus->dev), dev->chip_ops->name);
+ dev_path(dev->upstream->dev), dev->chip_ops->name);
} else {
printk(BIOS_DEBUG, "%s: Enable downshift after %d attempts for %s.\n",
- dev_path(dev->bus->dev), config->downshift_cnt,
+ dev_path(dev->upstream->dev), config->downshift_cnt,
dev->chip_ops->name);
reg = mdio_read(dev, COPPER_SPEC_CTRL_REG_1);
@@ -42,7 +42,7 @@ static void m88e1512_init(struct device *dev)
/* Configure LEDs if requested. */
if (config->configure_leds) {
printk(BIOS_DEBUG, "%s: Set a customized LED mode for %s.\n",
- dev_path(dev->bus->dev), dev->chip_ops->name);
+ dev_path(dev->upstream->dev), dev->chip_ops->name);
/* Select page 3 to access LED function control register. */
switch_page(dev, 3);
@@ -57,7 +57,7 @@ static void m88e1512_init(struct device *dev)
/* INTn can be routed to LED[2] pin. */
if (config->enable_int) {
printk(BIOS_DEBUG, "%s: INTn is routed to LED[2] pin %s.\n",
- dev_path(dev->bus->dev), dev->chip_ops->name);
+ dev_path(dev->upstream->dev), dev->chip_ops->name);
/* Select page 3 to access LED function control register. */
switch_page(dev, 3);
@@ -70,7 +70,7 @@ static void m88e1512_init(struct device *dev)
/* Set RGMII output impedance manually. */
if (config->force_mos) {
printk(BIOS_DEBUG, "%s: Set RGMII driver strength manually for %s.\n",
- dev_path(dev->bus->dev), dev->chip_ops->name);
+ dev_path(dev->upstream->dev), dev->chip_ops->name);
/* Select page 2 to access RGMII output impedance calibration override
register. */
diff --git a/src/drivers/net/r8168.c b/src/drivers/net/r8168.c
index 70a0f63d47..6d93ed2dd7 100644
--- a/src/drivers/net/r8168.c
+++ b/src/drivers/net/r8168.c
@@ -364,7 +364,7 @@ static void r8168_init(struct device *dev)
static void r8168_net_fill_ssdt(const struct device *dev)
{
struct drivers_net_config *config = dev->chip_info;
- const char *path = acpi_device_path(dev->bus->dev);
+ const char *path = acpi_device_path(dev->upstream->dev);
u32 address;
if (!path || !config)
diff --git a/src/drivers/nxp/uwb/uwb.c b/src/drivers/nxp/uwb/uwb.c
index 0f5ba47f08..b828657420 100644
--- a/src/drivers/nxp/uwb/uwb.c
+++ b/src/drivers/nxp/uwb/uwb.c
@@ -15,10 +15,10 @@ static int spi_acpi_get_bus(const struct device *dev)
struct device *spi_dev;
struct device_operations *ops;
- if (!dev->bus || !dev->bus->dev)
+ if (!dev->upstream || !dev->upstream->dev)
return -1;
- spi_dev = dev->bus->dev;
+ spi_dev = dev->upstream->dev;
ops = spi_dev->ops;
if (ops && ops->ops_spi_bus && ops->ops_spi_bus->dev_to_bus)
diff --git a/src/drivers/pcie/generic/generic.c b/src/drivers/pcie/generic/generic.c
index 1b7976e6ad..e401261579 100644
--- a/src/drivers/pcie/generic/generic.c
+++ b/src/drivers/pcie/generic/generic.c
@@ -27,13 +27,13 @@ static void pcie_generic_fill_ssdt(const struct device *dev)
pci_rom_ssdt(dev);
config = dev->chip_info;
- if (!config || !dev->bus || !dev->bus->dev)
+ if (!config || !dev->upstream || !dev->upstream->dev)
return;
const char *scope;
const char *name;
- scope = acpi_device_path(dev->bus->dev);
+ scope = acpi_device_path(dev->upstream->dev);
name = acpi_device_name(dev);
acpigen_write_scope(scope);
diff --git a/src/drivers/spi/acpi/acpi.c b/src/drivers/spi/acpi/acpi.c
index b58bc2daa8..537c377f7c 100644
--- a/src/drivers/spi/acpi/acpi.c
+++ b/src/drivers/spi/acpi/acpi.c
@@ -15,10 +15,10 @@ static int spi_acpi_get_bus(const struct device *dev)
struct device *spi_dev;
struct device_operations *ops;
- if (!dev->bus || !dev->bus->dev)
+ if (!dev->upstream || !dev->upstream->dev)
return -1;
- spi_dev = dev->bus->dev;
+ spi_dev = dev->upstream->dev;
ops = spi_dev->ops;
if (ops && ops->ops_spi_bus &&
diff --git a/src/drivers/usb/hub/acpi.c b/src/drivers/usb/hub/acpi.c
index e26d584a16..3944952eab 100644
--- a/src/drivers/usb/hub/acpi.c
+++ b/src/drivers/usb/hub/acpi.c
@@ -41,7 +41,7 @@ static void usb_hub_add_ports(const struct device *dev)
struct device *port = NULL;
unsigned int child_count = 0;
- while ((port = dev_bus_each_child(dev->link_list, port)) != NULL) {
+ while ((port = dev_bus_each_child(dev->downstream, port)) != NULL) {
if (child_count++ >= config->port_count) {
printk(BIOS_WARNING, "%s cannot be added. Port Count limit reached.\n",
dev_name(port));
diff --git a/src/drivers/usb/pci_xhci/pci_xhci.c b/src/drivers/usb/pci_xhci/pci_xhci.c
index 398595d114..47f69c046c 100644
--- a/src/drivers/usb/pci_xhci/pci_xhci.c
+++ b/src/drivers/usb/pci_xhci/pci_xhci.c
@@ -76,7 +76,7 @@ static const struct device *get_xhci_dev(const struct device *dev)
if (is_root_device(dev))
return NULL;
- dev = dev->bus->dev;
+ dev = dev->upstream->dev;
}
return dev;
diff --git a/src/drivers/wifi/generic/acpi.c b/src/drivers/wifi/generic/acpi.c
index f37a084b53..6abad83f85 100644
--- a/src/drivers/wifi/generic/acpi.c
+++ b/src/drivers/wifi/generic/acpi.c
@@ -610,7 +610,7 @@ void wifi_cnvi_fill_ssdt(const struct device *dev)
if (!dev)
return;
- path = acpi_device_path(dev->bus->dev);
+ path = acpi_device_path(dev->upstream->dev);
if (!path)
return;
diff --git a/src/drivers/wifi/generic/smbios.c b/src/drivers/wifi/generic/smbios.c
index 82c96a52a8..e6ccd5d8a6 100644
--- a/src/drivers/wifi/generic/smbios.c
+++ b/src/drivers/wifi/generic/smbios.c
@@ -38,5 +38,5 @@ int smbios_write_wifi_pcie(struct device *dev, int *handle, unsigned long *curre
int smbios_write_wifi_cnvi(struct device *dev, int *handle, unsigned long *current)
{
- return smbios_write_wifi_pcie(dev->bus->dev, handle, current);
+ return smbios_write_wifi_pcie(dev->upstream->dev, handle, current);
}
diff --git a/src/drivers/wwan/fm/acpi_fm350gl.c b/src/drivers/wwan/fm/acpi_fm350gl.c
index 77ff085240..564ac03cfc 100644
--- a/src/drivers/wwan/fm/acpi_fm350gl.c
+++ b/src/drivers/wwan/fm/acpi_fm350gl.c
@@ -317,7 +317,7 @@ static void wwan_fm350gl_acpi_gpio_events(const struct device *dev)
static void wwan_fm350gl_acpi_fill_ssdt(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;
const char *scope = acpi_device_path(parent);
const struct soc_intel_common_block_pcie_rtd3_config *rtd3_config;