drivers/amd/opensil/acpi.c: Factor common ACPI calls to openSIL driver
Refactor to factor out and route ACPI calls through the openSIL driver interface to separate main SoC code from vendorcode. Change-Id: I9fa4f60164333ec7a268702fa3e94979a1b83594 Signed-off-by: Nicolas Kochlowski <nickkochlowski@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/85633 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
This commit is contained in:
parent
c6f82a8432
commit
6c8913ee20
8 changed files with 38 additions and 10 deletions
|
|
@ -5,9 +5,10 @@
|
|||
#include <SilCommon.h>
|
||||
#include <xSIM-api.h>
|
||||
#include <FCH/Common/FchCommonCfg.h>
|
||||
|
||||
#include "../opensil.h"
|
||||
|
||||
void opensil_fill_fadt_io_ports(acpi_fadt_t *fadt)
|
||||
void opensil_fill_fadt(acpi_fadt_t *fadt)
|
||||
{
|
||||
FCHHWACPI_INPUT_BLK *blk = SilFindStructure(SilId_FchHwAcpiP, 0);
|
||||
|
||||
|
|
@ -16,3 +17,8 @@ void opensil_fill_fadt_io_ports(acpi_fadt_t *fadt)
|
|||
fadt->pm_tmr_blk = blk->AcpiPmTmrBlkAddr;
|
||||
fadt->gpe0_blk = blk->AcpiGpe0BlkAddr;
|
||||
}
|
||||
|
||||
unsigned long add_opensil_acpi_table(unsigned long current, acpi_rsdp_t *rsdp)
|
||||
{
|
||||
return current;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@
|
|||
void SIL_STATUS_report(const char *function, const int status);
|
||||
// Add the memory map to dev, starting at index idx, returns last use idx
|
||||
void add_opensil_memmap(struct device *dev, unsigned long *idx);
|
||||
// Fill in FADT from openSIL
|
||||
void opensil_fill_fadt_io_ports(acpi_fadt_t *fadt);
|
||||
|
||||
void opensil_fill_fadt(acpi_fadt_t *fadt);
|
||||
unsigned long add_opensil_acpi_table(unsigned long current, acpi_rsdp_t *rsdp);
|
||||
|
||||
void setup_opensil(void);
|
||||
void opensil_xSIM_timepoint_1(void);
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0-only */
|
||||
|
||||
#include <acpi/acpi.h>
|
||||
#include <amdblocks/acpi.h>
|
||||
#include <device/device.h>
|
||||
|
||||
#include "../opensil.h"
|
||||
|
||||
void add_opensil_memmap(struct device *dev, unsigned long *idx)
|
||||
|
|
@ -10,12 +10,12 @@ void add_opensil_memmap(struct device *dev, unsigned long *idx)
|
|||
printk(BIOS_NOTICE, "openSIL stub: %s\n", __func__);
|
||||
}
|
||||
|
||||
void opensil_fill_fadt_io_ports(acpi_fadt_t *fadt)
|
||||
void opensil_fill_fadt(acpi_fadt_t *fadt)
|
||||
{
|
||||
printk(BIOS_NOTICE, "openSIL stub: %s\n", __func__);
|
||||
}
|
||||
|
||||
unsigned long acpi_add_opensil_tables(unsigned long current, acpi_rsdp_t *rsdp)
|
||||
unsigned long add_opensil_acpi_table(unsigned long current, acpi_rsdp_t *rsdp)
|
||||
{
|
||||
printk(BIOS_NOTICE, "openSIL stub: %s\n", __func__);
|
||||
return current;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue