lkml.org 
[lkml]   [2014]   [Dec]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] tools: testing: selftests: powerpc: pmu: ebb: trace.c: Remove some unused functions
Date
Removes some functions that are not used anywhere:
trace_log_outdent() trace_log_indent()

This was partially found by using a static code analysis program called cppcheck.

Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
---
tools/testing/selftests/powerpc/pmu/ebb/trace.c | 26 -----------------------
tools/testing/selftests/powerpc/pmu/ebb/trace.h | 2 --
2 files changed, 28 deletions(-)

diff --git a/tools/testing/selftests/powerpc/pmu/ebb/trace.c b/tools/testing/selftests/powerpc/pmu/ebb/trace.c
index 251e66a..2b18b22 100644
--- a/tools/testing/selftests/powerpc/pmu/ebb/trace.c
+++ b/tools/testing/selftests/powerpc/pmu/ebb/trace.c
@@ -139,32 +139,6 @@ int trace_log_string(struct trace_buffer *tb, char *str)
return 0;
}

-int trace_log_indent(struct trace_buffer *tb)
-{
- struct trace_entry *e;
-
- e = trace_alloc_entry(tb, 0);
- if (!e)
- return -ENOSPC;
-
- e->type = TRACE_TYPE_INDENT;
-
- return 0;
-}
-
-int trace_log_outdent(struct trace_buffer *tb)
-{
- struct trace_entry *e;
-
- e = trace_alloc_entry(tb, 0);
- if (!e)
- return -ENOSPC;
-
- e->type = TRACE_TYPE_OUTDENT;
-
- return 0;
-}
-
static void trace_print_header(int seq, int prefix)
{
printf("%*s[%d]: ", prefix, "", seq);
diff --git a/tools/testing/selftests/powerpc/pmu/ebb/trace.h b/tools/testing/selftests/powerpc/pmu/ebb/trace.h
index 926458e..6c436d7 100644
--- a/tools/testing/selftests/powerpc/pmu/ebb/trace.h
+++ b/tools/testing/selftests/powerpc/pmu/ebb/trace.h
@@ -33,8 +33,6 @@ struct trace_buffer *trace_buffer_allocate(u64 size);
int trace_log_reg(struct trace_buffer *tb, u64 reg, u64 value);
int trace_log_counter(struct trace_buffer *tb, u64 value);
int trace_log_string(struct trace_buffer *tb, char *str);
-int trace_log_indent(struct trace_buffer *tb);
-int trace_log_outdent(struct trace_buffer *tb);
void trace_buffer_print(struct trace_buffer *tb);
void trace_print_location(struct trace_buffer *tb);

--
1.7.10.4


\
 
 \ /
  Last update: 2014-12-08 00:01    [W:0.036 / U:0.176 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site