diff options
author | Wentao Qin <qinwentao@huaqin.corp-partner.google.com> | 2024-04-19 17:49:11 +0800 |
---|---|---|
committer | Yu-Ping Wu <yupingso@google.com> | 2024-05-03 08:35:11 +0000 |
commit | e282422c68569fb6d8442a89ecf2c785b0c28762 (patch) | |
tree | 81df70ca32cadc819d80c0fcd92bd7b09c71c66d /src/mainboard | |
parent | b566ce4aea2473274e1e59ac9d25b316080323f3 (diff) |
mb/google/corsola: Initialize USB port 0
The default MT8186 platform is to initialize USB3 port 1.
Use option bit 27 in fw_config to enable initialization of USB2 port 0
to support devices mounted on it.
BUG=b:335124437
TEST=boot to OS from USB-A
boot to OS from SD Card
BRANCH=corsola
Change-Id: I725b80593f5fc498a204bf47f943c36ccbd78134
Signed-off-by: Wentao Qin <qinwentao@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/82089
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
Diffstat (limited to 'src/mainboard')
-rw-r--r-- | src/mainboard/google/corsola/devicetree.cb | 4 | ||||
-rw-r--r-- | src/mainboard/google/corsola/mainboard.c | 5 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/mainboard/google/corsola/devicetree.cb b/src/mainboard/google/corsola/devicetree.cb index 300ba7b8a7..bb7f003c03 100644 --- a/src/mainboard/google/corsola/devicetree.cb +++ b/src/mainboard/google/corsola/devicetree.cb @@ -1,5 +1,9 @@ ## SPDX-License-Identifier: GPL-2.0-only fw_config + field SECONDARY_USB 27 + option DISABLED 0 + option ENABLED 1 + end field AUDIO_AMP 28 29 option AMP_ALC1019 0 option AMP_ALC5645 1 diff --git a/src/mainboard/google/corsola/mainboard.c b/src/mainboard/google/corsola/mainboard.c index a1ba5f9356..1a0ab3c917 100644 --- a/src/mainboard/google/corsola/mainboard.c +++ b/src/mainboard/google/corsola/mainboard.c @@ -53,6 +53,11 @@ static void mainboard_init(struct device *dev) setup_usb_host(); + if (fw_config_probe(FW_CONFIG(SECONDARY_USB, ENABLED))) { + /* Change host to USB2 port0 for initialization */ + setup_usb_secondary_host(); + } + if (!fw_config_is_provisioned() || fw_config_probe(FW_CONFIG(AUDIO_AMP, AMP_ALC1019))) configure_alc1019(); |