From b97eda4d23739d24da6ee5a99ed2779771cd089c Mon Sep 17 00:00:00 2001 From: Keith Hui Date: Sat, 11 Jan 2025 07:13:01 -0500 Subject: [PATCH] mb/lenovo/t530: Remove old USB configurations As of commit a911b7584820 ("mb/*: Remove old USB configurations from SNB/bd82x6x boards") USB configurations are drawn exclusively from devicetree. These stuff should have been removed then. Drop romstage.c from both variants that only carries the old USB configurations and xhci_overcurrent_mapping devicetree setting that is now derived from usb_port_config (they match). Change-Id: I1a5d57ae9e3788e0c7788013c6fe387ec83efcf2 Signed-off-by: Keith Hui Reviewed-on: https://review.coreboot.org/c/coreboot/+/85943 Reviewed-by: Patrick Rudolph Tested-by: build bot (Jenkins) Reviewed-by: Elyes Haouas --- src/mainboard/lenovo/t530/Makefile.mk | 1 - src/mainboard/lenovo/t530/devicetree.cb | 1 - .../lenovo/t530/variants/t530/romstage.c | 20 ------------------- .../lenovo/t530/variants/w530/romstage.c | 20 ------------------- 4 files changed, 42 deletions(-) delete mode 100644 src/mainboard/lenovo/t530/variants/t530/romstage.c delete mode 100644 src/mainboard/lenovo/t530/variants/w530/romstage.c diff --git a/src/mainboard/lenovo/t530/Makefile.mk b/src/mainboard/lenovo/t530/Makefile.mk index a3b838ba10..69ef08873b 100644 --- a/src/mainboard/lenovo/t530/Makefile.mk +++ b/src/mainboard/lenovo/t530/Makefile.mk @@ -2,7 +2,6 @@ bootblock-y += variants/$(VARIANT_DIR)/gpio.c romstage-y += variants/$(VARIANT_DIR)/gpio.c -romstage-y += variants/$(VARIANT_DIR)/romstage.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/t530/devicetree.cb b/src/mainboard/lenovo/t530/devicetree.cb index 4673aba395..305a47efff 100644 --- a/src/mainboard/lenovo/t530/devicetree.cb +++ b/src/mainboard/lenovo/t530/devicetree.cb @@ -46,7 +46,6 @@ chip northbridge/intel/sandybridge register "xhci_switchable_ports" = "0xf" register "superspeed_capable_ports" = "0xf" - register "xhci_overcurrent_mapping" = "0x04000201" register "docking_supported" = "true" diff --git a/src/mainboard/lenovo/t530/variants/t530/romstage.c b/src/mainboard/lenovo/t530/variants/t530/romstage.c deleted file mode 100644 index 2290bcea13..0000000000 --- a/src/mainboard/lenovo/t530/variants/t530/romstage.c +++ /dev/null @@ -1,20 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0-only */ - -#include - -const struct southbridge_usb_port mainboard_usb_ports[] = { - { 1, 1, 0 }, /* P0: USB double port upper, USB3, OC 0 */ - { 1, 1, 1 }, /* P1: USB double port lower, USB3, (EHCI debug) OC 1 */ - { 1, 2, 3 }, /* P2: Dock, USB3, OC 3 */ - { 1, 1, -1 }, /* P3: WWAN slot, no OC */ - { 1, 1, 2 }, /* P4: yellow USB, OC 2 */ - { 1, 0, -1 }, /* P5: ExpressCard slot, no OC */ - { 0, 0, -1 }, /* P6: empty */ - { 1, 2, -1 }, /* P7: docking, no OC */ - { 1, 0, -1 }, /* P8: smart card reader, no OC */ - { 1, 1, 5 }, /* P9: USB port single (EHCI debug), OC 5 */ - { 1, 0, -1 }, /* P10: fingerprint reader, no OC */ - { 1, 0, -1 }, /* P11: bluetooth, no OC. */ - { 1, 3, -1 }, /* P12: wlan, no OC - disabled in vendor bios*/ - { 1, 1, -1 }, /* P13: camera, no OC */ -}; diff --git a/src/mainboard/lenovo/t530/variants/w530/romstage.c b/src/mainboard/lenovo/t530/variants/w530/romstage.c deleted file mode 100644 index 7458d1ad4d..0000000000 --- a/src/mainboard/lenovo/t530/variants/w530/romstage.c +++ /dev/null @@ -1,20 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0-only */ - -#include - -const struct southbridge_usb_port mainboard_usb_ports[] = { - { 1, 1, 0 }, /* P0: USB double port upper, USB3, OC 0 */ - { 1, 1, 1 }, /* P1: USB double port lower, USB3, (EHCI debug) OC 1 */ - { 1, 2, 3 }, /* P2: Dock, USB3, OC 3 */ - { 1, 1, -1 }, /* P3: WWAN slot, no OC */ - { 1, 1, 2 }, /* P4: yellow USB, OC 2 */ - { 1, 0, -1 }, /* P5: ExpressCard slot, no OC */ - { 1, 0, -1 }, /* P6: color sensor, no OC */ - { 1, 2, -1 }, /* P7: docking, no OC */ - { 1, 0, -1 }, /* P8: smart card reader, no OC */ - { 1, 1, 5 }, /* P9: USB port single (EHCI debug), OC 5 */ - { 1, 0, -1 }, /* P10: fingerprint reader, no OC */ - { 1, 0, -1 }, /* P11: bluetooth, no OC. */ - { 1, 3, -1 }, /* P12: wlan, no OC - disabled in vendor bios*/ - { 1, 1, -1 }, /* P13: camera, no OC */ -};