• Vlastimil Babka's avatar
    mm: rename and change semantics of nr_indirectly_reclaimable_bytes · b29940c1
    Vlastimil Babka authored
    The vmstat counter NR_INDIRECTLY_RECLAIMABLE_BYTES was introduced by
    commit eb592546 ("mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES") with
    the goal of accounting objects that can be reclaimed, but cannot be
    allocated via a SLAB_RECLAIM_ACCOUNT cache.  This is now possible via
    kmalloc() with __GFP_RECLAIMABLE flag, and the dcache external names user
    is converted.
    
    The counter is however still useful for accounting direct page allocations
    (i.e.  not slab) with a shrinker, such as the ION page pool.  So keep it,
    and:
    
    - change granularity to pages to be more like other counters; sub-page
      allocations should be able to use kmalloc
    - rename the counter to NR_KERNEL_MISC_RECLAIMABLE
    - expose the counter again in vmstat as "nr_kernel_misc_reclaimable"; we can
      again remove the check for not printing "hidden" counters
    
    Link: http://lkml.kernel.org/r/20180731090649.16028-5-vbabka@suse.czSigned-off-by: default avatarVlastimil Babka <vbabka@suse.cz>
    Acked-by: default avatarChristoph Lameter <cl@linux.com>
    Acked-by: default avatarRoman Gushchin <guro@fb.com>
    Cc: Vijayanand Jitta <vjitta@codeaurora.org>
    Cc: Laura Abbott <labbott@redhat.com>
    Cc: Sumit Semwal <sumit.semwal@linaro.org>
    Cc: David Rientjes <rientjes@google.com>
    Cc: Johannes Weiner <hannes@cmpxchg.org>
    Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com>
    Cc: Matthew Wilcox <willy@infradead.org>
    Cc: Mel Gorman <mgorman@techsingularity.net>
    Cc: Michal Hocko <mhocko@kernel.org>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    b29940c1
util.c 19.5 KB