Netdev List
 help / color / mirror / Atom feed
From: Yunsheng Lin <linyunsheng@huawei.com>
To: Li RongQing <lirongqing@baidu.com>, <netdev@vger.kernel.org>,
	<edumazet@google.com>
Subject: Re: [PATCH] net: fix the per task frag allocator size
Date: Fri, 23 Nov 2018 10:19:23 +0800	[thread overview]
Message-ID: <deeed503-acc8-4d32-73cd-63b7c98fe0a7@huawei.com> (raw)
In-Reply-To: <1542938606-9676-1-git-send-email-lirongqing@baidu.com>

On 2018/11/23 10:03, Li RongQing wrote:
> when fill task frag, 32K pages, 128MB memory is asked, it
> hardly successes when system has memory stress
> 
> and commit '5640f7685831 ("net: use a per task frag allocator")'
> said it wants 32768 bytes, not 32768 pages:
> 
> 	 "(up to 32768 bytes per frag, thats order-3 pages on x86)"
> 
> Fixes: 5640f7685831e ("net: use a per task frag allocator")
> Signed-off-by: Zhang Yu <zhangyu31@baidu.com>
> Signed-off-by: Li RongQing <lirongqing@baidu.com>
> ---
>  net/core/sock.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/net/core/sock.c b/net/core/sock.c
> index 6d7e189e3cd9..e3cbefeedf5c 100644
> --- a/net/core/sock.c
> +++ b/net/core/sock.c
> @@ -2186,8 +2186,8 @@ static void sk_leave_memory_pressure(struct sock *sk)
>  	}
>  }
>  
> -/* On 32bit arches, an skb frag is limited to 2^15 */
> -#define SKB_FRAG_PAGE_ORDER	get_order(32768)
> +/* On 32bit arches, an skb frag is limited to 2^15 bytes*/
> +#define SKB_FRAG_PAGE_ORDER	get_order(8)

get_order(8) returns zero here if I understood it correctly.


>  
>  /**
>   * skb_page_frag_refill - check that a page_frag contains enough room
> 

  reply	other threads:[~2018-11-23 13:01 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-23  2:03 [PATCH] net: fix the per task frag allocator size Li RongQing
2018-11-23  2:19 ` Yunsheng Lin [this message]
2018-11-23  2:40   ` 答复: " Li,Rongqing

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=deeed503-acc8-4d32-73cd-63b7c98fe0a7@huawei.com \
    --to=linyunsheng@huawei.com \
    --cc=edumazet@google.com \
    --cc=lirongqing@baidu.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox