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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAADnVQ+=Liu0t35yn4LHD3GuFiz53KvL8Moair0E3CRD_iZs7Q@mail.gmail.com>
Date:   Thu, 10 Dec 2020 21:46:04 -0800
From:   Alexei Starovoitov <alexei.starovoitov@...il.com>
To:     Andrii Nakryiko <andrii@...nel.org>
Cc:     bpf <bpf@...r.kernel.org>,
        Network Development <netdev@...r.kernel.org>,
        Alexei Starovoitov <ast@...com>,
        Daniel Borkmann <daniel@...earbox.net>,
        Kernel Team <kernel-team@...com>,
        Alexei Starovoitov <ast@...nel.org>
Subject: Re: [PATCH bpf-next] selftests/bpf: fix bpf_testmod.ko recompilation logic

On Thu, Dec 10, 2020 at 5:59 PM Andrii Nakryiko <andrii@...nel.org> wrote:
>
> bpf_testmod.ko build rule declared dependency on VMLINUX_BTF, but the variable
> itself was initialized after the rule was declared, which often caused
> bpf_testmod.ko to not be re-compiled. Fix by moving VMLINUX_BTF determination
> sooner.
>
> Also enforce bpf_testmod.ko recompilation when we detect that vmlinux image
> changed by removing bpf_testmod/bpf_testmod.ko. This is necessary to generate
> correct module's split BTF. Without it, Kbuild's module build logic might
> determine that nothing changed on the kernel side and thus bpf_testmod.ko
> shouldn't be rebuilt, so won't re-generate module BTF, which often leads to
> module's BTF with wrong string offsets against vmlinux BTF. Removing .ko file
> forces Kbuild to re-build the module.
>
> Reported-by: Alexei Starovoitov <ast@...nel.org>
> Fixes: 9f7fa225894c ("selftests/bpf: Add bpf_testmod kernel module for testing")
> Signed-off-by: Andrii Nakryiko <andrii@...nel.org>

Applied. Thanks

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ