summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAaron Durbin <adurbin@chromium.org>2020-08-14 16:32:53 -0600
committerAaron Durbin <adurbin@chromium.org>2020-08-17 17:40:31 +0000
commit9bed96eb56e2c31c5321df5f5438e4a91e303323 (patch)
tree5b2cbfa77404f963cf9f749525a7a76bb489f062 /src
parent404a5c3b60f8d27c6e0b3e79f069d281d5df7905 (diff)
downloadcoreboot-9bed96eb56e2c31c5321df5f5438e4a91e303323.tar.xz
soc/amd/common: removed unused functions
Now that all users of the functions manipulating global state and using soc-specific objects are removed remove those functions. BUG=b:159947207 Signed-off-by: Aaron Durbin <adurbin@chromium.org> Change-Id: I18c4c8b0c7852dde8cf0b6b3f11e43e15c3ce155 Reviewed-on: https://review.coreboot.org/c/coreboot/+/44485 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Furquan Shaikh <furquan@google.com>
Diffstat (limited to 'src')
-rw-r--r--src/soc/amd/common/block/acpi/acpi.c37
-rw-r--r--src/soc/amd/common/block/include/amdblocks/acpi.h2
2 files changed, 0 insertions, 39 deletions
diff --git a/src/soc/amd/common/block/acpi/acpi.c b/src/soc/amd/common/block/acpi/acpi.c
index 0e6dabf150..17c0ed16c7 100644
--- a/src/soc/amd/common/block/acpi/acpi.c
+++ b/src/soc/amd/common/block/acpi/acpi.c
@@ -4,7 +4,6 @@
#include <amdblocks/acpi.h>
#include <acpi/acpi.h>
#include <bootmode.h>
-#include <cbmem.h>
#include <console/console.h>
#include <elog.h>
#include <halt.h>
@@ -25,13 +24,6 @@ void poweroff(void)
halt();
}
-static uint16_t reset_pm1_status(void)
-{
- uint16_t pm1_sts = acpi_read16(MMIO_ACPI_PM1_STS);
- acpi_write16(MMIO_ACPI_PM1_STS, pm1_sts);
- return pm1_sts;
-}
-
static void print_num_status_bits(int num_bits, uint32_t status,
const char *const bit_names[])
{
@@ -151,35 +143,6 @@ void acpi_fill_gnvs(struct global_nvs *gnvs, const struct acpi_pm_gpe_state *sta
gnvs->gpei = index;
}
-static void save_sws(uint16_t pm1_status)
-{
- struct soc_power_reg *sws;
- uint32_t reg32;
- uint16_t reg16;
-
- sws = cbmem_add(CBMEM_ID_POWER_STATE, sizeof(struct soc_power_reg));
- if (sws == NULL)
- return;
- sws->pm1_sts = pm1_status;
- sws->pm1_en = acpi_read16(MMIO_ACPI_PM1_EN);
- reg32 = acpi_read32(MMIO_ACPI_GPE0_STS);
- acpi_write32(MMIO_ACPI_GPE0_STS, reg32);
- sws->gpe0_sts = reg32;
- sws->gpe0_en = acpi_read32(MMIO_ACPI_GPE0_EN);
- reg16 = acpi_read16(MMIO_ACPI_PM1_CNT_BLK);
- reg16 &= SLP_TYP;
- sws->wake_from = reg16 >> SLP_TYP_SHIFT;
-}
-
-void acpi_clear_pm1_status(void)
-{
- uint16_t pm1_sts = reset_pm1_status();
-
- save_sws(pm1_sts);
- log_pm1_status(pm1_sts);
- print_pm1_status(pm1_sts);
-}
-
int acpi_get_sleep_type(void)
{
return acpi_sleep_from_pm1(acpi_read16(MMIO_ACPI_PM1_CNT_BLK));
diff --git a/src/soc/amd/common/block/include/amdblocks/acpi.h b/src/soc/amd/common/block/include/amdblocks/acpi.h
index 8d0e5f664e..b6244cb70d 100644
--- a/src/soc/amd/common/block/include/amdblocks/acpi.h
+++ b/src/soc/amd/common/block/include/amdblocks/acpi.h
@@ -36,8 +36,6 @@ void acpi_clear_pm_gpe_status(void);
/* Fill GNVS object from PM GPE object. */
void acpi_fill_gnvs(struct global_nvs *gnvs, const struct acpi_pm_gpe_state *state);
-void acpi_clear_pm1_status(void);
-
/*
* If a system reset is about to be requested, modify the PM1 register so it
* will never be misinterpreted as an S3 resume.