Skip to content

Commit

Permalink
Add session_id to libspdm_event_get_types
Browse files Browse the repository at this point in the history
Fix #2838.

Signed-off-by: Steven Bellock <sbellock@nvidia.com>
  • Loading branch information
steven-bellock committed Sep 23, 2024
1 parent 98d4a3a commit 36c4bcd
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 1 deletion.
2 changes: 2 additions & 0 deletions include/hal/library/eventlib.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
*
* @param spdm_context A pointer to the SPDM context.
* @param spdm_version Indicates the negotiated version.
* @param session_id Secure session identifier.
* @param supported_event_groups_list A pointer to the buffer that holds the list of event.
* groups.
* @param supported_event_groups_list_len On input, the size, in bytes, of the buffer to hold the
Expand All @@ -35,6 +36,7 @@
extern bool libspdm_event_get_types(
void *spdm_context,
spdm_version_number_t spdm_version,
uint32_t session_id,
void *supported_event_groups_list,
uint32_t *supported_event_groups_list_len,
uint8_t *event_group_count);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ libspdm_return_t libspdm_get_response_supported_event_types(libspdm_context_t *s
supported_event_groups_list_len = (uint32_t)response_buffer_size -
sizeof(spdm_supported_event_types_response_t);

if (!libspdm_event_get_types(spdm_context, spdm_context->connection_info.version,
if (!libspdm_event_get_types(spdm_context, spdm_context->connection_info.version, session_id,
(void *)(spdm_response + 1), &supported_event_groups_list_len,
&event_group_count)) {
return libspdm_generate_error_response(spdm_context,
Expand Down
1 change: 1 addition & 0 deletions os_stub/spdm_device_secret_lib_null/lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,7 @@ bool libspdm_gen_csr_ex(
bool libspdm_event_get_types(
void *spdm_context,
spdm_version_number_t spdm_version,
uint32_t session_id,
void *supported_event_groups_list,
uint32_t *supported_event_groups_list_len,
uint8_t *event_group_count)
Expand Down
1 change: 1 addition & 0 deletions os_stub/spdm_device_secret_lib_sample/lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -2236,6 +2236,7 @@ bool libspdm_write_certificate_to_nvm(
bool libspdm_event_get_types(
void *spdm_context,
spdm_version_number_t spdm_version,
uint32_t session_id,
void *supported_event_groups_list,
uint32_t *supported_event_groups_list_len,
uint8_t *event_group_count)
Expand Down

0 comments on commit 36c4bcd

Please sign in to comment.