Re: [PATCH v3 bpf-next 11/11] bpf: selftest: Use bpf_skc_to_tcp_sock() in the sock_fields test

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

 



On Tue, Sep 22, 2020 at 12:05:18AM -0700, Martin KaFai Lau wrote:
>  
> @@ -165,9 +168,13 @@ int egress_read_sock_fields(struct __sk_buff *skb)
>  	tpcpy(tp_ret, tp);
>  
>  	if (sk_ret == &srv_sk) {
> +		ktp = bpf_skc_to_tcp_sock(sk);
> +		if (!ktp)
> +			RET_LOG();
> +		lsndtime = ktp->lsndtime;

If I understood the patches correctly they extend the use cases significantly,
but this test only covers cgroup/egress type with one particular helper.
Could you please expand the test cases to cover more of things from earlier
patches. Patch 7 covers some, but imo not enough.
Similarly the case of sk_release(sk) in one place and sk_release(ktp)
in another branch (one you mention in commit log) needs to have
C based selftest as well.



[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