[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1470318647.13693.28.camel@edumazet-glaptop3.roam.corp.google.com>
Date: Thu, 04 Aug 2016 15:50:47 +0200
From: Eric Dumazet <eric.dumazet@...il.com>
To: Ilya Lesokhin <ilyal@...lanox.com>
Cc: "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"edumazet@...gle.com" <edumazet@...gle.com>
Subject: Re: [PATCH] net: use non-compound pages in frag allocator
On Thu, 2016-08-04 at 13:38 +0000, Ilya Lesokhin wrote:
> You are right I just realized that this patch causes a memory leak, so sorry for the spam.
>
> I just had problem understanding when compound pages are needed and when It is enough to use an high order pages.
> I thought that that high order pages are enough for this use case, tested it and saw no problems.
>
> Unfortunately it seems you must use compound pages to keep track of the page order.
> put_page assumes that the order of a non-compound page is always 0.
> It would be nice to document it somewhere but I'm not sure where.
Please do not top-post on netdev mailing list.
( Documentation/development-process/2.Process : line 422 )
AFAIK, only when we can call free_pages(p, order) and provide @order, we
can avoid using __GFP_COMP at alloc time.
But if some path has to use put_page(), then we are forced to use
__GFP_COMP for high order pages.
Thanks.
Powered by blists - more mailing lists