drivers/wwan/fm: Include option to add ACPI _DSD for DmaProperty

Similar to commit 09c047c, the WWAN device might be considered an
untrusted device by some platforms, therefore add an option to add the
same `DmaProperty` to the WWAN _DSD.

BUG=b:215424986
BRANCH=brya
TEST=dump SSDT, see new property

Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Change-Id: If485ac5314fae6e6faefac43fcfcea4f4cdd02c0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/62436
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
This commit is contained in:
Tim Wawrzynczak 2022-02-28 08:57:09 -07:00 committed by Felix Held
parent e611905eb3
commit 0292703b96
2 changed files with 12 additions and 0 deletions

View File

@ -241,6 +241,14 @@ static void wwan_fm350gl_acpi_fill_ssdt(const struct device *dev)
wwan_fm350gl_acpi_method_shrf(parent, config); wwan_fm350gl_acpi_method_shrf(parent, config);
wwan_fm350gl_acpi_method_rst(parent, config); wwan_fm350gl_acpi_method_rst(parent, config);
wwan_fm350gl_acpi_method_dpts(parent, config); wwan_fm350gl_acpi_method_dpts(parent, config);
if (config->add_acpi_dma_property) {
struct acpi_dp *dsd;
dsd = acpi_dp_new_table("_DSD");
acpi_dp_add_integer(dsd, "DmaProperty", 1);
acpi_dp_write(dsd);
}
/* NOTE: the 5G driver will call MRST._RST to trigger a cold reset /* NOTE: the 5G driver will call MRST._RST to trigger a cold reset
* during firmware update. * during firmware update.
*/ */
@ -249,6 +257,7 @@ static void wwan_fm350gl_acpi_fill_ssdt(const struct device *dev)
acpigen_write_ADR(0); acpigen_write_ADR(0);
wwan_fm350gl_acpi_method_mrst_rst(parent, config); wwan_fm350gl_acpi_method_mrst_rst(parent, config);
} }
acpigen_write_device_end(); /* Device */ acpigen_write_device_end(); /* Device */
} }
acpigen_write_device_end(); /* Device */ acpigen_write_device_end(); /* Device */

View File

@ -20,6 +20,9 @@ struct drivers_wwan_fm_config {
/* Pointer to the corresponding RTD3 */ /* Pointer to the corresponding RTD3 */
DEVTREE_CONST struct device *rtd3dev; DEVTREE_CONST struct device *rtd3dev;
/* Add `DmaProperty` in _DSD */
bool add_acpi_dma_property;
}; };
#endif /* __DRIVERS_WWAN_FM_CHIP_H__ */ #endif /* __DRIVERS_WWAN_FM_CHIP_H__ */