Attention is currently required from: Keith Hui.
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/78206?usp=email )
Change subject: nb/intel/sandybridge: Pre-render constants in MRC pei_data ......................................................................
Patch Set 4:
(1 comment)
File src/northbridge/intel/sandybridge/raminit_mrc.c:
https://review.coreboot.org/c/coreboot/+/78206/comment/c62eb3f4_19608061 : PS4, Line 404: struct pei_data pei_data; The same thing can easily be achieved using a struct initialiser here: ``` struct pei_data pei_data = { .pei_version = PEI_VERSION, .mchbar = CONFIG_FIXED_MCHBAR_MMIO_BASE, .dmibar = CONFIG_FIXED_DMIBAR_MMIO_BASE, .epbar = CONFIG_FIXED_EPBAR_MMIO_BASE, .pciexbar = CONFIG_ECAM_MMCONF_BASE_ADDRESS, .smbusbar = CONFIG_FIXED_SMBUS_IO_BASE, .wdbbar = 0x4000000, .wdbsize = 0x1000, .hpet_address = HPET_BASE_ADDRESS, .rcba = (uintptr_t)DEFAULT_RCBA, .pmbase = DEFAULT_PMBASE, .gpiobase = DEFAULT_GPIOBASE, .thermalbase = 0xfed08000, .tseg_size = CONFIG_SMM_TSEG_SIZE, }; ``` This works because unspecified members are zero-initialised by the compiler. So the `memset()` becomes unnecessary.