mb/google/nissa/var/rull: Configure Acoustic noise mitigation
[coreboot2.git] / src / ec / google / chromeec / mux / mux.c
blob62be23842aa97559f8fbb4ece143029d921fbe3c
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 #include <acpi/acpigen.h>
5 #define GOOGLE_CHROMEEC_MUX_DEVICE_HID "GOOG001A"
6 #define GOOGLE_CHROMEEC_MUX_DEVICE_NAME "ECMX"
8 static void mux_fill_ssdt(const struct device *dev)
10 acpigen_write_scope(acpi_device_scope(dev));
11 acpigen_write_device(GOOGLE_CHROMEEC_MUX_DEVICE_NAME);
12 acpigen_write_name_string("_HID", GOOGLE_CHROMEEC_MUX_DEVICE_HID);
13 acpigen_write_name_string("_DDN", "ChromeOS EC Embedded Controller "
14 "Mux & Retimer control");
16 acpigen_write_device_end();
17 acpigen_write_scope_end();
20 static const char *mux_acpi_name(const struct device *dev)
22 return GOOGLE_CHROMEEC_MUX_DEVICE_NAME;
25 static struct device_operations mux_ops = {
26 .read_resources = noop_read_resources,
27 .set_resources = noop_set_resources,
28 .acpi_name = mux_acpi_name,
29 .acpi_fill_ssdt = mux_fill_ssdt,
30 .scan_bus = scan_static_bus,
33 static void mux_enable(struct device *dev)
35 dev->ops = &mux_ops;
38 struct chip_operations ec_google_chromeec_mux_ops = {
39 .name = "CrosEC Type C Mux device",
40 .enable_dev = mux_enable