Attention is currently required from: Bora Guvendik, Cliff Huang, Jérémy Compostella, Pranava Y N.
Subrata Banik has posted comments on this change by Cliff Huang. ( https://review.coreboot.org/c/coreboot/+/84901?usp=email )
Change subject: soc/intel/common/gpio: add function to lock GPIO configuration ......................................................................
Patch Set 3:
(1 comment)
File src/soc/intel/common/block/gpio/gpio.c:
https://review.coreboot.org/c/coreboot/+/84901/comment/251d5040_8904ed20?usp... : PS3, Line 485: /* Clear lock for the exception PADs */
The thing is that we don't enable lock in our MB gpio.c and fw_config.c for pretty much all GPIOs today, In particularly, those configuration are generated from HW mapping document where lock decision are not determined and provided. We either manually replaced with lock macros for each of PAD in the ramstage table or fw_config.c or we could use this new function to add lock prior to writing to the registers.
IMO, gpio.c with LOCK config is better option rather maintaining two different source of truth to update the same GPIO configuration.
Can you please create a TODO task to apply the LOCK config, we can start with N-1 platform aka Rex and try to apply the lock config for similar functional GPIOs.