aboutsummaryrefslogtreecommitdiff
path: root/src/soc/intel
diff options
context:
space:
mode:
Diffstat (limited to 'src/soc/intel')
-rw-r--r--src/soc/intel/common/nvm.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/soc/intel/common/nvm.c b/src/soc/intel/common/nvm.c
index b7e0f4e7ac..61b7a65991 100644
--- a/src/soc/intel/common/nvm.c
+++ b/src/soc/intel/common/nvm.c
@@ -22,7 +22,6 @@
#include <spi_flash.h>
#include <vendorcode/google/chromeos/chromeos.h>
#include "nvm.h"
-#include "spi_flash.h"
/* Read flash status register to determine if write protect is active */
int nvm_is_write_protected(void)
@@ -62,5 +61,5 @@ int nvm_protect(const struct region *r)
if (!IS_ENABLED(CONFIG_BOOT_DEVICE_SPI_FLASH))
return 0;
- return spi_flash_protect(region_offset(r), region_sz(r));
+ return spi_flash_ctrlr_protect_region(boot_device_spi_flash(), r);
}