1 | /* SPDX-License-Identifier: GPL-2.0 */ |
2 | /* Copyright (c) 2022 Meta Platforms, Inc. and affiliates. */ |
3 | |
4 | #ifndef _TEST_USER_RINGBUF_H |
5 | #define _TEST_USER_RINGBUF_H |
6 | |
7 | #define TEST_OP_64 4 |
8 | #define TEST_OP_32 2 |
9 | |
10 | enum test_msg_op { |
11 | TEST_MSG_OP_INC64, |
12 | TEST_MSG_OP_INC32, |
13 | TEST_MSG_OP_MUL64, |
14 | TEST_MSG_OP_MUL32, |
15 | |
16 | // Must come last. |
17 | TEST_MSG_OP_NUM_OPS, |
18 | }; |
19 | |
20 | struct test_msg { |
21 | enum test_msg_op msg_op; |
22 | union { |
23 | __s64 operand_64; |
24 | __s32 operand_32; |
25 | }; |
26 | }; |
27 | |
28 | struct sample { |
29 | int pid; |
30 | int seq; |
31 | long value; |
32 | char comm[16]; |
33 | }; |
34 | |
35 | #endif /* _TEST_USER_RINGBUF_H */ |
36 | |