summaryrefslogtreecommitdiff
path: root/src/mainboard/emulation/qemu-i440fx
diff options
context:
space:
mode:
authorArthur Heymans <arthur@aheymans.xyz>2020-12-01 18:29:13 +0100
committerPatrick Georgi <pgeorgi@google.com>2021-03-18 08:10:11 +0000
commite69d2dfdb70c33dfcc07a54c217601f498c2214c (patch)
treefa79b9a46e7c80b6c5ac06ec582b79db66c56d4a /src/mainboard/emulation/qemu-i440fx
parentff485f2bcef9d0c8cf9536f6b8bc87edbe718e04 (diff)
mb/emulation/qemu-q35: Add support for SMM_TSEG with parallel MP init
Tested with and without -enable-kvm, with -smp 1 2 and 32. Change-Id: I612cebcd2ddef809434eb9bfae9d8681cda112ef Signed-off-by: Arthur Heymans <arthur@aheymans.xyz> Reviewed-on: https://review.coreboot.org/c/coreboot/+/48262 Reviewed-by: Angel Pons <th3fanbus@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/mainboard/emulation/qemu-i440fx')
-rw-r--r--src/mainboard/emulation/qemu-i440fx/northbridge.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mainboard/emulation/qemu-i440fx/northbridge.c b/src/mainboard/emulation/qemu-i440fx/northbridge.c
index 80fba1de07..fcff7bcf7f 100644
--- a/src/mainboard/emulation/qemu-i440fx/northbridge.c
+++ b/src/mainboard/emulation/qemu-i440fx/northbridge.c
@@ -249,9 +249,13 @@ static const struct mp_ops mp_ops_no_smm = {
.get_cpu_count = fw_cfg_max_cpus,
};
+extern const struct mp_ops mp_ops_with_smm;
+
void mp_init_cpus(struct bus *cpu_bus)
{
- if (mp_init_with_smm(cpu_bus, &mp_ops_no_smm))
+ const struct mp_ops *ops = CONFIG(SMM_TSEG) ? &mp_ops_with_smm : &mp_ops_no_smm;
+
+ if (mp_init_with_smm(cpu_bus, ops))
printk(BIOS_ERR, "MP initialization failure.\n");
}