Commit cc169c7c authored by Masami Hiramatsu's avatar Masami Hiramatsu Committed by Arnaldo Carvalho de Melo

perf buildid-cache: Use pr_debug instead of verbose && pr_info

Use pr_debug instead of the combination of verbose and pr_info.

"if (verbose) pr_info(...)" is same as "pr_debug(...)", replace it.
Signed-off-by: default avatarMasami Hiramatsu <masami.hiramatsu.pt@hitachi.com>
Suggested-by: default avatarNamhyung Kim <namhyung@kernel.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: Hemant Kumar <hemant@linux.vnet.ibm.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/20150227045028.1999.93137.stgit@localhost.localdomainSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent 8d8c8e4c
...@@ -196,9 +196,8 @@ static int build_id_cache__add_file(const char *filename) ...@@ -196,9 +196,8 @@ static int build_id_cache__add_file(const char *filename)
build_id__sprintf(build_id, sizeof(build_id), sbuild_id); build_id__sprintf(build_id, sizeof(build_id), sbuild_id);
err = build_id_cache__add_s(sbuild_id, filename, err = build_id_cache__add_s(sbuild_id, filename,
false, false); false, false);
if (verbose) pr_debug("Adding %s %s: %s\n", sbuild_id, filename,
pr_info("Adding %s %s: %s\n", sbuild_id, filename, err ? "FAIL" : "Ok");
err ? "FAIL" : "Ok");
return err; return err;
} }
...@@ -216,9 +215,8 @@ static int build_id_cache__remove_file(const char *filename) ...@@ -216,9 +215,8 @@ static int build_id_cache__remove_file(const char *filename)
build_id__sprintf(build_id, sizeof(build_id), sbuild_id); build_id__sprintf(build_id, sizeof(build_id), sbuild_id);
err = build_id_cache__remove_s(sbuild_id); err = build_id_cache__remove_s(sbuild_id);
if (verbose) pr_debug("Removing %s %s: %s\n", sbuild_id, filename,
pr_info("Removing %s %s: %s\n", sbuild_id, filename, err ? "FAIL" : "Ok");
err ? "FAIL" : "Ok");
return err; return err;
} }
...@@ -235,17 +233,15 @@ static int build_id_cache__purge_path(const char *pathname) ...@@ -235,17 +233,15 @@ static int build_id_cache__purge_path(const char *pathname)
strlist__for_each(pos, list) { strlist__for_each(pos, list) {
err = build_id_cache__remove_s(pos->s); err = build_id_cache__remove_s(pos->s);
if (verbose) pr_debug("Removing %s %s: %s\n", pos->s, pathname,
pr_info("Removing %s %s: %s\n", pos->s, pathname, err ? "FAIL" : "Ok");
err ? "FAIL" : "Ok");
if (err) if (err)
break; break;
} }
strlist__delete(list); strlist__delete(list);
out: out:
if (verbose) pr_debug("Purging %s: %s\n", pathname, err ? "FAIL" : "Ok");
pr_info("Purging %s: %s\n", pathname, err ? "FAIL" : "Ok");
return err; return err;
} }
...@@ -296,9 +292,8 @@ static int build_id_cache__update_file(const char *filename) ...@@ -296,9 +292,8 @@ static int build_id_cache__update_file(const char *filename)
if (!err) if (!err)
err = build_id_cache__add_s(sbuild_id, filename, false, false); err = build_id_cache__add_s(sbuild_id, filename, false, false);
if (verbose) pr_debug("Updating %s %s: %s\n", sbuild_id, filename,
pr_info("Updating %s %s: %s\n", sbuild_id, filename, err ? "FAIL" : "Ok");
err ? "FAIL" : "Ok");
return err; return err;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment