summaryrefslogtreecommitdiff
path: root/src/soc/amd/common/block/psp/psp_smm.c
diff options
context:
space:
mode:
authorFelix Held <felix.held@amd.corp-partner.google.com>2020-04-15 17:05:38 +0200
committerFelix Held <felix-coreboot@felixheld.de>2020-04-16 23:17:41 +0000
commit7d304186057cc6c66e5469fadd003e3a62b8eb63 (patch)
tree168d0e7939c8fd45fa41cba0906f82a93a2db802 /src/soc/amd/common/block/psp/psp_smm.c
parent90b8339b8d4338c14cfd791bf4d5058aa515da34 (diff)
downloadcoreboot-7d304186057cc6c66e5469fadd003e3a62b8eb63.tar.xz
soc/amd/common/psp: refactor psp_print_cmd_status parameters
psp_print_cmd_status only needs data from the mbox buffer header and not the whole buffer. This avoids type casts when the buffer type isn't mbox_default_buffer. BUG=b:153677737 Change-Id: I8688b66fefe89fc4f3ce2207d4360ceb2dbaef12 Signed-off-by: Felix Held <felix-coreboot@felixheld.de> Reviewed-on: https://review.coreboot.org/c/coreboot/+/40412 Reviewed-by: Raul Rangel <rrangel@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc/amd/common/block/psp/psp_smm.c')
-rw-r--r--src/soc/amd/common/block/psp/psp_smm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/soc/amd/common/block/psp/psp_smm.c b/src/soc/amd/common/block/psp/psp_smm.c
index 4ae2277cab..7ffa6b6116 100644
--- a/src/soc/amd/common/block/psp/psp_smm.c
+++ b/src/soc/amd/common/block/psp/psp_smm.c
@@ -72,7 +72,7 @@ int psp_notify_smm(void)
clear_smm_flag();
/* buffer's status shouldn't change but report it if it does */
- psp_print_cmd_status(cmd_status, (struct mbox_default_buffer *)&buffer);
+ psp_print_cmd_status(cmd_status, &buffer.header);
return cmd_status;
}
@@ -102,5 +102,5 @@ void psp_notify_sx_info(u8 sleep_type)
clear_smm_flag();
/* buffer's status shouldn't change but report it if it does */
- psp_print_cmd_status(cmd_status, (struct mbox_default_buffer *)buffer);
+ psp_print_cmd_status(cmd_status, &buffer->header);
}