Subject: Re: [PATCH v2] net: Remove low_thresh in ip defrag

From: Petr Machata <[email-masked]>
Date: Mon, 15 May 2023 14:46:03 +0200

Angus Chen <[email-masked]> writes:

> As low_thresh has no work in fragment reassembles,del it.
> And Mark it deprecated in sysctl Document.
>
> Signed-off-by: Angus Chen <[email-masked]>

When you spin a fix for the issue that Ido has reported, could you also
smuggle in the following fixlets?

> diff --git a/net/ieee802154/6lowpan/reassembly.c b/net/ieee802154/6lowpan/reassembly.c
> index a91283d1e5bf..3ba4c0f27af9 100644
> --- a/net/ieee802154/6lowpan/reassembly.c
> +++ b/net/ieee802154/6lowpan/reassembly.c
> @@ -318,7 +318,7 @@ int lowpan_frag_rcv(struct sk_buff *skb, u8 frag_type)
>  }
>  
>  #ifdef CONFIG_SYSCTL
> -
> +static unsigned long lowpanfrag_low_thresh_unuesd = IPV6_FRAG_LOW_THRESH;

s/unuesd/unused/

> @@ -674,12 +674,9 @@ static int __net_init ipv4_frags_init_net(struct net *net)
>  	 * A 64K fragment consumes 129736 bytes (44*2944)+200
>  	 * (1500 truesize == 2944, sizeof(struct ipq) == 200)
>  	 *
> -	 * We will commit 4MB at one time. Should we cross that limit
> -	 * we will prune down to 3MB, making room for approx 8 big 64K
> -	 * fragments 8x128k.
> +	 * We will commit 4MB at one time. Should we cross that limit.

"Should we cross that limit" means "when it happens that we cross that
limit". So on its own it conveys no information and can be dropped.

>  	 */
>  	net->ipv4.fqdir->high_thresh = 4 * 1024 * 1024;
> -	net->ipv4.fqdir->low_thresh  = 3 * 1024 * 1024;
>  	/*
>  	 * Important NOTE! Fragment queue must be destroyed before MSL expires.
>  	 * RFC791 is wrong proposing to prolongate timer each fragment arrival

Thanks!