Skip to content

Commit

Permalink
perf kmem: Fix statistics typo
Browse files Browse the repository at this point in the history
Replace bytes_req with bytes_alloc.

Signed-off-by: Wenji Huang <wenji.huang@oracle.com>
Reviewed-by: Li Zefan <lizf@cn.fujitsu.com>
Cc: acme@redhat.com
LKML-Reference: <1261389175-2227-1-git-send-email-wenji.huang@oracle.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Wenji Huang authored and Ingo Molnar committed Dec 28, 2009
1 parent c2ef666 commit 4efb529
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/perf/builtin-kmem.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ static void insert_alloc_stat(unsigned long call_site, unsigned long ptr,
if (data && data->ptr == ptr) {
data->hit++;
data->bytes_req += bytes_req;
data->bytes_alloc += bytes_req;
data->bytes_alloc += bytes_alloc;
} else {
data = malloc(sizeof(*data));
if (!data)
Expand Down Expand Up @@ -177,7 +177,7 @@ static void insert_caller_stat(unsigned long call_site,
if (data && data->call_site == call_site) {
data->hit++;
data->bytes_req += bytes_req;
data->bytes_alloc += bytes_req;
data->bytes_alloc += bytes_alloc;
} else {
data = malloc(sizeof(*data));
if (!data)
Expand Down

0 comments on commit 4efb529

Please sign in to comment.