summaryrefslogtreecommitdiff
path: root/src/soc/amd
diff options
context:
space:
mode:
Diffstat (limited to 'src/soc/amd')
-rw-r--r--src/soc/amd/common/block/psp/psp_smi.c8
-rw-r--r--src/soc/amd/common/block/psp/psp_smi_flash.c14
-rw-r--r--src/soc/amd/common/block/psp/psp_smi_flash.h2
3 files changed, 24 insertions, 0 deletions
diff --git a/src/soc/amd/common/block/psp/psp_smi.c b/src/soc/amd/common/block/psp/psp_smi.c
index ccd03793c9..5a1a4b9e46 100644
--- a/src/soc/amd/common/block/psp/psp_smi.c
+++ b/src/soc/amd/common/block/psp/psp_smi.c
@@ -14,6 +14,8 @@
#define MBOX_PSP_CMD_SPI_READ 0x84
#define MBOX_PSP_CMD_SPI_WRITE 0x85
#define MBOX_PSP_CMD_SPI_ERASE 0x86
+#define MBOX_PSP_CMD_SPI_RPMC_INC_MC 0x88
+#define MBOX_PSP_CMD_SPI_RPMC_REQ_MC 0x89
extern struct {
uint8_t buffer[P2C_BUFFER_MAXSIZE];
@@ -154,6 +156,12 @@ static void handle_psp_command(void)
case MBOX_PSP_CMD_SPI_ERASE:
status = psp_smi_spi_erase(buffer);
break;
+ case MBOX_PSP_CMD_SPI_RPMC_INC_MC:
+ status = psp_smi_spi_rpmc_inc_mc(buffer);
+ break;
+ case MBOX_PSP_CMD_SPI_RPMC_REQ_MC:
+ status = psp_smi_spi_rpmc_req_mc(buffer);
+ break;
default:
printk(BIOS_ERR, "PSP: Unknown command %d\n", cmd);
status = MBOX_PSP_UNSUPPORTED;
diff --git a/src/soc/amd/common/block/psp/psp_smi_flash.c b/src/soc/amd/common/block/psp/psp_smi_flash.c
index ab9bc6c7f2..d78db48ddc 100644
--- a/src/soc/amd/common/block/psp/psp_smi_flash.c
+++ b/src/soc/amd/common/block/psp/psp_smi_flash.c
@@ -269,3 +269,17 @@ enum mbox_p2c_status psp_smi_spi_erase(struct mbox_default_buffer *buffer)
return MBOX_PSP_SUCCESS;
}
+
+enum mbox_p2c_status psp_smi_spi_rpmc_inc_mc(struct mbox_default_buffer *buffer)
+{
+ printk(BIOS_SPEW, "PSP: SPI RPMC increment monotonic counter request\n");
+
+ return MBOX_PSP_UNSUPPORTED;
+}
+
+enum mbox_p2c_status psp_smi_spi_rpmc_req_mc(struct mbox_default_buffer *buffer)
+{
+ printk(BIOS_SPEW, "PSP: SPI RPMC request monotonic counter request\n");
+
+ return MBOX_PSP_UNSUPPORTED;
+}
diff --git a/src/soc/amd/common/block/psp/psp_smi_flash.h b/src/soc/amd/common/block/psp/psp_smi_flash.h
index c9c6a1c9ce..344c9fb429 100644
--- a/src/soc/amd/common/block/psp/psp_smi_flash.h
+++ b/src/soc/amd/common/block/psp/psp_smi_flash.h
@@ -66,3 +66,5 @@ enum mbox_p2c_status psp_smi_spi_get_info(struct mbox_default_buffer *buffer);
enum mbox_p2c_status psp_smi_spi_read(struct mbox_default_buffer *buffer);
enum mbox_p2c_status psp_smi_spi_write(struct mbox_default_buffer *buffer);
enum mbox_p2c_status psp_smi_spi_erase(struct mbox_default_buffer *buffer);
+enum mbox_p2c_status psp_smi_spi_rpmc_inc_mc(struct mbox_default_buffer *buffer);
+enum mbox_p2c_status psp_smi_spi_rpmc_req_mc(struct mbox_default_buffer *buffer);