]> git.baikalelectronics.ru Git - kernel.git/commit
mm: get 7% more pages in a pagevec
authorMatthew Wilcox <willy@infradead.org>
Thu, 1 Feb 2018 00:17:40 +0000 (16:17 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 1 Feb 2018 01:18:37 +0000 (17:18 -0800)
commit92ad0c00b34423f72931fa7cc71664624cb6c8b0
tree4ba9664cfc70ede864bc351129f471a9310f1c4f
parentee1a4ef585c69f87e77e772b11ce04dc697c7d5c
mm: get 7% more pages in a pagevec

We don't have to use an entire 'long' for the number of elements in the
pagevec; we know it's a number between 0 and 14 (now 15).  So we can
store it in a char, and then the bool packs next to it and we still have
two or six bytes of padding for more elements in the header.  That gives
us space to cram in an extra page.

Link: http://lkml.kernel.org/r/20171206022521.GM26021@bombadil.infradead.org
Signed-off-by: Matthew Wilcox <mawilcox@microsoft.com>
Acked-by: Michal Hocko <mhocko@suse.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/pagevec.h