lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3949dfa2-d684-47af-ffa7-71b07141f64d@huawei.com>
Date:   Tue, 28 Sep 2021 14:32:02 +0100
From:   John Garry <john.garry@...wei.com>
To:     Arnaldo Carvalho de Melo <acme@...nel.org>
CC:     Like Xu <like.xu.linux@...il.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Ingo Molnar <mingo@...hat.com>,
        Mark Rutland <mark.rutland@....com>,
        Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
        Jiri Olsa <jolsa@...hat.com>,
        Namhyung Kim <namhyung@...nel.org>,
        <linux-perf-users@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] perf jevents: Fix sys_event_tables to be freed like
 arch_std_events

On 28/09/2021 14:22, Arnaldo Carvalho de Melo wrote:
>   jevents-y      += json.o jsmn.o jevents.o
> -HOSTCFLAGS_jevents.o   = -I$(srctree)/tools/include
> +HOSTCFLAGS_jevents.o   = -I$(srctree)/tools/include -Wall -Wextra
>   pmu-events-y   += pmu-events.o
>   JDIR           =  pmu-events/arch/$(SRCARCH)
>   JSON           =  $(shell [ -d $(JDIR) ] &&                            \
> ⬢[acme@...lbox perf]$
> 
> I get this before applying Xu's patch:
> 
>    LINK    /tmp/build/perf/libbpf.a
> pmu-events/jevents.c: In function ‘save_arch_std_events’:
> pmu-events/jevents.c:473:39: warning: unused parameter ‘data’ [-Wunused-parameter]
>    473 | static int save_arch_std_events(void *data, struct json_event *je)
>        |                                 ~~~~~~^~~~
> At top level:
> pmu-events/jevents.c:93:13: warning: ‘free_sys_event_tables’ defined but not used [-Wunused-function]
>     93 | static void free_sys_event_tables(void)
>        |             ^~~~~~~~~~~~~~~~~~~~~
> 
> 
> -------------------------------------
> 
> I'll add this to perf/core, as this isn't a strict fix, so can wait for
> v5.16.

Hi Arnaldo,

OK, would you also consider reusing CFLAGS:

--- a/tools/perf/pmu-events/Build
+++ b/tools/perf/pmu-events/Build
@@ -9,10 +9,12 @@ JSON          =  $(shell [ -d $(JDIR) ] && 
                \
JDIR_TEST      =  pmu-events/arch/test
JSON_TEST      =  $(shell [ -d $(JDIR_TEST) ] &&                       \
                        find $(JDIR_TEST) -name '*.json')
-
+HOSTCFLAGS_jevents += $(CFLAGS)

I tried it, and there are more things to fix for jevents.o. Let me know 
your preference and if any help required to fix any errors up.

Thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ