diff options
author | Dani Liberman <dliberman@habana.ai> | 2024-03-11 18:31:10 +0200 |
---|---|---|
committer | Ofir Bitton <obitton@habana.ai> | 2024-06-23 09:53:04 +0300 |
commit | c2a27584ff3b7f17da3ed2abfa3956f9d376e3da (patch) | |
tree | b9558ce599f9cae878588ad7d33d8bc8ab9c4fbc /include/linux/habanalabs | |
parent | c8c10dcacafce3b6fb0238479b5e28e92b0366da (diff) | |
download | linux-c2a27584ff3b7f17da3ed2abfa3956f9d376e3da.tar.gz linux-c2a27584ff3b7f17da3ed2abfa3956f9d376e3da.tar.bz2 linux-c2a27584ff3b7f17da3ed2abfa3956f9d376e3da.zip |
accel/habanalabs: separate nonce from max_size in cpucp_packet struct
In struct cpucp_packet both nonce and data_max_size members are in an
union overlapping each other. This is a problem as they both are used
in attestation and info_signed packets.
The solution here is to move the nonce member to a different union under
the same structure.
Signed-off-by: Dani Liberman <dliberman@habana.ai>
Reviewed-by: Ofir Bitton <obitton@habana.ai>
Signed-off-by: Ofir Bitton <obitton@habana.ai>
Diffstat (limited to 'include/linux/habanalabs')
-rw-r--r-- | include/linux/habanalabs/cpucp_if.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/habanalabs/cpucp_if.h b/include/linux/habanalabs/cpucp_if.h index 1ac1d68193e3..0913415243e8 100644 --- a/include/linux/habanalabs/cpucp_if.h +++ b/include/linux/habanalabs/cpucp_if.h @@ -859,9 +859,6 @@ struct cpucp_packet { * result cannot be used to hold general purpose data. */ __le32 status_mask; - - /* random, used once number, for security packets */ - __le32 nonce; }; union { @@ -870,6 +867,9 @@ struct cpucp_packet { /* For Generic packet sub index */ __le32 pkt_subidx; + + /* random, used once number, for security packets */ + __le32 nonce; }; }; |