Displaying 1 result from an estimated 1 matches for "prog_type".
2018 Sep 13
4
bpf compilation using clang
...ollowing error:
back-edge from insn 363 to 364
or something similar even though the compilation succeeds.
I have multiple maps in my code and I translate only the code section
to bpf insns structure and insert it using the bpf syscall as follows:
memset(&attr, 0, sizeof(attr));
attr.prog_type = BPF_PROG_TYPE_SOCKET_FILTER;
attr.insn_cnt = ARRAY_SIZE(l3_l4_hash_insns);
attr.insns = (__u64) (unsigned long) (l3_l4_hash_insns);
attr.license = (__u64) (unsigned long) ("Dual BSD/GPL");
attr.log_buf = (__u64) (unsigned long) (buffer);
attr.log_level = 7;
attr....