Elyes Haouas has submitted this change. ( https://review.coreboot.org/c/coreboot/+/85944?usp=email )
Change subject: mb/lenovo/x131e: Clean up USB configurations ......................................................................
mb/lenovo/x131e: Clean up USB configurations
As of commit a911b7584820 ("mb/*: Remove old USB configurations from SNB/bd82x6x boards") USB configurations are drawn exclusively from devicetree. The old copy carried by early_init.c should have been removed back then. Since it has nothing else, drop the whole file.
Remove xhci_overcurrent_mapping as it is now derived from usb_port_config.
According to schematics only the first two ports are wired for xHCI and both goes to OC0#. Remove OC pin assignment from disabled third port so the (former) xhci_overcurrent_mapping can be derived correctly. Also adjust xhci_switchable_ports and superspeed_capable_ports to match.
Thanks to Patrick Rudolph for the information.
Change-Id: I6bdc9a188b2baa2207aaccb46821b58f97ff7da6 Signed-off-by: Keith Hui buurin@gmail.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/85944 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Patrick Rudolph patrick.rudolph@9elements.com Reviewed-by: Elyes Haouas ehaouas@noos.fr --- M src/mainboard/lenovo/x131e/Makefile.mk M src/mainboard/lenovo/x131e/devicetree.cb D src/mainboard/lenovo/x131e/early_init.c 3 files changed, 3 insertions(+), 26 deletions(-)
Approvals: Patrick Rudolph: Looks good to me, approved build bot (Jenkins): Verified Elyes Haouas: Looks good to me, approved
diff --git a/src/mainboard/lenovo/x131e/Makefile.mk b/src/mainboard/lenovo/x131e/Makefile.mk index e4b6fbf..7611194 100644 --- a/src/mainboard/lenovo/x131e/Makefile.mk +++ b/src/mainboard/lenovo/x131e/Makefile.mk @@ -4,5 +4,3 @@ romstage-y += gpio.c
ramstage-$(CONFIG_MAINBOARD_USE_LIBGFXINIT) += gma-mainboard.ads -bootblock-y += early_init.c -romstage-y += early_init.c diff --git a/src/mainboard/lenovo/x131e/devicetree.cb b/src/mainboard/lenovo/x131e/devicetree.cb index b74e78f..dfd11d5 100644 --- a/src/mainboard/lenovo/x131e/devicetree.cb +++ b/src/mainboard/lenovo/x131e/devicetree.cb @@ -40,13 +40,12 @@ register "gen3_dec" = "0x000c0701" register "gen4_dec" = "0x000c06a1"
- register "xhci_switchable_ports" = "0xf" - register "superspeed_capable_ports" = "0xf" - register "xhci_overcurrent_mapping" = "0x00000c03" + register "xhci_switchable_ports" = "0x3" + register "superspeed_capable_ports" = "0x3" register "usb_port_config" = "{ {1, 1, 0}, /* P0: USB 3.0 1 (OC0) */ {1, 1, 0}, /* P1: USB 3.0 2 (OC0) */ - {0, 0, 0}, + {0, 0, -1}, {1, 1, -1}, /* P3: Camera (no OC) */ {1, 0, -1}, /* P4: WLAN (no OC) */ {1, 0, -1}, /* P5: WWAN (no OC) */ diff --git a/src/mainboard/lenovo/x131e/early_init.c b/src/mainboard/lenovo/x131e/early_init.c deleted file mode 100644 index 410dea6..0000000 --- a/src/mainboard/lenovo/x131e/early_init.c +++ /dev/null @@ -1,20 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0-only */ - -#include <southbridge/intel/bd82x6x/pch.h> - -const struct southbridge_usb_port mainboard_usb_ports[] = { - {1, 1, 0}, /* P0: USB 3.0 1 (OC0) */ - {1, 1, 0}, /* P1: USB 3.0 2 (OC0) */ - {0, 0, 0}, - {1, 1, -1}, /* P3: Camera (no OC) */ - {1, 0, -1}, /* P4: WLAN (no OC) */ - {1, 0, -1}, /* P5: WWAN (no OC) */ - {0, 0, 0}, - {0, 0, 0}, - {0, 0, 0}, - {1, 1, 4}, /* P9: USB 2.0 (AUO4) (OC4) */ - {0, 0, 0}, - {0, 0, 0}, - {0, 0, 0}, - {1, 0, -1}, /* P13: Bluetooth (no OC) */ -};