Arthur Heymans has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/63602 )
Change subject: cpu/x86/smm: Use struct region to check overlapping sections ......................................................................
Patch Set 5:
(1 comment)
File src/cpu/x86/smm/smm_module_loader.c:
https://review.coreboot.org/c/coreboot/+/63602/comment/ba7cdc26_e4d0e9f9 PS5, Line 511: for (unsigned int i = 0; i < params->num_concurrent_save_states; i++) { : printk(BIOS_DEBUG, "\nCPU %d\n", i); : struct region ss = { .offset = cpus[i].ss_start, .size = cpus[i].ss_top - cpus[i].ss_start }; : char string[13]; : snprintf(string, sizeof(string), " ss%d", i); : if (check_region(smram, ss, string)) : return 1; : struct region stub = {.offset = cpus[i].code_start, : .size = cpus[i].code_end - cpus[i].code_start}; : snprintf(string, sizeof(string), " stub%d", i); : if (check_region(smram, stub, string)) : return 1; : } This is common with both TSEG and ASEG. Put in a function.