summaryrefslogtreecommitdiff
path: root/src/mainboard/samsung
diff options
context:
space:
mode:
authorKeith Hui <buurin@gmail.com>2023-03-20 02:03:47 -0400
committerFelix Held <felix-coreboot@felixheld.de>2023-03-23 15:14:45 +0000
commitc5d6af43fb544423fa103f523ac85356b3ff3725 (patch)
tree8cf30f87ba30b1e3334b4546dddd69dbd8b2ffdd /src/mainboard/samsung
parent0e1be046acaf5cfb9e2c41521270d137fa3423c5 (diff)
nb/intel/snb: Abolish mainboard_should_reset_usb()
Of the 13 mainboards that implement mainboard_should_reset_usb() hook, all but one do the same: Stop MRC from resetting USB when resuming from S3 suspend. This hook turns out is only here to facilitate a USB reset workaround on samsung/stumpy for an old ChromeOS kernel which is no longer needed. Drop the workaround, the hook, and headers no longer used. roda/rv11/early_init.c is left with no useful code after this patch, so drop it entirely from both bootblock and romstage. Change-Id: Ib3a5a00c0a6b1528e39435784919223d16b3914e Signed-off-by: Keith Hui <buurin@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/72496 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Diffstat (limited to 'src/mainboard/samsung')
-rw-r--r--src/mainboard/samsung/lumpy/early_init.c5
-rw-r--r--src/mainboard/samsung/stumpy/cmos.layout3
-rw-r--r--src/mainboard/samsung/stumpy/early_init.c34
3 files changed, 0 insertions, 42 deletions
diff --git a/src/mainboard/samsung/lumpy/early_init.c b/src/mainboard/samsung/lumpy/early_init.c
index fd0f9448eb..3f515ec374 100644
--- a/src/mainboard/samsung/lumpy/early_init.c
+++ b/src/mainboard/samsung/lumpy/early_init.c
@@ -181,8 +181,3 @@ void mainboard_get_spd(spd_raw_data *spd, bool id_only)
/* read removable dimm spd */
read_spd(&spd[0], 0x50, id_only);
}
-
-int mainboard_should_reset_usb(int s3resume)
-{
- return !s3resume;
-}
diff --git a/src/mainboard/samsung/stumpy/cmos.layout b/src/mainboard/samsung/stumpy/cmos.layout
index f1fb849f68..1f2e8d5eee 100644
--- a/src/mainboard/samsung/stumpy/cmos.layout
+++ b/src/mainboard/samsung/stumpy/cmos.layout
@@ -15,9 +15,6 @@ entries
# coreboot config options: console
395 4 e 6 debug_level
-# Stumpy USB reset workaround disable
-400 8 r 0 stumpy_usb_reset_disable
-
# coreboot config options: southbridge
408 1 e 1 nmi
409 2 e 7 power_on_after_fail
diff --git a/src/mainboard/samsung/stumpy/early_init.c b/src/mainboard/samsung/stumpy/early_init.c
index 97f656af4d..14fc2528d9 100644
--- a/src/mainboard/samsung/stumpy/early_init.c
+++ b/src/mainboard/samsung/stumpy/early_init.c
@@ -15,15 +15,6 @@
#include <southbridge/intel/common/gpio.h>
#include <superio/smsc/lpc47n207/lpc47n207.h>
-/* Stumpy USB Reset Disable defined in cmos.layout */
-#if CONFIG(USE_OPTION_TABLE)
-#include "option_table.h"
-#define CMOS_USB_RESET_DISABLE (CMOS_VSTART_stumpy_usb_reset_disable >> 3)
-#else
-#define CMOS_USB_RESET_DISABLE (400 >> 3)
-#endif
-#define USB_RESET_DISABLE_MAGIC (0xdd) /* Disable if set to this */
-
#define SUPERIO_DEV PNP_DEV(0x2e, 0)
#define SERIAL_DEV PNP_DEV(0x2e, IT8772F_SP1)
#define GPIO_DEV PNP_DEV(0x2e, IT8772F_GPIO)
@@ -164,31 +155,6 @@ const struct southbridge_usb_port mainboard_usb_ports[] = {
{ 1, 0, 5 }, /* P13: Back port (OC5) */
};
-int mainboard_should_reset_usb(int s3resume)
-{
- if (s3resume) {
- /*
- * For Stumpy the back USB ports are reset on resume
- * so default to resetting the controller to make the
- * kernel happy. There is a CMOS flag to disable the
- * controller reset in case the kernel can tolerate
- * the device power loss better in the future.
- */
- u8 magic = cmos_read(CMOS_USB_RESET_DISABLE);
- if (magic == USB_RESET_DISABLE_MAGIC) {
- printk(BIOS_DEBUG, "USB Controller Reset Disabled\n");
- return 0;
- } else {
- printk(BIOS_DEBUG, "USB Controller Reset Enabled\n");
- return 1;
- }
- } else {
- /* Ensure USB reset on resume is enabled at boot */
- cmos_write(0, CMOS_USB_RESET_DISABLE);
- return 1;
- }
-}
-
void bootblock_mainboard_early_init(void)
{
if (CONFIG(DRIVERS_UART_8250IO))