diff options
author | Poornima Tom <poornima.tom@intel.com> | 2024-04-11 07:07:42 +0530 |
---|---|---|
committer | Jérémy Compostella <jeremy.compostella@intel.com> | 2024-07-03 17:01:25 +0000 |
commit | 89566946fb6ff46b85ae2c560076fb377d0f8128 (patch) | |
tree | cce9ccb6cc8837401de3d52a57e61f7b91325dd4 /src/drivers/wifi | |
parent | 71dda74fe8addc0beffffc5a039c896c3f910640 (diff) |
drivers/wifi: Support 320Mhz Bandwidth Enablement per MCC
Add support for the configuration of 320MHz Bandwidth per MCC based on
countries. The implementation follows document #559910 Intel
Connectivity Platforms BIOS Guidelines revision 8.3.
BUG=b:333804562
BRANCH=firmware-rex-15709.B
TEST=WBEM method is added to the CNVW device and return the data
supplied by the SAR binary blob
Change-Id: Ie76794825f1a0104d199c078aa4ffc714aa95b17
Signed-off-by: Poornima Tom <poornima.tom@intel.com>
Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/81790
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Eric Lai <ericllai@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/drivers/wifi')
-rw-r--r-- | src/drivers/wifi/generic/acpi.c | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/src/drivers/wifi/generic/acpi.c b/src/drivers/wifi/generic/acpi.c index e303589660..13120d4acf 100644 --- a/src/drivers/wifi/generic/acpi.c +++ b/src/drivers/wifi/generic/acpi.c @@ -539,6 +539,43 @@ static void sar_emit_brds(const struct bsar_profile *bsar) acpigen_write_package_end(); } +static void sar_emit_wbem(const struct wbem_profile *wbem) +{ + if (wbem == NULL) + return; + + /* + * Name ("WBEM", Package() { + * { + * Revision, + * Package() + * { + * DomainType, // 0x7:WiFi + * bandwidth_320mhz_country_enablement // 0 Disabled + * // 1 Japan Enabled + * // 2 South Korea Enabled + * // 3 Japan + South Korea Enabled + * } + } }) + */ + if (wbem->revision != WBEM_REVISION) { + printk(BIOS_ERR, "Unsupported WBEM table revision: %d\n", + wbem->revision); + return; + } + + acpigen_write_name("WBEM"); + acpigen_write_package(2); + acpigen_write_dword(wbem->revision); + + acpigen_write_package(2); + acpigen_write_dword(DOMAIN_TYPE_WIFI); + acpigen_write_dword(wbem->bandwidth_320mhz_country_enablement); + + acpigen_write_package_end(); + acpigen_write_package_end(); +} + static void emit_sar_acpi_structures(const struct device *dev, struct dsm_profile *dsm, struct bsar_profile *bsar, bool *bsar_loaded) { @@ -562,6 +599,7 @@ static void emit_sar_acpi_structures(const struct device *dev, struct dsm_profil sar_emit_wgds(sar_limits.wgds); sar_emit_ppag(sar_limits.ppag); sar_emit_wtas(sar_limits.wtas); + sar_emit_wbem(sar_limits.wbem); /* copy the dsm data to be later used for creating _DSM function */ if (sar_limits.dsm != NULL) |