Module: Mesa Branch: main Commit: a7366d68ae551763acc8cd481ff64af04e7a7cd9 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=a7366d68ae551763acc8cd481ff64af04e7a7cd9
Author: Feng Jiang <[email protected]> Date: Mon Jun 20 14:22:28 2022 +0800 gallium: add key size to the structure pipe_picture_desc Signed-off-by: Feng Jiang <[email protected]> Reviewed-by: Liming Sun <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17157> --- src/gallium/frontends/va/picture.c | 1 + src/gallium/include/pipe/p_video_state.h | 1 + 2 files changed, 2 insertions(+) diff --git a/src/gallium/frontends/va/picture.c b/src/gallium/frontends/va/picture.c index bcd23b3ae8a..5f443d5c3f8 100644 --- a/src/gallium/frontends/va/picture.c +++ b/src/gallium/frontends/va/picture.c @@ -283,6 +283,7 @@ handleVAProtectedSliceDataBufferType(vlVaContext *context, vlVaBuffer *buf) context->desc.base.decrypt_key = CALLOC(1, drm_key_size); memcpy(context->desc.base.decrypt_key, encrypted_data, drm_key_size); + context->desc.base.key_size = drm_key_size; context->desc.base.protected_playback = true; } diff --git a/src/gallium/include/pipe/p_video_state.h b/src/gallium/include/pipe/p_video_state.h index db34fce73ae..1a95dfb39d4 100755 --- a/src/gallium/include/pipe/p_video_state.h +++ b/src/gallium/include/pipe/p_video_state.h @@ -137,6 +137,7 @@ struct pipe_picture_desc enum pipe_video_entrypoint entry_point; bool protected_playback; uint8_t *decrypt_key; + uint32_t key_size; enum pipe_format input_format; enum pipe_format output_format; };
