x86: Remove HAVE_ACPI_RESUME
authorBin Meng <bmeng.cn@gmail.com>
Thu, 26 Nov 2015 01:46:09 +0000 (17:46 -0800)
committerBin Meng <bmeng.cn@gmail.com>
Wed, 9 Dec 2015 09:44:56 +0000 (17:44 +0800)
These are currently dead codes. Until we have complete ACPI support,
we don't know if it works or not. Remove to avoid confusion.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Acked-by: Simon Glass <sjg@chromium.org>
Tested-by: Simon Glass <sjg@chromium.org>
arch/x86/cpu/ivybridge/cpu.c
arch/x86/cpu/ivybridge/lpc.c
arch/x86/cpu/ivybridge/northbridge.c
board/google/chromebook_link/Kconfig
board/google/chromebox_panther/Kconfig
drivers/pci/pci_rom.c

index 03874448a613e100f5175a1153a95d6fbfa1826e..343bfb4e98e264a7e5fa91f7e9f58c89427f73f3 100644 (file)
@@ -298,16 +298,7 @@ int print_cpuinfo(void)
        pm1_cnt = inl(DEFAULT_PMBASE + PM1_CNT);
 
        if ((pm1_sts & WAK_STS) && ((pm1_cnt >> 10) & 7) == 5) {
-#if CONFIG_HAVE_ACPI_RESUME
-               debug("Resume from S3 detected.\n");
-               boot_mode = PEI_BOOT_RESUME;
-               /* Clear SLP_TYPE. This will break stage2 but
-                * we care for that when we get there.
-                */
-               outl(pm1_cnt & ~(7 << 10), DEFAULT_PMBASE + PM1_CNT);
-#else
                debug("Resume from S3 detected, but disabled.\n");
-#endif
        } else {
                /*
                 * TODO: An indication of life might be possible here (e.g.
index 3efd3e841f4e8f1c7696664ac7efc33dad54a839..af5d4a89089bad99778d5aef6799af6781143e86 100644 (file)
@@ -240,15 +240,6 @@ static void pch_rtc_init(pci_dev_t dev)
        }
        debug("rtc_failed = 0x%x\n", rtc_failed);
 
-#if CONFIG_HAVE_ACPI_RESUME
-       /* Avoid clearing pending interrupts and resetting the RTC control
-        * register in the resume path because the Linux kernel relies on
-        * this to know if it should restart the RTC timerqueue if the wake
-        * was due to the RTC alarm.
-        */
-       if (acpi_get_slp_type() == 3)
-               return;
-#endif
        /* TODO: Handle power failure */
        if (rtc_failed)
                printf("RTC power failed\n");
index e95e60e5190ea70274b5c18783aaa6a10419635e..e3d8c139dfda3a3d6472a00f69b2f990b076537c 100644 (file)
@@ -169,20 +169,4 @@ void northbridge_init(pci_dev_t dev)
 
 void northbridge_enable(pci_dev_t dev)
 {
-#if CONFIG_HAVE_ACPI_RESUME
-       switch (x86_pci_read_config32(dev, SKPAD)) {
-       case 0xcafebabe:
-               debug("Normal boot.\n");
-               apci_set_slp_type(0);
-               break;
-       case 0xcafed00d:
-               debug("S3 Resume.\n");
-               apci_set_slp_type(3);
-               break;
-       default:
-               debug("Unknown boot method, assuming normal.\n");
-               apci_set_slp_type(0);
-               break;
-       }
-#endif
 }
index ce976db8b0fb471ad71f4ccbf2dc8fe4854c681c..6b139392b56dd40e65a5f01d5f7de9606ce92737 100644 (file)
@@ -19,7 +19,6 @@ config BOARD_SPECIFIC_OPTIONS # dummy
        def_bool y
        select X86_RESET_VECTOR
        select NORTHBRIDGE_INTEL_IVYBRIDGE
-       select HAVE_ACPI_RESUME
        select BOARD_ROMSIZE_KB_8192
 
 config PCIE_ECAM_BASE
index c1cf89cbebe8bc0744141a154181ca8f3c7beec7..ae96d23d0306a40228842aeca22b347b90169927 100644 (file)
@@ -20,7 +20,6 @@ config BOARD_SPECIFIC_OPTIONS # dummy
        def_bool y
        select X86_RESET_VECTOR
        select NORTHBRIDGE_INTEL_IVYBRIDGE
-       select HAVE_ACPI_RESUME
        select BOARD_ROMSIZE_KB_8192
 
 config SYS_CAR_ADDR
index d2445438a6ccd3c58517d969c21566a82767b165..ad1167e2b65ad436824132eaf2d671b683d3151c 100644 (file)
 #include <video_fb.h>
 #include <linux/screen_info.h>
 
-#ifdef CONFIG_HAVE_ACPI_RESUME
-#include <asm/acpi.h>
-#endif
-
 __weak bool board_should_run_oprom(pci_dev_t dev)
 {
        return true;
@@ -44,10 +40,6 @@ __weak bool board_should_run_oprom(pci_dev_t dev)
 
 static bool should_load_oprom(pci_dev_t dev)
 {
-#ifdef CONFIG_HAVE_ACPI_RESUME
-       if (acpi_get_slp_type() == 3)
-               return false;
-#endif
        if (IS_ENABLED(CONFIG_ALWAYS_LOAD_OPROM))
                return 1;
        if (board_should_run_oprom(dev))