diff options
author | Jeremy Compostella <jeremy.compostella@intel.com> | 2024-10-29 10:40:27 -0700 |
---|---|---|
committer | Jérémy Compostella <jeremy.compostella@intel.com> | 2024-11-27 21:28:05 +0000 |
commit | 67dff1b2b1023aecbe6fa169bee2a4ba342b15c3 (patch) | |
tree | 8f370bcb1d97317155b52c48a0f783415b7be776 /src/drivers/wifi/generic | |
parent | 3f535d3a0dcf17fadb98f52450ab79e693446040 (diff) |
drivers/wifi: Support Bluetooth Dual Chain Mode
This feature provides ability to provide dual chain setting.
The implementation follows document 559910 Intel Connectivity
Platforms BIOS Guideline revision 9.2 specification.
BUG=b:346600091
TEST=BDCM method is added to the bluetooth companion device and
return the data supplied by the SAR binary blob
Change-Id: Iebe95815c944d045f4cf686abcd1874a8a45e220
Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/84943
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
Diffstat (limited to 'src/drivers/wifi/generic')
-rw-r--r-- | src/drivers/wifi/generic/acpi.c | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/src/drivers/wifi/generic/acpi.c b/src/drivers/wifi/generic/acpi.c index 4be43ffe43..8bfce816fb 100644 --- a/src/drivers/wifi/generic/acpi.c +++ b/src/drivers/wifi/generic/acpi.c @@ -736,6 +736,41 @@ static void sar_emit_bbfb(const struct bbfb_profile *bbfb) acpigen_write_package_end(); } +static void sar_emit_bdcm(const struct bdcm_profile *bdcm) +{ + if (bdcm == NULL) + return; + + /* + * Name ("BDCM", Package () { + * Revision, + * Package () { + * Domain Type, // 0x12:Bluetooth + * Dual Chain Mode + * } + * }) + */ + if (bdcm->revision != BDCM_REVISION) { + printk(BIOS_ERR, "Unsupported BDCM table revision: %d\n", + bdcm->revision); + return; + } + + acpigen_write_name("BDCM"); + acpigen_write_package(2); + acpigen_write_dword(bdcm->revision); + + /* + * Emit 'Domain Type' + 'Dual Chain Mode' + */ + acpigen_write_package(2); + acpigen_write_dword(DOMAIN_TYPE_BLUETOOTH); + acpigen_write_dword(bdcm->dual_chain_mode); + + acpigen_write_package_end(); + acpigen_write_package_end(); +} + static void emit_wifi_sar_acpi_structures(const struct device *dev, union wifi_sar_limits *sar_limits) { @@ -870,6 +905,7 @@ static void wifi_ssdt_write_properties(const struct device *dev, const char *sco sar_emit_brds(sar_limits.bsar); sar_emit_bpag(sar_limits.bpag); sar_emit_bbfb(sar_limits.bbfb); + sar_emit_bdcm(sar_limits.bdcm); acpigen_write_scope_end(); } else { printk(BIOS_ERR, "Failed to get %s Bluetooth companion ACPI path\n", |