summaryrefslogtreecommitdiff
path: root/src/drivers
diff options
context:
space:
mode:
authorTim Wawrzynczak <twawrzynczak@chromium.org>2022-02-28 08:57:09 -0700
committerFelix Held <felix-coreboot@felixheld.de>2022-03-07 17:48:44 +0000
commit0292703b967f690f1770521804d0a5992941a37e (patch)
tree0c3b67491d5b58e040181feb480ba9486979c2da /src/drivers
parente611905eb3ba2ef9987fc2dad47ef42aa712308e (diff)
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>
Diffstat (limited to 'src/drivers')
-rw-r--r--src/drivers/wwan/fm/acpi_fm350gl.c9
-rw-r--r--src/drivers/wwan/fm/chip.h3
2 files changed, 12 insertions, 0 deletions
diff --git a/src/drivers/wwan/fm/acpi_fm350gl.c b/src/drivers/wwan/fm/acpi_fm350gl.c
index 80370ad4ab..dbc4f2429d 100644
--- a/src/drivers/wwan/fm/acpi_fm350gl.c
+++ b/src/drivers/wwan/fm/acpi_fm350gl.c
@@ -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_rst(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
* during firmware update.
*/
@@ -249,6 +257,7 @@ static void wwan_fm350gl_acpi_fill_ssdt(const struct device *dev)
acpigen_write_ADR(0);
wwan_fm350gl_acpi_method_mrst_rst(parent, config);
}
+
acpigen_write_device_end(); /* Device */
}
acpigen_write_device_end(); /* Device */
diff --git a/src/drivers/wwan/fm/chip.h b/src/drivers/wwan/fm/chip.h
index 635178bd16..19bc4c9008 100644
--- a/src/drivers/wwan/fm/chip.h
+++ b/src/drivers/wwan/fm/chip.h
@@ -20,6 +20,9 @@ struct drivers_wwan_fm_config {
/* Pointer to the corresponding RTD3 */
DEVTREE_CONST struct device *rtd3dev;
+
+ /* Add `DmaProperty` in _DSD */
+ bool add_acpi_dma_property;
};
#endif /* __DRIVERS_WWAN_FM_CHIP_H__ */