xref: /aosp_15_r20/external/mesa3d/src/gallium/drivers/radeonsi/pspdecryptionparam.h (revision 6104692788411f58d303aa86923a9ff6ecaded22)
1 /**************************************************************************
2  *
3  * Copyright 2020 Advanced Micro Devices, Inc.
4  *
5  * SPDX-License-Identifier: MIT
6  *
7  **************************************************************************/
8 #ifndef _PSP_DECRYPTION_PARAM_H_
9 #define _PSP_DECRYPTION_PARAM_H_
10 
11 typedef struct _DECRYPT_PARAMETERS_
12 {
13    uint32_t                frame_size;         // Size of encrypted frame
14    uint8_t                 encrypted_iv[16];   // IV of the encrypted frame (clear)
15    uint8_t                 encrypted_key[16];  // key to decrypt encrypted frame (encrypted with session key)
16    uint8_t                 session_iv[16];     // IV to be used to decrypt encrypted_key
17 
18    union
19    {
20       struct
21       {
22          uint32_t    drm_id   : 4;	//DRM session ID
23          uint32_t    ctr      : 1;
24          uint32_t    cbc      : 1;
25          uint32_t    reserved : 26;
26       } s;
27       uint32_t        value;
28    } u;
29 } DECRYPT_PARAMETERS;
30 
31 #endif //_PSP_DECRYPTION_PARAM_H_
32