diff options
author | Arthur Heymans <arthur@aheymans.xyz> | 2023-04-25 16:07:49 +0200 |
---|---|---|
committer | Lean Sheng Tan <sheng.tan@9elements.com> | 2023-04-26 08:40:14 +0000 |
commit | 9368cf90255daeb53765d442a639f86ee5be1f29 (patch) | |
tree | d0f3e0b567fb9adc6ba1e0ae1134c7474b7f1ce5 /src | |
parent | 323a0ae2b143cf95cc815ec1a94b528017e7db36 (diff) |
acpi/acpi.c: Reduce scope of some functions
These functions are only used in one compilation unit.
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Change-Id: I6f8282f308506a68b14ce3101f11078cb13709f2
Reviewed-on: https://review.coreboot.org/c/coreboot/+/74756
Reviewed-by: Jan Samek <jan.samek@siemens.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Maximilian Brune <maximilian.brune@9elements.com>
Reviewed-by: Tim Wawrzynczak <inforichland@gmail.com>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed-by: Lean Sheng Tan <sheng.tan@9elements.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/acpi/acpi.c | 18 | ||||
-rw-r--r-- | src/include/acpi/acpi.h | 16 |
2 files changed, 9 insertions, 25 deletions
diff --git a/src/acpi/acpi.c b/src/acpi/acpi.c index fb9a758fb0..25409295fc 100644 --- a/src/acpi/acpi.c +++ b/src/acpi/acpi.c @@ -288,7 +288,7 @@ unsigned long acpi_create_madt_lapics_with_nmis(unsigned long current) return current; } -void acpi_create_madt(acpi_madt_t *madt) +static void acpi_create_madt(acpi_madt_t *madt) { acpi_header_t *header = &(madt->header); unsigned long current = (unsigned long)madt + sizeof(acpi_madt_t); @@ -333,7 +333,7 @@ static unsigned long acpi_fill_mcfg(unsigned long current) } /* MCFG is defined in the PCI Firmware Specification 3.0. */ -void acpi_create_mcfg(acpi_mcfg_t *mcfg) +static void acpi_create_mcfg(acpi_mcfg_t *mcfg) { acpi_header_t *header = &(mcfg->header); unsigned long current = (unsigned long)mcfg + sizeof(acpi_mcfg_t); @@ -517,7 +517,7 @@ static void acpi_ssdt_write_cbtable(void) acpigen_pop_len(); } -void acpi_create_ssdt_generator(acpi_header_t *ssdt, const char *oem_table_id) +static void acpi_create_ssdt_generator(acpi_header_t *ssdt, const char *oem_table_id) { unsigned long current = (unsigned long)ssdt + sizeof(acpi_header_t); @@ -989,7 +989,7 @@ void acpi_create_slit(acpi_slit_t *slit, } /* http://www.intel.com/hardwaredesign/hpetspec_1.pdf */ -void acpi_create_hpet(acpi_hpet_t *hpet) +static void acpi_create_hpet(acpi_hpet_t *hpet) { acpi_header_t *header = &(hpet->header); acpi_addr_t *addr = &(hpet->addr); @@ -1330,7 +1330,7 @@ unsigned long acpi_write_hpet(const struct device *device, unsigned long current return current; } -void acpi_create_dbg2(acpi_dbg2_header_t *dbg2, +static void acpi_create_dbg2(acpi_dbg2_header_t *dbg2, int port_type, int port_subtype, acpi_addr_t *address, uint32_t address_size, const char *device_path) @@ -1451,7 +1451,7 @@ unsigned long acpi_write_dbg2_pci_uart(acpi_rsdp_t *rsdp, unsigned long current, return current; } -void acpi_create_facs(acpi_facs_t *facs) +static void acpi_create_facs(acpi_facs_t *facs) { memset((void *)facs, 0, sizeof(acpi_facs_t)); @@ -1628,7 +1628,7 @@ void acpi_write_hest(acpi_hest_t *hest, } /* ACPI 3.0b */ -void acpi_write_bert(acpi_bert_t *bert, uintptr_t region, size_t length) +static void acpi_write_bert(acpi_bert_t *bert, uintptr_t region, size_t length) { acpi_header_t *header = &(bert->header); @@ -1656,7 +1656,7 @@ __weak void arch_fill_fadt(acpi_fadt_t *fadt) { } __weak void soc_fill_fadt(acpi_fadt_t *fadt) { } __weak void mainboard_fill_fadt(acpi_fadt_t *fadt) { } -void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt) +static void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt) { acpi_header_t *header = &(fadt->header); @@ -1709,7 +1709,7 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt) acpi_checksum((void *)fadt, header->length); } -void acpi_create_lpit(acpi_lpit_t *lpit) +static void acpi_create_lpit(acpi_lpit_t *lpit) { acpi_header_t *header = &(lpit->header); unsigned long current = (unsigned long)lpit + sizeof(acpi_lpit_t); diff --git a/src/include/acpi/acpi.h b/src/include/acpi/acpi.h index 77f73ae358..58db58cdd0 100644 --- a/src/include/acpi/acpi.h +++ b/src/include/acpi/acpi.h @@ -1308,9 +1308,6 @@ void preload_acpi_dsdt(void); unsigned long write_acpi_tables(unsigned long addr); unsigned long acpi_fill_madt(unsigned long current); unsigned long acpi_fill_ivrs_ioapic(acpi_ivrs_t *ivrs, unsigned long current); -void acpi_create_ssdt_generator(acpi_header_t *ssdt, const char *oem_table_id); -void acpi_write_bert(acpi_bert_t *bert, uintptr_t region, size_t length); -void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt); void acpi_fill_fadt(acpi_fadt_t *fadt); void arch_fill_fadt(acpi_fadt_t *fadt); @@ -1342,8 +1339,6 @@ int acpi_create_madt_ioapic_from_hw(acpi_madt_ioapic_t *ioapic, u32 addr); int acpi_create_madt_irqoverride(acpi_madt_irqoverride_t *irqoverride, u8 bus, u8 source, u32 gsirq, u16 flags); -void acpi_create_madt(acpi_madt_t *madt); - unsigned long acpi_create_madt_one_lapic(unsigned long current, u32 cpu, u32 apic); unsigned long acpi_create_madt_lapics_with_nmis(unsigned long current); @@ -1401,22 +1396,12 @@ void acpi_create_crat(struct acpi_crat_header *crat, unsigned long (*acpi_fill_crat)(struct acpi_crat_header *crat_struct, unsigned long current)); -void acpi_create_hpet(acpi_hpet_t *hpet); unsigned long acpi_write_hpet(const struct device *device, unsigned long start, acpi_rsdp_t *rsdp); /* cpu/intel/speedstep/acpi.c */ void generate_cpu_entries(const struct device *device); -void acpi_create_mcfg(acpi_mcfg_t *mcfg); - -void acpi_create_facs(acpi_facs_t *facs); - -void acpi_create_dbg2(acpi_dbg2_header_t *dbg2_header, - int port_type, int port_subtype, - acpi_addr_t *address, uint32_t address_size, - const char *device_path); - unsigned long acpi_write_dbg2_pci_uart(acpi_rsdp_t *rsdp, unsigned long current, const struct device *dev, uint8_t access_size); void acpi_create_dmar(acpi_dmar_t *dmar, enum dmar_flags flags, @@ -1455,7 +1440,6 @@ void acpi_write_hest(acpi_hest_t *hest, unsigned long acpi_create_hest_error_source(acpi_hest_t *hest, acpi_hest_esd_t *esd, u16 type, void *data, u16 len); -void acpi_create_lpit(acpi_lpit_t *lpit); unsigned long acpi_create_lpi_desc_ncst(acpi_lpi_desc_ncst_t *lpi_desc, uint16_t uid); /* chipsets that select ACPI_BERT must implement this function */ |