From 9f8d3dec72f97deaede34fdc5960a69d7363132a Mon Sep 17 00:00:00 2001 From: Suren Baghdasaryan Date: Mon, 14 Dec 2020 13:10:59 -0800 Subject: [PATCH] lmkd: Remove unused workingset_refault parsing from zoneinfo workingset_refault field in zoneinfo is currently being parsed but is not used. Instead the same field in vmstat is being used to capture the number of file-backed workingset refaults. Remove the unused field parsing code. Bug: 175617952 Test: lmkd_unit_test Signed-off-by: Suren Baghdasaryan Change-Id: I79641a833c252cf50ac08c0c7d17c8294236d82d --- lmkd.cpp | 5 ----- 1 file changed, 5 deletions(-) diff --git a/lmkd.cpp b/lmkd.cpp index 8d872df..937e63d 100644 --- a/lmkd.cpp +++ b/lmkd.cpp @@ -336,21 +336,18 @@ struct zoneinfo_zone { enum zoneinfo_node_field { ZI_NODE_NR_INACTIVE_FILE = 0, ZI_NODE_NR_ACTIVE_FILE, - ZI_NODE_WORKINGSET_REFAULT, ZI_NODE_FIELD_COUNT }; static const char* const zoneinfo_node_field_names[ZI_NODE_FIELD_COUNT] = { "nr_inactive_file", "nr_active_file", - "workingset_refault", }; union zoneinfo_node_fields { struct { int64_t nr_inactive_file; int64_t nr_active_file; - int64_t workingset_refault; } field; int64_t arr[ZI_NODE_FIELD_COUNT]; }; @@ -371,7 +368,6 @@ struct zoneinfo { int64_t totalreserve_pages; int64_t total_inactive_file; int64_t total_active_file; - int64_t total_workingset_refault; }; /* Fields to parse in /proc/meminfo */ @@ -1718,7 +1714,6 @@ static int zoneinfo_parse(struct zoneinfo *zi) { } zi->total_inactive_file += node->fields.field.nr_inactive_file; zi->total_active_file += node->fields.field.nr_active_file; - zi->total_workingset_refault += node->fields.field.workingset_refault; } return 0; }