On 2018年09月03日 19:54, Daniel P. Berrangé wrote:
+ *
+ * This work is licensed under the terms of the GNU GPL, version 2 or later.
+ * See the COPYING file in the top-level directory.
+ *
+ */
+
+#include <linux/bpf.h>
+
+#ifndef BPF_RSS_INSNS
+#define BPF_RSS_INSNS
+
+/* bpf_insn array matching l3_l4 section. see tap_bpf_program.c file */
+struct bpf_insn l3_l4_hash_insns[] = {
+{0xbf , 0x6 , 0x1 , 0x0000 , 0x00000000},
+{0x28 , 0x0 , 0x0 , 0x0000 , 0x0000000c},
+{0xbf , 0x8 , 0x0 , 0x0000 , 0x00000000},
[snip]
+};
This massive array is presumably an auto-generated content.
We shouldn't be storing this in GIT. We need to store the
original preferred source format, and providing makefile
rules to generate it.
This is possible. But it depends on eBPF toolchain (e.g recent version
of LLVM) to work which is inflexible or impossible to make it work on
some distributions. Providing compiled bytecode does not have such
limitation.
Thanks