diff options
author | Eric Lai <ericr_lai@compal.corp-partner.google.com> | 2021-08-09 14:54:00 +0800 |
---|---|---|
committer | Nick Vaccaro <nvaccaro@google.com> | 2021-08-12 17:57:55 +0000 |
commit | b6f6e01bcb8561628af122f2b84c67e53cdc5545 (patch) | |
tree | 73c374da1ab51db0c3fedc8a845daecc668f4639 /src/drivers/generic | |
parent | 6cf47f524a3f1cbf699dcb843f098d854a59f8fc (diff) |
drivers/generic/alc1015: Add HID to support alc1019
ALC1019 will use the ACPI compatible and share the same driver with
ALC1015. Add HID to support more compatible ICs.
BUG=b:195891240
TEST=ALC1019P driver can probe properly.
Signed-off-by: Eric Lai <ericr_lai@compal.corp-partner.google.com>
Change-Id: I3e98297f3a39048b24d61e61ca95c60cd2037eb5
Reviewed-on: https://review.coreboot.org/c/coreboot/+/56877
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Diffstat (limited to 'src/drivers/generic')
-rw-r--r-- | src/drivers/generic/alc1015/alc1015.c | 5 | ||||
-rw-r--r-- | src/drivers/generic/alc1015/chip.h | 4 |
2 files changed, 6 insertions, 3 deletions
diff --git a/src/drivers/generic/alc1015/alc1015.c b/src/drivers/generic/alc1015/alc1015.c index 920b8af4bc..ca685d6afb 100644 --- a/src/drivers/generic/alc1015/alc1015.c +++ b/src/drivers/generic/alc1015/alc1015.c @@ -25,7 +25,10 @@ static void alc1015_fill_ssdt(const struct device *dev) acpigen_write_scope(scope); acpigen_write_device(name); - acpigen_write_name_string("_HID", "RTL1015"); + if (config->hid) + acpigen_write_name_string("_HID", config->hid); + else + acpigen_write_name_string("_HID", "RTL1015"); acpigen_write_name_integer("_UID", 0); acpigen_write_name_string("_DDN", dev->chip_ops->name); acpigen_write_STA(acpi_device_status(dev)); diff --git a/src/drivers/generic/alc1015/chip.h b/src/drivers/generic/alc1015/chip.h index 4c01e7ca2e..fa841772ed 100644 --- a/src/drivers/generic/alc1015/chip.h +++ b/src/drivers/generic/alc1015/chip.h @@ -3,6 +3,6 @@ #include <acpi/acpi_device.h> struct drivers_generic_alc1015_config { - /* SDMODE GPIO */ - struct acpi_gpio sdb; + const char *hid; /* ACPI _HID */ + struct acpi_gpio sdb; /* SDMODE GPIO */ }; |