perf genelf: Fix NO_LIBDW=1 build
Ian Rogers
reviewerPATCH 1/1 perf genelf: Fix NO_LIBDW=1 build
With NO_LIBDW=1 a new unused-parameter warning/error has appeared:
``` util/genelf.c: In function ‘jit_write_elf’: util/genelf.c:163:32: error: unused parameter ‘load_addr’ [-Werror=unused-parameter] 163 | jit_write_elf(int fd, uint64_t load_addr, const char *sym, ```
Fixes e3f612c1d8f3 ("perf genelf: Remove libcrypto dependency and use built-in sha1()")
Signed-off-by Ian Rogers <[email protected]>
--- tools/perf/util/genelf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
tools/perf/util/genelf.c +1 -1
@@ -160,7 +160,7 @@ jit_add_eh_frame_info(Elf *e, void* unwinding, uint64_t unwinding_header_size,* csize: the code size in bytes */ int -jit_write_elf (int fd,uint64_t load_addr,const char *sym, +jit_write_elf (int fd,uint64_t load_addr__maybe_unused ,const char *sym,const void *code,int csize,void *debug__maybe_unused ,int nr_debug_entries__maybe_unused ,void *unwinding,uint64_t unwinding_header_size,uint64_t unwinding_size)
Signature · 1 line
2.50.0.727.gbf7dc18ff4-goog
Namhyung Kim
maintainerQuoted 6 lines · Ian Rogers
With NO_LIBDW=1 a new unused-parameter warning/error has appeared:
``` util/genelf.c: In function ‘jit_write_elf’: util/genelf.c:163:32: error: unused parameter ‘load_addr’ [-Werror=unused-parameter] 163 | jit_write_elf(int fd, uint64_t load_addr, const char *sym, ```
Thanks for the fix.
And I found there's no entry for NO_LIBDW=1 in the build-test. Can you please add one?
Thanks,
Namhyung
Quoted 23 lines
Fixes e3f612c1d8f3 ("perf genelf: Remove libcrypto dependency and use built-in sha1()")Signed-off-by Ian Rogers <[email protected]>--- tools/perf/util/genelf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)tools/perf/util/genelf.c +1
-1@@ -160,7 +160,7 @@ jit_add_eh_frame_info(Elf *e, void* unwinding, uint64_t unwinding_header_size,* csize: the code size in bytes */ int -jit_write_elf (int fd,uint64_t load_addr,const char *sym, +jit_write_elf (int fd,uint64_t load_addr__maybe_unused ,const char *sym,const void *code,int csize,void *debug__maybe_unused ,int nr_debug_entries__maybe_unused ,void *unwinding,uint64_t unwinding_header_size,uint64_t unwinding_size)Signature · 1 line
2.50.0.727.gbf7dc18ff4-goog
Quoted 8 lines · Ian Rogers
With NO_LIBDW=1 a new unused-parameter warning/error has appeared:
``` util/genelf.c: In function ‘jit_write_elf’: util/genelf.c:163:32: error: unused parameter ‘load_addr’ [-Werror=unused-parameter] 163 | jit_write_elf(int fd, uint64_t load_addr, const char *sym, ```[...]
Applied to perf-tools-next, thanks!
Best regards,
Namhyung