We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 557c8c4 commit 8c18ea2Copy full SHA for 8c18ea2
tools/testing/selftests/bpf/progs/tag.c
@@ -24,18 +24,23 @@ struct key_t {
24
int c;
25
} __tag1 __tag2;
26
27
+typedef struct {
28
+ int a;
29
+ int b;
30
+} value_t __tag1 __tag2;
31
+
32
struct {
33
__uint(type, BPF_MAP_TYPE_HASH);
34
__uint(max_entries, 3);
35
__type(key, struct key_t);
- __type(value, __u64);
36
+ __type(value, value_t);
37
} hashmap1 SEC(".maps");
38
39
40
static __noinline int foo(int x __tag1 __tag2) __tag1 __tag2
41
{
42
struct key_t key;
- __u64 val = 1;
43
+ value_t val = {};
44
45
key.a = key.b = key.c = x;
46
bpf_map_update_elem(&hashmap1, &key, &val, 0);
0 commit comments