1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2017 Intel Corporation
5 #ifndef TEST_BBDEV_VECTOR_H_
6 #define TEST_BBDEV_VECTOR_H_
8 #include <rte_bbdev_op.h>
10 /* Flags which are set when specific parameter is define in vector file */
12 TEST_BBDEV_VF_E = (1ULL << 0),
13 TEST_BBDEV_VF_EA = (1ULL << 1),
14 TEST_BBDEV_VF_EB = (1ULL << 2),
15 TEST_BBDEV_VF_K = (1ULL << 3),
16 TEST_BBDEV_VF_K_NEG = (1ULL << 4),
17 TEST_BBDEV_VF_K_POS = (1ULL << 5),
18 TEST_BBDEV_VF_C_NEG = (1ULL << 6),
19 TEST_BBDEV_VF_C = (1ULL << 7),
20 TEST_BBDEV_VF_CAB = (1ULL << 8),
21 TEST_BBDEV_VF_RV_INDEX = (1ULL << 9),
22 TEST_BBDEV_VF_ITER_MAX = (1ULL << 10),
23 TEST_BBDEV_VF_ITER_MIN = (1ULL << 11),
24 TEST_BBDEV_VF_EXPECTED_ITER_COUNT = (1ULL << 12),
25 TEST_BBDEV_VF_EXT_SCALE = (1ULL << 13),
26 TEST_BBDEV_VF_NUM_MAPS = (1ULL << 14),
27 TEST_BBDEV_VF_NCB = (1ULL << 15),
28 TEST_BBDEV_VF_NCB_NEG = (1ULL << 16),
29 TEST_BBDEV_VF_NCB_POS = (1ULL << 17),
30 TEST_BBDEV_VF_R = (1ULL << 18),
31 TEST_BBDEV_VF_CODE_BLOCK_MODE = (1ULL << 19),
32 TEST_BBDEV_VF_OP_FLAGS = (1ULL << 20),
33 TEST_BBDEV_VF_EXPECTED_STATUS = (1ULL << 21),
48 struct op_data_entries {
49 struct op_data_buf segments[RTE_BBDEV_MAX_CODE_BLOCKS];
50 unsigned int nb_segments;
53 struct test_bbdev_vector {
54 enum rte_bbdev_op_type op_type;
58 struct rte_bbdev_op_turbo_dec turbo_dec;
59 struct rte_bbdev_op_turbo_enc turbo_enc;
61 /* Additional storage for op data entries */
62 struct op_data_entries entries[DATA_NUM_TYPES];
65 /* fills test vector parameters based on test file */
67 test_bbdev_vector_read(const char *filename,
68 struct test_bbdev_vector *vector);
71 #endif /* TEST_BBDEV_VECTOR_H_ */