Re: [Patch bpf-next v5 06/11] sock: introduce sk->sk_prot->psock_update_sk_prot()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 18, 2021 at 5:09 AM Alexander Lobakin <alobakin@xxxxx> wrote:
> Regarding that both {tcp,udp}_bpf_update_proto() is global and
> for now they are the only two implemented callbacks, wouldn't it
> be worthy to straighten the calls here? Like
>
>         return INDIRECT_CALL_2(sk->sk_prot->psock_update_sk_prot,
>                                tcp_bpf_update_proto,
>                                udp_bpf_update_proto,
>                                sk, false);

I get your point, but AF_UNIX will implement this in the next patchset,
and my colleague is working on vsock support too, so it will go beyond
INET very soon.

>
> (the same in sk_psock_restore_proto() then)
>
> Or this code path is not performance-critical?

It is not on the hot path, updating proto happens when we insert
the socket to the map or remove it from there.

Thanks.



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux