Subrata Banik has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/33115
Change subject: Makefile.inc: Exclude smm related files from ramstage compilation ......................................................................
Makefile.inc: Exclude smm related files from ramstage compilation
Change-Id: I17a3eb80a4d5ef86e0319357c01b6bf5b90ef15b Signed-off-by: Subrata Banik subrata.banik@intel.com --- M src/arch/x86/Makefile.inc 1 file changed, 17 insertions(+), 12 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/15/33115/1
diff --git a/src/arch/x86/Makefile.inc b/src/arch/x86/Makefile.inc index 7e518d8..0ad5d3e 100644 --- a/src/arch/x86/Makefile.inc +++ b/src/arch/x86/Makefile.inc @@ -336,13 +336,6 @@ ramstage-$(CONFIG_COLLECT_TIMESTAMPS_TSC) += timestamp.c ramstage-$(CONFIG_HAVE_ACPI_RESUME) += wakeup.S
-smm-$(CONFIG_IDT_IN_EVERY_STAGE) += exception.c -smm-$(CONFIG_IDT_IN_EVERY_STAGE) += idt.S -smm-y += memcpy.c -smm-y += memmove.c -smm-y += memset.c -smm-$(CONFIG_X86_TOP4G_BOOTMEDIA_MAP) += mmap_boot.c - ifeq ($(CONFIG_ARCH_RAMSTAGE_X86_32),y) rmodules_x86_32-y += memcpy.c rmodules_x86_32-y += memmove.c @@ -379,11 +372,6 @@ ramstage-srcs += src/mainboard/$(MAINBOARDDIR)/fadt.c endif endif # CONFIG_GENERATE_ACPI_TABLES -ifeq ($(CONFIG_HAVE_SMI_HANDLER),y) -ifneq ($(wildcard src/mainboard/$(MAINBOARDDIR)/smihandler.c),) -smm-srcs += src/mainboard/$(MAINBOARDDIR)/smihandler.c -endif -endif
ramstage-libs ?=
@@ -408,3 +396,20 @@ endif
endif # CONFIG_ARCH_RAMSTAGE_X86_32 / CONFIG_ARCH_RAMSTAGE_X86_64 + +############################################################################### +# smm +############################################################################### + +smm-$(CONFIG_IDT_IN_EVERY_STAGE) += exception.c +smm-$(CONFIG_IDT_IN_EVERY_STAGE) += idt.S +smm-y += memcpy.c +smm-y += memmove.c +smm-y += memset.c +smm-$(CONFIG_X86_TOP4G_BOOTMEDIA_MAP) += mmap_boot.c + +ifeq ($(CONFIG_HAVE_SMI_HANDLER),y) +ifneq ($(wildcard src/mainboard/$(MAINBOARDDIR)/smihandler.c),) +smm-srcs += src/mainboard/$(MAINBOARDDIR)/smihandler.c +endif +endif
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Exclude smm related files from ramstage compilation ......................................................................
Patch Set 1:
(1 comment)
https://review.coreboot.org/#/c/33115/1//COMMIT_MSG Commit Message:
https://review.coreboot.org/#/c/33115/1//COMMIT_MSG@7 PS1, Line 7: Makefile.inc: Exclude smm related files from ramstage compilation If you are you reordering Makefiles then say that. This change doesn't affect ramstage compilation from what I can tell.
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Exclude smm related files from ramstage compilation ......................................................................
Patch Set 1:
(1 comment)
https://review.coreboot.org/#/c/33115/1//COMMIT_MSG Commit Message:
https://review.coreboot.org/#/c/33115/1//COMMIT_MSG@7 PS1, Line 7: Makefile.inc: Exclude smm related files from ramstage compilation
If you are you reordering Makefiles then say that. […]
i don't think, its just recording. if you see there is a if(ramstage_config) and endif check, one can deselect ramsatge_config and smm code will not be able to compile
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Exclude smm related files from ramstage compilation ......................................................................
Patch Set 1:
(1 comment)
https://review.coreboot.org/#/c/33115/1//COMMIT_MSG Commit Message:
https://review.coreboot.org/#/c/33115/1//COMMIT_MSG@7 PS1, Line 7: Makefile.inc: Exclude smm related files from ramstage compilation
i don't think, its just recording. […]
smm build targets are only pulled in when there's a high level dependency that is requesting smm. If you want to remove the enablement of smm then add a Kconfig and find the root dependency and conditionalize it w/ the Kconfig option.
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Exclude smm related files from ramstage compilation ......................................................................
Patch Set 1:
(1 comment)
https://review.coreboot.org/#/c/33115/1//COMMIT_MSG Commit Message:
https://review.coreboot.org/#/c/33115/1//COMMIT_MSG@7 PS1, Line 7: Makefile.inc: Exclude smm related files from ramstage compilation
smm build targets are only pulled in when there's a high level dependency that is requesting smm. […]
So looks like we might need to dedicated config for smm, which doesn't exist today.
Hello ron minnich, build bot (Jenkins), Furquan Shaikh, Patrick Georgi,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/33115
to look at the new patch set (#2).
Change subject: Makefile.inc: Compile smm files based on CONFIG_SMM_INDEPENDENT_BUILD ......................................................................
Makefile.inc: Compile smm files based on CONFIG_SMM_INDEPENDENT_BUILD
This patch makes smm related files compile independent of ramstage getting compiled.
If user selects RAMPAYLOAD to boot without ramstage, there will be need for smm code to get compiled independently.
Change-Id: I17a3eb80a4d5ef86e0319357c01b6bf5b90ef15b Signed-off-by: Subrata Banik subrata.banik@intel.com --- M src/Kconfig M src/arch/x86/Makefile.inc 2 files changed, 31 insertions(+), 12 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/15/33115/2
Hello ron minnich, build bot (Jenkins), Furquan Shaikh, Patrick Georgi,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/33115
to look at the new patch set (#4).
Change subject: Makefile.inc: Compile smm files based on CONFIG_SMM_INDEPENDENT_BUILD ......................................................................
Makefile.inc: Compile smm files based on CONFIG_SMM_INDEPENDENT_BUILD
This patch makes smm related files compile independent of ramstage getting compiled.
If user selects RAMPAYLOAD to boot without ramstage, there will be need for smm code to get compiled independently.
Change-Id: I17a3eb80a4d5ef86e0319357c01b6bf5b90ef15b Signed-off-by: Subrata Banik subrata.banik@intel.com --- M src/Kconfig M src/arch/x86/Makefile.inc 2 files changed, 31 insertions(+), 12 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/15/33115/4
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_SMM_INDEPENDENT_BUILD ......................................................................
Patch Set 4:
(2 comments)
https://review.coreboot.org/#/c/33115/4/src/Kconfig File src/Kconfig:
https://review.coreboot.org/#/c/33115/4/src/Kconfig@333 PS4, Line 333: default y if STAGE_RAMSTAGE || RAMPAYLOAD I'm not following why the default would be based on these things. I think you should have another Kconfig which is the negative of this one such that you can select it for the small number of platforms that would deselect smm. Then the default of this option would be !that_option.
Also, as this option is x86 dependent it should go in src/arch/x86
https://review.coreboot.org/#/c/33115/4/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/4/src/arch/x86/Makefile.inc@403 PS4, Line 403: ifeq ($(CONFIG_SMM_INDEPENDENT_BUILD),y) I still don't follow why this change is needed. I think some work is required in src/cpu/x86/smm as well as a few guards in the code to not include the root reference which pulls everything in.
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_SMM_INDEPENDENT_BUILD ......................................................................
Patch Set 4:
(2 comments)
https://review.coreboot.org/#/c/33115/4/src/Kconfig File src/Kconfig:
https://review.coreboot.org/#/c/33115/4/src/Kconfig@333 PS4, Line 333: default y if STAGE_RAMSTAGE || RAMPAYLOAD
I'm not following why the default would be based on these things. I think you should have another Kconfig which is the negative of this one such that you can select it for the small number of platforms that would deselect smm. Then the default of this option would be !that_option.
purpose of this CL is to make required SMM code "also" compiled independent of ramstage hence i have included only below case.
1. when ramstage is enable then we might need to pull those smm code (this was the existing case)
2. when rampayload is selected and we need to only compiled those smm code without ramstage (new change)
The changes that you are recommending makes sense if i don't remove smm code from ramstage and additionally duplicate the same code under SMM_INDEPENDENT_BUILD which will be enable if !STAGE_RAMSTAGE ?
Also, as this option is x86 dependent it should go in src/arch/x86
yes, this is good idea
https://review.coreboot.org/#/c/33115/4/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/4/src/arch/x86/Makefile.inc@403 PS4, Line 403: ifeq ($(CONFIG_SMM_INDEPENDENT_BUILD),y)
I still don't follow why this change is needed. […]
are you referring about smm.manual creation ?
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_SMM_INDEPENDENT_BUILD ......................................................................
Patch Set 4:
(2 comments)
https://review.coreboot.org/#/c/33115/4/src/Kconfig File src/Kconfig:
https://review.coreboot.org/#/c/33115/4/src/Kconfig@333 PS4, Line 333: default y if STAGE_RAMSTAGE || RAMPAYLOAD
I'm not following why the default would be based on these things. […]
I see it now. Anyway, I'm not sure why we would have 'independent' in the name at all. It should really just be BUILD_SMM which is the current default w/o a Kconfig.
https://review.coreboot.org/#/c/33115/4/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/4/src/arch/x86/Makefile.inc@403 PS4, Line 403: ifeq ($(CONFIG_SMM_INDEPENDENT_BUILD),y)
are you referring about smm. […]
I see the reason now. It was in the if/endif of arch_ramstage_x86 bits.
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_SMM_INDEPENDENT_BUILD ......................................................................
Patch Set 4:
(2 comments)
https://review.coreboot.org/#/c/33115/4/src/Kconfig File src/Kconfig:
https://review.coreboot.org/#/c/33115/4/src/Kconfig@333 PS4, Line 333: default y if STAGE_RAMSTAGE || RAMPAYLOAD
I see it now. Anyway, I'm not sure why we would have 'independent' in the name at all. […]
agree, i will make required changes
https://review.coreboot.org/#/c/33115/4/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/4/src/arch/x86/Makefile.inc@403 PS4, Line 403: ifeq ($(CONFIG_SMM_INDEPENDENT_BUILD),y)
I see the reason now. It was in the if/endif of arch_ramstage_x86 bits.
yes, you are right
Hello ron minnich, build bot (Jenkins), Furquan Shaikh, Patrick Georgi,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/33115
to look at the new patch set (#5).
Change subject: Makefile.inc: Compile smm files based on CONFIG_BUILD_SMM ......................................................................
Makefile.inc: Compile smm files based on CONFIG_BUILD_SMM
This patch makes smm related files compile independent of ramstage getting compiled.
If user selects RAMPAYLOAD to boot without ramstage, there will be need for smm code to get compiled independently.
Change-Id: I17a3eb80a4d5ef86e0319357c01b6bf5b90ef15b Signed-off-by: Subrata Banik subrata.banik@intel.com --- M src/arch/x86/Kconfig M src/arch/x86/Makefile.inc 2 files changed, 27 insertions(+), 12 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/15/33115/5
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_BUILD_SMM ......................................................................
Patch Set 5:
(1 comment)
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc@403 PS5, Line 403: CONFIG_BUILD_SMM I don't think this guard is needed here. What I think needs to be done is pull out smm from the Makefile.inc classes-y when it's not employed. Same goes for ramstage. That said, it doesn't completely remove the referenced dependency, but that's a more correct way of doing this.
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_BUILD_SMM ......................................................................
Patch Set 5:
(1 comment)
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc@403 PS5, Line 403: CONFIG_BUILD_SMM
I don't think this guard is needed here. What I think needs to be done is pull out smm from the Makefile.inc classes-y when it's not employed.
Do you mean something like dedicated Makefile.inc for seperate stage ?
Same goes for ramstage. That said, it doesn't completely remove the referenced dependency, but that's a more correct way of doing this.
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_BUILD_SMM ......................................................................
Patch Set 5:
(1 comment)
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc@403 PS5, Line 403: CONFIG_BUILD_SMM
I don't think this guard is needed here. […]
Same thing as all my other comments. We need to determine what is pulling in the dependencies such that these rules are being evaluated.
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_BUILD_SMM ......................................................................
Patch Set 5:
(1 comment)
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc@403 PS5, Line 403: CONFIG_BUILD_SMM
Same thing as all my other comments. […]
isn't the case that we need to compile smm code for x86 platform ?
Also few files like uart.c, smihandler.c are getting compiled inside smm mode as well. Those files might need to perform memset, memcpy, those functions are part of files that been compiled here inside this Makefile.inc.
I thought this CL is simple where we might just need to compile smm code outside ramstage independently.
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files based on CONFIG_BUILD_SMM ......................................................................
Patch Set 5:
(1 comment)
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/5/src/arch/x86/Makefile.inc@403 PS5, Line 403: CONFIG_BUILD_SMM
isn't the case that we need to compile smm code for x86 platform ? […]
I'm saying that moving these stanzas here is required. But I'm not convinced we need to find all the places and guard the blocks. I'm suggesting removing the root dependency removes the need for doing per-Makefile guarding of these recipes. I want to focus on removing the root dependency when these options aren't selected.
Hello ron minnich, build bot (Jenkins), Furquan Shaikh, Patrick Georgi,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/33115
to look at the new patch set (#6).
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64
This patch makes smm related files compile independent of ramstage getting compiled.
If user selects RAMPAYLOAD to boot without ramstage, there will be need for smm code to get compiled independently.
Change-Id: I17a3eb80a4d5ef86e0319357c01b6bf5b90ef15b Signed-off-by: Subrata Banik subrata.banik@intel.com --- M src/arch/x86/Makefile.inc 1 file changed, 5 insertions(+), 4 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/15/33115/6
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Patch Set 7:
(1 comment)
https://review.coreboot.org/#/c/33115/7/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/7/src/arch/x86/Makefile.inc@340 PS7, Line 340: smm-$(CONFIG_IDT_IN_EVERY_STAGE) += idt.S Why weren't the above moved?
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Patch Set 7:
(1 comment)
https://review.coreboot.org/#/c/33115/7/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/7/src/arch/x86/Makefile.inc@340 PS7, Line 340: smm-$(CONFIG_IDT_IN_EVERY_STAGE) += idt.S
Why weren't the above moved?
i was only keeping root dependencies for now. looks like !ramstage build is not bothered about those files.
Also i don't think payload loads from postcar might not required these.
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Patch Set 7:
(1 comment)
https://review.coreboot.org/#/c/33115/7/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/7/src/arch/x86/Makefile.inc@340 PS7, Line 340: smm-$(CONFIG_IDT_IN_EVERY_STAGE) += idt.S
i was only keeping root dependencies for now. […]
If you are building for smm you should pull in the same objects as before. I don't understand your reasoning here at all. It doesn't make sense -- just because your build options you don't care why would you make policy and semantic changes on other people's usages?
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Patch Set 7:
(1 comment)
https://review.coreboot.org/#/c/33115/7/src/arch/x86/Makefile.inc File src/arch/x86/Makefile.inc:
https://review.coreboot.org/#/c/33115/7/src/arch/x86/Makefile.inc@340 PS7, Line 340: smm-$(CONFIG_IDT_IN_EVERY_STAGE) += idt.S
If you are building for smm you should pull in the same objects as before. […]
got your point
Hello ron minnich, build bot (Jenkins), Furquan Shaikh, Patrick Georgi,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/33115
to look at the new patch set (#8).
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64
This patch makes smm related files compile independent of ramstage getting compiled.
If user selects RAMPAYLOAD to boot without ramstage, there will be need for smm code to get compiled independently.
Change-Id: I17a3eb80a4d5ef86e0319357c01b6bf5b90ef15b Signed-off-by: Subrata Banik subrata.banik@intel.com --- M src/arch/x86/Makefile.inc 1 file changed, 13 insertions(+), 12 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/15/33115/8
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Patch Set 8: Code-Review+2
This can land on its own.
Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Patch Set 8:
Patch Set 8: Code-Review+2
This can land on its own.
yes, i will wait for 24hr as per guideline. thanks for your time Aaron
Subrata Banik has submitted this change and it was merged. ( https://review.coreboot.org/c/coreboot/+/33115 )
Change subject: Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64 ......................................................................
Makefile.inc: Compile smm files independent ARCH_RAMSTAGE_X86_32/64
This patch makes smm related files compile independent of ramstage getting compiled.
If user selects RAMPAYLOAD to boot without ramstage, there will be need for smm code to get compiled independently.
Change-Id: I17a3eb80a4d5ef86e0319357c01b6bf5b90ef15b Signed-off-by: Subrata Banik subrata.banik@intel.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/33115 Reviewed-by: Aaron Durbin adurbin@chromium.org Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M src/arch/x86/Makefile.inc 1 file changed, 13 insertions(+), 12 deletions(-)
Approvals: build bot (Jenkins): Verified Aaron Durbin: Looks good to me, approved
diff --git a/src/arch/x86/Makefile.inc b/src/arch/x86/Makefile.inc index 7e518d8..025b933 100644 --- a/src/arch/x86/Makefile.inc +++ b/src/arch/x86/Makefile.inc @@ -336,13 +336,6 @@ ramstage-$(CONFIG_COLLECT_TIMESTAMPS_TSC) += timestamp.c ramstage-$(CONFIG_HAVE_ACPI_RESUME) += wakeup.S
-smm-$(CONFIG_IDT_IN_EVERY_STAGE) += exception.c -smm-$(CONFIG_IDT_IN_EVERY_STAGE) += idt.S -smm-y += memcpy.c -smm-y += memmove.c -smm-y += memset.c -smm-$(CONFIG_X86_TOP4G_BOOTMEDIA_MAP) += mmap_boot.c - ifeq ($(CONFIG_ARCH_RAMSTAGE_X86_32),y) rmodules_x86_32-y += memcpy.c rmodules_x86_32-y += memmove.c @@ -379,11 +372,6 @@ ramstage-srcs += src/mainboard/$(MAINBOARDDIR)/fadt.c endif endif # CONFIG_GENERATE_ACPI_TABLES -ifeq ($(CONFIG_HAVE_SMI_HANDLER),y) -ifneq ($(wildcard src/mainboard/$(MAINBOARDDIR)/smihandler.c),) -smm-srcs += src/mainboard/$(MAINBOARDDIR)/smihandler.c -endif -endif
ramstage-libs ?=
@@ -408,3 +396,16 @@ endif
endif # CONFIG_ARCH_RAMSTAGE_X86_32 / CONFIG_ARCH_RAMSTAGE_X86_64 + +smm-$(CONFIG_IDT_IN_EVERY_STAGE) += exception.c +smm-$(CONFIG_IDT_IN_EVERY_STAGE) += idt.S +smm-y += memcpy.c +smm-y += memmove.c +smm-y += memset.c +smm-$(CONFIG_X86_TOP4G_BOOTMEDIA_MAP) += mmap_boot.c + +ifeq ($(CONFIG_HAVE_SMI_HANDLER),y) +ifneq ($(wildcard src/mainboard/$(MAINBOARDDIR)/smihandler.c),) +smm-srcs += src/mainboard/$(MAINBOARDDIR)/smihandler.c +endif +endif