diff options
author | Justus Winter <justus@gnupg.org> | 2016-02-23 01:21:44 +0100 |
---|---|---|
committer | Justus Winter <justus@gnupg.org> | 2016-02-23 01:21:44 +0100 |
commit | 59b9cf8f46fb5a186fafe08b2086913cf1b00188 (patch) | |
tree | 4e5d17b1d009003f9da1884912f6a90aff8ce012 /procfs/rootdir.c | |
parent | 0cb36265d2f76a3445823ece7944e9c1c8c0c341 (diff) |
procfs: adapt to kernel interface change
procfs makes use of the debug interface which is subject to change.
* procfs/rootdir.c (rootdir_gc_slabinfo): The flag
CACHE_FLAGS_NO_RECLAIM is no longer used.
Diffstat (limited to 'procfs/rootdir.c')
-rw-r--r-- | procfs/rootdir.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/procfs/rootdir.c b/procfs/rootdir.c index 1e9ec8f3..93fef8d9 100644 --- a/procfs/rootdir.c +++ b/procfs/rootdir.c @@ -446,12 +446,11 @@ rootdir_gc_slabinfo (void *hook, char **contents, ssize_t *contents_len) for (i = 0; i < cache_info_count; i++) { - mem_usage = (cache_info[i].nr_slabs * cache_info[i].slab_size) - >> 10; + mem_usage = + (cache_info[i].nr_slabs * cache_info[i].slab_size) >> 10; mem_total += mem_usage; - mem_reclaimable = (cache_info[i].flags & CACHE_FLAGS_NO_RECLAIM) - ? 0 : (cache_info[i].nr_free_slabs - * cache_info[i].slab_size) >> 10; + mem_reclaimable = + (cache_info[i].nr_free_slabs * cache_info[i].slab_size) >> 10; mem_total_reclaimable += mem_reclaimable; fprintf (m, "%-21s %04x %7zu %3zuk %4lu %6lu %6lu %7zuk %10zuk\n", |