Re: [PATCH] bpf: Add bpf_skb_get_sock_comm() helper

2020-08-19 Thread Martin KaFai Lau
On Wed, Aug 19, 2020 at 02:10:56PM +0800, 江禹 wrote: > Dear Martin, > > > > One possibility is to use the "sk_bpf_storage" member immediately above > > instead of adding "sk_task_com[]". > > > > It is an extensible sk storage for bpf. There are examples in selftests, > > e.g tools/testing/selfte

Re: [PATCH] bpf: Add bpf_skb_get_sock_comm() helper

2020-08-10 Thread Martin KaFai Lau
On Mon, Aug 10, 2020 at 06:09:48AM -0700, Jiang Yu wrote: > skb distinguished by uid can only recorded to user who consume them. > in many case, skb should been recorded more specific to process who > consume them. E.g, the unexpected large data traffic of illegal process > in metered network. > >

Re: [PATCH] bpf: Add bpf_skb_get_sock_comm() helper

2020-08-10 Thread Eric Dumazet
On 8/10/20 6:09 AM, Jiang Yu wrote: > skb distinguished by uid can only recorded to user who consume them. > in many case, skb should been recorded more specific to process who > consume them. E.g, the unexpected large data traffic of illegal process > in metered network. > > this helper is use