/bin/dmesg to dmesg Path
PATCH 1/1 /bin/dmesg to dmesg Path
Dmesg is not in every distro at /bin/dmesg, in NixOS for example, this fails, but the path should in most cases contain dmesg.
This follows the example of replacing /bin/bash with bash Path in the codebase.
---tools/perf/util/evsel.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
tools/perf/util/evsel.c +0 -0
@@ -3053,7 +3053,7 @@ int evsel__open_strerror(struct evsel *evsel, struct target *target,
return scnprintf(msg, size,
"The sys_perf_event_open() syscall returned with %d (%s) for event (%s).\n"
- "/bin/dmesg | grep -i perf may provide additional information.\n",
+ "dmesg | grep -i perf may provide additional information.\n", err, str_error_r(err, sbuf, sizeof(sbuf)), evsel__name(evsel)); }
--
2.42.0
Hello,
Quoted 22 lines · April John
Dmesg is not in every distro at
/bin/dmesg, in NixOS for example, this fails, but the path should in most cases contain dmesg.
This follows the example of replacing/bin/bashwith bash Path in the codebase.---
tools/perf/util/evsel.c| 2 +-1 file changed, 1 insertion(+), 1 deletion(-)tools/perf/util/evsel.c +0
-0@@ -3053,7 +3053,7 @@ int evsel__open_strerror(struct evsel *evsel, struct target *target, return scnprintf(msg, size,"The
sys_perf_event_open()syscall returned with %d (%s) for event (%s).\n"
- "/bin/dmesg| grep -i perf may provide additional information.\n",
+ "dmesg | grep -i perf may provide additional information.\n", err,str_error_r(err, sbuf, sizeof(sbuf)),evsel__name(evsel)); }
Quoted 4 lines
--
2.42.0Signed-off-by April John <[email protected]>
It is usual to put a tag after the patch, it should be at the end of the commit message. With that,
Thanks,
Namhyung
Namhyung Kim
maintainerQuoted 29 lines · Namhyung Kim
Hello,
Quoted 25 lines · April John
Dmesg is not in every distro at
/bin/dmesg, in NixOS for example, this fails, but the path should in most cases contain dmesg.
This follows the example of replacing/bin/bashwith bash Path in the codebase.---
tools/perf/util/evsel.c| 2 +-1 file changed, 1 insertion(+), 1 deletion(-)tools/perf/util/evsel.c +0
-0@@ -3053,7 +3053,7 @@ int evsel__open_strerror(struct evsel *evsel, struct target *target, return scnprintf(msg, size,"The
sys_perf_event_open()syscall returned with %d (%s) for event (%s).\n"
- "/bin/dmesg| grep -i perf may provide additional information.\n",
+ "dmesg | grep -i perf may provide additional information.\n", err,str_error_r(err, sbuf, sizeof(sbuf)),evsel__name(evsel)); }--
2.42.0
Quoted 6 lines
Quoted 1 line
Signed-off-by April John <[email protected]>It is usual to put a tag after the patch, it should be at the end of the commit message. With that,
Acked-by Namhyung Kim <[email protected]>
I've tried to apply the patch but it failed. It looks broken. Have you generated it using git format-patch ?
Thanks,
Namhyung
Applying: /bin/dmesg to dmesg Path
error: corrupt patch at line 11
Patch failed at 0001 /bin/dmesg to dmesg Path