From 1d69099115603591ed07b06b42fea5b25d5628d2 Mon Sep 17 00:00:00 2001 From: Marshall Dawson Date: Wed, 12 Aug 2020 16:21:23 -0600 Subject: vc/amd/picasso/bl_uapp: Update header file Update to match the 0.8.6.7B release of PSP blobs. BUG=b:163857965,b:137123167 TEST=Boot Trembyle, run SST Signed-off-by: Marshall Dawson Change-Id: I728dc17ba2cfb40bc6eaaa30556a3f6bc57d18f6 Reviewed-on: https://review.coreboot.org/c/coreboot/+/44428 Tested-by: build bot (Jenkins) Reviewed-by: Furquan Shaikh --- .../picasso/include/bl_uapp/bl_syscall_public.h | 25 +++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) (limited to 'src/vendorcode') diff --git a/src/vendorcode/amd/fsp/picasso/include/bl_uapp/bl_syscall_public.h b/src/vendorcode/amd/fsp/picasso/include/bl_uapp/bl_syscall_public.h index 45ea67e5c4..69ada3490a 100644 --- a/src/vendorcode/amd/fsp/picasso/include/bl_uapp/bl_syscall_public.h +++ b/src/vendorcode/amd/fsp/picasso/include/bl_uapp/bl_syscall_public.h @@ -52,6 +52,7 @@ #define SVC_WRITE_POSTCODE 0x44 #define SVC_GET_MAX_WORKBUF_SIZE 0x45 #define SVC_SHA 0x46 +#define SVC_RSAPKCS_VERIFY 0x47 typedef struct _RSAPSS_VERIFY_PARAMS_T { @@ -64,6 +65,17 @@ typedef struct _RSAPSS_VERIFY_PARAMS_T char *pSig; // Signature to be verified, same size as ModulusSize } RSAPSS_VERIFY_PARAMS; +typedef struct RSAPKCS_VERIFY_PARAMS_T +{ + char *pHash; // Message digest to verify the RSA signature + unsigned int HashLen; // hash length in bytes + char *pModulus; // Modulus address + unsigned int ModulusSize; // Modulus length in bytes + char *pExponent; // Exponent address + unsigned int ExpSize; // Exponent length in bytes + char *pSig; // Signature to be verified, same size as ModulusSize +} RSAPKCS_VERIFY_PARAMS; + typedef enum _PSP_BOOT_MODE { PSP_BOOT_MODE_S0 = 0x0, @@ -347,7 +359,8 @@ uint32_t svc_get_max_workbuf_size(uint32_t *size); */ uint32_t svc_crypto_sha(SHA_GENERIC_DATA *sha_op, SHA_OPERATION_MODE sha_mode); -/* RSA PSS Verification of signature and data +/* + * RSA PSS Verification of signature and data * * Parameters: * RSAPSS_VERIFY_PARAMS - Pointer to RSA PSS parameters @@ -356,6 +369,16 @@ uint32_t svc_crypto_sha(SHA_GENERIC_DATA *sha_op, SHA_OPERATION_MODE sha_mode); */ uint32_t svc_rsa_pss_verify(const RSAPSS_VERIFY_PARAMS *params); +/* + * RSA PKCS Verification of signature and data + * + * Parameters: + * RSAPKCS_VERIFY_PARAMS - Pointer to RSA PKCS parameters + * + * Return value: BL_OK or error code + */ +uint32_t svc_rsa_pkcs_verify(const RSAPKCS_VERIFY_PARAMS *params); + /* C entry point for the Bootloader Userspace Application */ void Main(void); -- cgit v1.2.3