summaryrefslogtreecommitdiffstats
path: root/src/soc/intel/common/block/gpio/gpio.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/soc/intel/common/block/gpio/gpio.c')
-rw-r--r--src/soc/intel/common/block/gpio/gpio.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/soc/intel/common/block/gpio/gpio.c b/src/soc/intel/common/block/gpio/gpio.c
index 419c77ea48e7..1bc34e7fc3ac 100644
--- a/src/soc/intel/common/block/gpio/gpio.c
+++ b/src/soc/intel/common/block/gpio/gpio.c
@@ -469,6 +469,9 @@ int gpio_lock_pads(const struct gpio_lock_config *pad_list, const size_t count)
uint32_t data;
gpio_t pad;
+ if (!CONFIG(SOC_INTEL_COMMON_BLOCK_SMM_LOCK_GPIO_PADS))
+ return -1;
+
/*
* FSP-S will unlock all the GPIO pads and hide the P2SB device. With
* the device hidden, we will not be able to send the sideband interface