Attention is currently required from: Kevin Chiu. Hello Kevin Chiu,
I'd like you to do a code review. Please visit
https://review.coreboot.org/c/coreboot/+/51660
to review the following change.
Change subject: drivers/i2c/da7219: Add override hook to enable/disable device in OSPM ......................................................................
drivers/i2c/da7219: Add override hook to enable/disable device in OSPM
For the boards which might have multiple codecs with the same I2C device, it will need to disable to prevent the incorrect kernel driver load.
BUG=b:171755306 BRANCH=master TEST=emerge-grunt coreboot
Change-Id: I0a001a62cd68da814e6f8367b3a4a9522ba8330f Signed-off-by: Kevin Chiu Kevin.Chiu@quantatw.com --- M src/drivers/i2c/da7219/da7219.c 1 file changed, 7 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/60/51660/1
diff --git a/src/drivers/i2c/da7219/da7219.c b/src/drivers/i2c/da7219/da7219.c index 0423460..19b3de2 100644 --- a/src/drivers/i2c/da7219/da7219.c +++ b/src/drivers/i2c/da7219/da7219.c @@ -15,6 +15,12 @@ #define DA7219_ACPI_NAME "DLG7" #define DA7219_ACPI_HID "DLGS7219"
+uint8_t __weak da7219_acpi_sta(void); +uint8_t __weak da7219_acpi_sta(void) +{ + return ACPI_STATUS_DEVICE_ALL_ON; +} + static void da7219_fill_ssdt(const struct device *dev) { struct drivers_i2c_da7219_config *config = dev->chip_info; @@ -37,7 +43,7 @@ acpigen_write_name_integer("_UID", 1); acpigen_write_name_string("_DDN", dev->chip_ops->name); acpigen_write_name_integer("_S0W", 4); - acpigen_write_STA(acpi_device_status(dev)); + acpigen_write_STA(da7219_acpi_sta());
/* Resources */ acpigen_write_name("_CRS");