summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/bpf/progs/btf_data.c
blob: 8082c13490abda88c03e398483e26f6f0f4a4cd7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
// SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause)

struct S {
	int	a;
	int	b;
	int	c;
};

union U {
	int	a;
	int	b;
	int	c;
};

struct S1 {
	int	a;
	int	b;
	int	c;
};

union U1 {
	int	a;
	int	b;
	int	c;
};

typedef int T;
typedef int S;
typedef int U;
typedef int T1;
typedef int S1;
typedef int U1;

struct root_struct {
	S		m_1;
	T		m_2;
	U		m_3;
	S1		m_4;
	T1		m_5;
	U1		m_6;
	struct S	m_7;
	struct S1	m_8;
	union  U	m_9;
	union  U1	m_10;
};

int func(struct root_struct *root)
{
	return 0;
}

int kfunc_a(struct root_struct *root)
{
	return 0;
}

int kfunc_b(struct root_struct *root)
{
	return 0;
}

struct root_struct *kfunc_c(struct root_struct *a, struct root_struct *b)
{
	return a;
}

int kfunc_d(struct root_struct *a, struct root_struct *b)
{
	return 0;
}

int kfunc_e(struct root_struct *a__arena,
	    struct root_struct *b__arena__nullable,
	    struct root_struct *c__arena,
	    struct root_struct *d__arena__nullable,
	    struct root_struct *e__arena)
{
	return 0;
}

int kfunc_f(struct root_struct *a, struct root_struct *b__arena, int flags)
{
	return 0;
}

struct root_struct *kfunc_g(struct root_struct *a__arena,
			    struct root_struct *b__arena__nullable)
{
	return a__arena;
}