Tom Rini | 83d290c | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | # SPDX-License-Identifier: GPL-2.0+ |
wdenk | 2262cfe | 2002-11-18 00:14:45 +0000 | [diff] [blame] | 2 | # |
Marian Balakowicz | f932863 | 2006-09-01 19:49:50 +0200 | [diff] [blame] | 3 | # (C) Copyright 2002-2006 |
wdenk | 2262cfe | 2002-11-18 00:14:45 +0000 | [diff] [blame] | 4 | # Wolfgang Denk, DENX Software Engineering, wd@denx.de. |
wdenk | 2262cfe | 2002-11-18 00:14:45 +0000 | [diff] [blame] | 5 | |
Simon Glass | 567dfef | 2021-09-24 18:30:21 -0600 | [diff] [blame] | 6 | obj-y += bdinfo.o |
Simon Glass | 5345700 | 2023-07-15 21:38:58 -0600 | [diff] [blame] | 7 | |
Simon Glass | 5c10c8b | 2024-09-29 19:49:54 -0600 | [diff] [blame] | 8 | ifndef CONFIG_$(PHASE_)X86_64 |
Simon Glass | 0ca2426 | 2014-11-14 20:56:32 -0700 | [diff] [blame] | 9 | obj-y += bios.o |
10 | obj-y += bios_asm.o | ||||
11 | obj-y += bios_interrupts.o | ||||
Simon Glass | fb96dee | 2019-12-06 21:42:23 -0700 | [diff] [blame] | 12 | endif |
Simon Glass | 5345700 | 2023-07-15 21:38:58 -0600 | [diff] [blame] | 13 | |
Simon Glass | bef9fdb | 2024-09-29 19:49:46 -0600 | [diff] [blame] | 14 | ifndef CONFIG_XPL_BUILD |
Simon Glass | b194e43 | 2023-05-04 16:50:52 -0600 | [diff] [blame] | 15 | obj-$(CONFIG_X86_32BIT_INIT) += string.o |
Simon Glass | 05cbd98 | 2017-01-16 07:04:09 -0700 | [diff] [blame] | 16 | endif |
Simon Glass | 5345700 | 2023-07-15 21:38:58 -0600 | [diff] [blame] | 17 | |
Simon Glass | bef9fdb | 2024-09-29 19:49:46 -0600 | [diff] [blame] | 18 | ifndef CONFIG_XPL_BUILD |
Tom Rini | cdd20e3 | 2024-04-18 08:29:35 -0600 | [diff] [blame] | 19 | obj-$(CONFIG_CMD_BOOTM) += bootm.o |
Simon Glass | ca5114f | 2017-01-16 07:04:13 -0700 | [diff] [blame] | 20 | endif |
Masahiro Yamada | 3954b73 | 2013-10-21 11:53:34 +0900 | [diff] [blame] | 21 | obj-y += cmd_boot.o |
Simon Glass | c46760d | 2024-09-29 19:49:53 -0600 | [diff] [blame] | 22 | obj-$(CONFIG_$(XPL_)COREBOOT_SYSINFO) += coreboot/ |
Bin Meng | 5483449 | 2016-05-11 07:44:58 -0700 | [diff] [blame] | 23 | obj-$(CONFIG_SEABIOS) += coreboot_table.o |
Bin Meng | 9f1fad1 | 2017-04-21 07:24:38 -0700 | [diff] [blame] | 24 | obj-y += early_cmos.o |
Bin Meng | 59ec719 | 2015-10-07 20:19:10 -0700 | [diff] [blame] | 25 | obj-y += e820.o |
Masahiro Yamada | 3954b73 | 2013-10-21 11:53:34 +0900 | [diff] [blame] | 26 | obj-y += init_helpers.o |
27 | obj-y += interrupts.o | ||||
Simon Glass | a274e9c | 2015-03-26 09:29:28 -0600 | [diff] [blame] | 28 | obj-y += lpc-uclass.o |
Bin Meng | 7f5df8d | 2015-06-23 12:18:51 +0800 | [diff] [blame] | 29 | obj-y += mpspec.o |
Simon Glass | 5c10c8b | 2024-09-29 19:49:54 -0600 | [diff] [blame] | 30 | obj-$(CONFIG_$(PHASE_)ACPIGEN) += acpi_nhlt.o |
Simon Glass | 5544757 | 2016-01-17 16:11:14 -0700 | [diff] [blame] | 31 | obj-y += northbridge-uclass.o |
Bin Meng | da3fe24 | 2015-10-22 19:13:30 -0700 | [diff] [blame] | 32 | obj-$(CONFIG_I8259_PIC) += i8259.o |
33 | obj-$(CONFIG_I8254_TIMER) += i8254.o | ||||
Bin Meng | fcfc8a8 | 2018-06-10 06:25:01 -0700 | [diff] [blame] | 34 | obj-$(CONFIG_PINCTRL_ICH6) += pinctrl_ich6.o |
Bin Meng | b5b6b01 | 2015-04-24 18:10:05 +0800 | [diff] [blame] | 35 | obj-y += pirq_routing.o |
Masahiro Yamada | 3954b73 | 2013-10-21 11:53:34 +0900 | [diff] [blame] | 36 | obj-y += relocate.o |
37 | obj-y += physmem.o | ||||
Andy Shevchenko | ca0d29e | 2017-04-01 16:21:34 +0300 | [diff] [blame] | 38 | obj-$(CONFIG_INTEL_MID) += pmu.o |
Simon Glass | 65dd74a | 2014-11-12 22:42:28 -0700 | [diff] [blame] | 39 | obj-$(CONFIG_X86_RAMTEST) += ramtest.o |
Felipe Balbi | bb41646 | 2017-04-01 16:21:33 +0300 | [diff] [blame] | 40 | obj-$(CONFIG_INTEL_MID) += scu.o |
Simon Glass | 65e4c0b | 2016-09-25 15:27:35 -0600 | [diff] [blame] | 41 | obj-y += sections.o |
Simon Glass | 6388e35 | 2015-04-28 20:25:10 -0600 | [diff] [blame] | 42 | obj-y += sfi.o |
Bin Meng | a0609a8 | 2018-07-18 21:42:15 -0700 | [diff] [blame] | 43 | obj-y += acpi.o |
Bin Meng | 3a34cae | 2017-04-21 07:24:37 -0700 | [diff] [blame] | 44 | obj-$(CONFIG_HAVE_ACPI_RESUME) += acpi_s3.o |
Miao Yan | 34865a6 | 2016-05-22 19:37:10 -0700 | [diff] [blame] | 45 | ifndef CONFIG_QEMU |
Simon Glass | 60c0231 | 2020-09-22 12:45:21 -0600 | [diff] [blame] | 46 | obj-y += acpigen.o |
Simon Glass | 5c10c8b | 2024-09-29 19:49:54 -0600 | [diff] [blame] | 47 | obj-$(CONFIG_$(PHASE_)GENERATE_ACPI_TABLE) += acpi_table.o |
Miao Yan | fa287b1 | 2016-01-20 01:57:06 -0800 | [diff] [blame] | 48 | endif |
Bin Meng | 5e2400e | 2015-04-24 18:10:04 +0800 | [diff] [blame] | 49 | obj-y += tables.o |
Simon Glass | bef9fdb | 2024-09-29 19:49:46 -0600 | [diff] [blame] | 50 | ifndef CONFIG_XPL_BUILD |
Simon Glass | 80d4c98 | 2023-12-03 17:29:28 -0700 | [diff] [blame] | 51 | obj-$(CONFIG_ZBOOT) += zimage.o |
Simon Glass | ca5114f | 2017-01-16 07:04:13 -0700 | [diff] [blame] | 52 | endif |
Park, Aiden | 7165fd5 | 2019-08-03 08:30:31 +0000 | [diff] [blame] | 53 | obj-$(CONFIG_USE_HOB) += hob.o |
Tom Rini | c87f9ce | 2020-06-26 17:40:06 -0400 | [diff] [blame] | 54 | ifndef CONFIG_TPL_BUILD |
55 | obj-$(CONFIG_ENABLE_MRC_CACHE) += mrccache.o | ||||
Simon Glass | e9de4a7 | 2019-08-24 14:10:32 -0600 | [diff] [blame] | 56 | obj-$(CONFIG_HAVE_FSP) += fsp/ |
Simon Glass | 8331188 | 2019-09-25 08:00:11 -0600 | [diff] [blame] | 57 | obj-$(CONFIG_FSP_VERSION1) += fsp1/ |
58 | obj-$(CONFIG_FSP_VERSION2) += fsp2/ | ||||
Tom Rini | c87f9ce | 2020-06-26 17:40:06 -0400 | [diff] [blame] | 59 | endif |
Simon Glass | 7c03caf | 2019-05-02 10:52:12 -0600 | [diff] [blame] | 60 | |
Simon Glass | bef9fdb | 2024-09-29 19:49:46 -0600 | [diff] [blame] | 61 | ifdef CONFIG_XPL_BUILD |
Simon Glass | 7c03caf | 2019-05-02 10:52:12 -0600 | [diff] [blame] | 62 | ifdef CONFIG_TPL_BUILD |
63 | obj-y += tpl.o | ||||
64 | else | ||||
65 | obj-y += spl.o | ||||
66 | endif | ||||
67 | endif | ||||
wdenk | 2262cfe | 2002-11-18 00:14:45 +0000 | [diff] [blame] | 68 | |
Stefan Roese | aa7839b | 2017-11-29 16:23:31 +0100 | [diff] [blame] | 69 | lib-$(CONFIG_USE_PRIVATE_LIBGCC) += div64.o |
Simon Glass | 2dcd4e9 | 2016-11-07 08:47:14 -0700 | [diff] [blame] | 70 | |
Simon Glass | 450ce56 | 2022-01-04 03:51:13 -0700 | [diff] [blame] | 71 | obj-$(CONFIG_EFI_APP_32BIT) += crt0_ia32_efi.o reloc_ia32_efi.o |
72 | obj-$(CONFIG_EFI_APP_64BIT) += crt0_x86_64_efi.o reloc_x86_64_efi.o | ||||
Simon Glass | 2dcd4e9 | 2016-11-07 08:47:14 -0700 | [diff] [blame] | 73 | |
74 | ifneq ($(CONFIG_EFI_STUB),) | ||||
75 | |||||
76 | CFLAGS_REMOVE_reloc_ia32_efi.o += -mregparm=3 | ||||
77 | CFLAGS_reloc_ia32_efi.o += -fpic -fshort-wchar | ||||
78 | |||||
79 | # When building for 64-bit we must remove the i386-specific flags | ||||
80 | CFLAGS_REMOVE_reloc_x86_64_efi.o += -mregparm=3 -march=i386 -m32 | ||||
Bin Meng | 16dde89 | 2018-06-10 06:25:03 -0700 | [diff] [blame] | 81 | CFLAGS_reloc_x86_64_efi.o += -fpic -fshort-wchar -m64 |
Simon Glass | 2dcd4e9 | 2016-11-07 08:47:14 -0700 | [diff] [blame] | 82 | |
83 | AFLAGS_REMOVE_crt0_x86_64_efi.o += -mregparm=3 -march=i386 -m32 | ||||
Bin Meng | 16dde89 | 2018-06-10 06:25:03 -0700 | [diff] [blame] | 84 | AFLAGS_crt0_x86_64_efi.o += -fpic -fshort-wchar -m64 |
Simon Glass | 2dcd4e9 | 2016-11-07 08:47:14 -0700 | [diff] [blame] | 85 | |
86 | extra-$(CONFIG_EFI_STUB_32BIT) += crt0_ia32_efi.o reloc_ia32_efi.o | ||||
87 | extra-$(CONFIG_EFI_STUB_64BIT) += crt0_x86_64_efi.o reloc_x86_64_efi.o | ||||
Simon Glass | 5bd828b | 2016-11-07 08:47:15 -0700 | [diff] [blame] | 88 | |
89 | endif | ||||
90 | |||||
Heinrich Schuchardt | f2560e2 | 2018-05-18 19:12:20 +0200 | [diff] [blame] | 91 | ifdef CONFIG_EFI_STUB |
92 | |||||
Simon Glass | c46760d | 2024-09-29 19:49:53 -0600 | [diff] [blame] | 93 | ifeq ($(CONFIG_$(XPL_)X86_64),) |
Simon Glass | 5bd828b | 2016-11-07 08:47:15 -0700 | [diff] [blame] | 94 | extra-y += $(EFI_CRT0) $(EFI_RELOC) |
Simon Glass | 2dcd4e9 | 2016-11-07 08:47:14 -0700 | [diff] [blame] | 95 | endif |
Heinrich Schuchardt | f2560e2 | 2018-05-18 19:12:20 +0200 | [diff] [blame] | 96 | |
97 | else | ||||
98 | |||||
Simon Glass | bef9fdb | 2024-09-29 19:49:46 -0600 | [diff] [blame] | 99 | ifndef CONFIG_XPL_BUILD |
Heinrich Schuchardt | f2560e2 | 2018-05-18 19:12:20 +0200 | [diff] [blame] | 100 | ifneq ($(CONFIG_CMD_BOOTEFI_SELFTEST)$(CONFIG_CMD_BOOTEFI_HELLO_COMPILE),) |
101 | extra-y += $(EFI_CRT0) $(EFI_RELOC) | ||||
102 | endif | ||||
103 | endif | ||||
104 | |||||
Simon Glass | e1b610b | 2017-01-16 07:04:12 -0700 | [diff] [blame] | 105 | endif |