sizes.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: 2025 TU Dresden
3  * SPDX-FileCopyrightText: 2021 HAW Hamburg
4  * SPDX-License-Identifier: LGPL-2.1-only
5  */
6 
7 #pragma once
8 
21 #ifdef __cplusplus
22 extern "C" {
23 #endif
24 
32 #define PSA_BITS_TO_BYTES(bits) (size_t)(((bits) + 7) / 8)
33 
41 #define PSA_BYTES_TO_BITS(bytes) ((bytes) * 8)
42 
43 #ifdef __cplusplus
44 }
45 #endif
46