diff options
author | 2017-06-10 19:05:47 -0400 | |
---|---|---|
committer | 2017-06-10 19:05:47 -0400 | |
commit | 9fd7aca2c604fd19c0822d9b1520fb8ec16a81fb (patch) | |
tree | d8fc58484a521feb4eeb19bbb332e00148efe51e /include | |
parent | net: fec: Add a fec_enet_clear_ethtool_stats() stub for CONFIG_M5272 (diff) | |
parent | bpf: add bpf_set_hash helper for tc progs (diff) | |
download | wireguard-linux-9fd7aca2c604fd19c0822d9b1520fb8ec16a81fb.tar.xz wireguard-linux-9fd7aca2c604fd19c0822d9b1520fb8ec16a81fb.zip |
Merge branch 'bpf-misc-updates'
Daniel Borkmann says:
====================
Misc BPF updates
This set contains a couple of misc updates: stack usage reduction
for perf_sample_data in tracing progs, reduction of stale data in
verifier on register state transitions that I still had in my queue
and few selftest improvements as well as bpf_set_hash() helper for
tc programs.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r-- | include/uapi/linux/bpf.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/include/uapi/linux/bpf.h b/include/uapi/linux/bpf.h index 9b2c10b45733..f94b48b168dc 100644 --- a/include/uapi/linux/bpf.h +++ b/include/uapi/linux/bpf.h @@ -513,6 +513,11 @@ union bpf_attr { * Get the owner uid of the socket stored inside sk_buff. * @skb: pointer to skb * Return: uid of the socket owner on success or overflowuid if failed. + * + * u32 bpf_set_hash(skb, hash) + * Set full skb->hash. + * @skb: pointer to skb + * @hash: hash to set */ #define __BPF_FUNC_MAPPER(FN) \ FN(unspec), \ @@ -562,7 +567,8 @@ union bpf_attr { FN(xdp_adjust_head), \ FN(probe_read_str), \ FN(get_socket_cookie), \ - FN(get_socket_uid), + FN(get_socket_uid), \ + FN(set_hash), /* integer value in 'imm' field of BPF_CALL instruction selects which helper * function eBPF program intends to call |