Felix Held has submitted this change. ( https://review.coreboot.org/c/coreboot/+/84068?usp=email )
Change subject: soc/amd/common/psp: move PSP SMI SPI access function prototypes ......................................................................
soc/amd/common/psp: move PSP SMI SPI access function prototypes
Now that we have the local psp_smi_flash.h header, move the psp_smi_spi_* function prototypes there.
Signed-off-by: Felix Held felix-coreboot@felixheld.de Change-Id: I12cbbabf6a960836fe0c5dc1424c08550cb66a7a Reviewed-on: https://review.coreboot.org/c/coreboot/+/84068 Reviewed-by: Marshall Dawson marshalldawson3rd@gmail.com Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Matt DeVillier matt.devillier@amd.corp-partner.google.com --- M src/soc/amd/common/block/psp/psp_def.h M src/soc/amd/common/block/psp/psp_smi.c M src/soc/amd/common/block/psp/psp_smi_flash.h 3 files changed, 6 insertions(+), 5 deletions(-)
Approvals: Matt DeVillier: Looks good to me, approved build bot (Jenkins): Verified Marshall Dawson: Looks good to me, approved
diff --git a/src/soc/amd/common/block/psp/psp_def.h b/src/soc/amd/common/block/psp/psp_def.h index e723c84..d1f57ac 100644 --- a/src/soc/amd/common/block/psp/psp_def.h +++ b/src/soc/amd/common/block/psp/psp_def.h @@ -153,9 +153,4 @@
void enable_psp_smi(void);
-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); - #endif /* __AMD_PSP_DEF_H__ */ diff --git a/src/soc/amd/common/block/psp/psp_smi.c b/src/soc/amd/common/block/psp/psp_smi.c index be7d4cb..ccd03793 100644 --- a/src/soc/amd/common/block/psp/psp_smi.c +++ b/src/soc/amd/common/block/psp/psp_smi.c @@ -7,6 +7,7 @@ #include <device/mmio.h> #include <types.h> #include "psp_def.h" +#include "psp_smi_flash.h"
/* PSP to x86 commands */ #define MBOX_PSP_CMD_SPI_INFO 0x83 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 6f3eb97..c9c6a1c 100644 --- a/src/soc/amd/common/block/psp/psp_smi_flash.h +++ b/src/soc/amd/common/block/psp/psp_smi_flash.h @@ -61,3 +61,8 @@ uint64_t *num_bytes, uint8_t **data); void get_psp_spi_erase(struct mbox_psp_cmd_spi_erase *cmd_buf, uint64_t *target_nv_id, uint64_t *lba, uint64_t *num_blocks); + +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);