diff options
| author | David S. Miller <davem@davemloft.net> | 2015-06-15 15:53:50 -0700 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2015-06-15 15:58:26 -0700 |
| commit | 9f42c8b3ebc80e8a544bcf726689d51c7e1e0fc8 (patch) | |
| tree | 6b4c9543550d114d75fad4362c6ef526a0d24b77 /include/linux | |
| parent | ada6c1de9ecabcfc5619479bcd29a208f2e248a0 (diff) | |
| parent | ab1973d3258aa8c40d153dc12bbb1aac56731e47 (diff) | |
| download | cachepc-linux-9f42c8b3ebc80e8a544bcf726689d51c7e1e0fc8.tar.gz cachepc-linux-9f42c8b3ebc80e8a544bcf726689d51c7e1e0fc8.zip | |
Merge branch 'bpf-share-helpers'
Alexei Starovoitov says:
====================
v1->v2: switched to init_user_ns from current_user_ns as suggested by Andy
Introduce new helpers to access 'struct task_struct'->pid, tgid, uid, gid, comm
fields in tracing and networking.
Share bpf_trace_printk() and bpf_get_smp_processor_id() helpers between
tracing and networking.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/bpf.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/bpf.h b/include/linux/bpf.h index 2235aee8096a..4383476a0d48 100644 --- a/include/linux/bpf.h +++ b/include/linux/bpf.h @@ -150,6 +150,7 @@ struct bpf_array { u64 bpf_tail_call(u64 ctx, u64 r2, u64 index, u64 r4, u64 r5); void bpf_prog_array_map_clear(struct bpf_map *map); bool bpf_prog_array_compatible(struct bpf_array *array, const struct bpf_prog *fp); +const struct bpf_func_proto *bpf_get_trace_printk_proto(void); #ifdef CONFIG_BPF_SYSCALL void bpf_register_prog_type(struct bpf_prog_type_list *tl); @@ -188,5 +189,8 @@ extern const struct bpf_func_proto bpf_get_prandom_u32_proto; extern const struct bpf_func_proto bpf_get_smp_processor_id_proto; extern const struct bpf_func_proto bpf_tail_call_proto; extern const struct bpf_func_proto bpf_ktime_get_ns_proto; +extern const struct bpf_func_proto bpf_get_current_pid_tgid_proto; +extern const struct bpf_func_proto bpf_get_current_uid_gid_proto; +extern const struct bpf_func_proto bpf_get_current_comm_proto; #endif /* _LINUX_BPF_H */ |
