summaryrefslogtreecommitdiff
path: root/src/soc/intel/common/block
diff options
context:
space:
mode:
Diffstat (limited to 'src/soc/intel/common/block')
-rw-r--r--src/soc/intel/common/block/i2c/i2c.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/soc/intel/common/block/i2c/i2c.c b/src/soc/intel/common/block/i2c/i2c.c
index 7200771a5a..f2154da3f6 100644
--- a/src/soc/intel/common/block/i2c/i2c.c
+++ b/src/soc/intel/common/block/i2c/i2c.c
@@ -122,6 +122,7 @@ static void lpss_i2c_acpi_fill_ssdt(struct device *dev)
I2C_SPEED_HIGH,
};
int i, bus;
+ const char *path;
if (!dev->enabled)
return;
@@ -140,7 +141,11 @@ static void lpss_i2c_acpi_fill_ssdt(struct device *dev)
if (!dw_i2c_addr)
return;
- acpigen_write_scope(acpi_device_path(dev));
+ path = acpi_device_path(dev);
+ if (!path)
+ return;
+
+ acpigen_write_scope(path);
/* Report timing values for the OS driver */
for (i = 0; i < DW_I2C_SPEED_CONFIG_COUNT; i++) {