Patch "samples: bpf: Don't fail for a missing VMLINUX_BTF when VMLINUX_H is provided" has been added to the 5.15-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    samples: bpf: Don't fail for a missing VMLINUX_BTF when VMLINUX_H is provided

to the 5.15-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     samples-bpf-don-t-fail-for-a-missing-vmlinux_btf-whe.patch
and it can be found in the queue-5.15 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 0889a0434077e1dd24103fca4774d249af3630d3
Author: Jerome Marchand <jmarchan@xxxxxxxxxx>
Date:   Sat May 7 18:16:35 2022 +0200

    samples: bpf: Don't fail for a missing VMLINUX_BTF when VMLINUX_H is provided
    
    [ Upstream commit ec24704492d8791a52a75a39e3ad762b6e017bc6 ]
    
    samples/bpf build currently always fails if it can't generate
    vmlinux.h from vmlinux, even when vmlinux.h is directly provided by
    VMLINUX_H variable, which makes VMLINUX_H pointless.
    Only fails when neither method works.
    
    Fixes: 384b6b3bbf0d ("samples: bpf: Add vmlinux.h generation support")
    Reported-by: CKI Project <cki-project@xxxxxxxxxx>
    Reported-by: Veronika Kabatova <vkabatov@xxxxxxxxxx>
    Signed-off-by: Jerome Marchand <jmarchan@xxxxxxxxxx>
    Signed-off-by: Andrii Nakryiko <andrii@xxxxxxxxxx>
    Link: https://lore.kernel.org/bpf/20220507161635.2219052-1-jmarchan@xxxxxxxxxx
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/samples/bpf/Makefile b/samples/bpf/Makefile
index c6e38e43c3fd..e2c9ea65df9f 100644
--- a/samples/bpf/Makefile
+++ b/samples/bpf/Makefile
@@ -365,16 +365,15 @@ VMLINUX_BTF ?= $(abspath $(firstword $(wildcard $(VMLINUX_BTF_PATHS))))
 
 $(obj)/vmlinux.h: $(VMLINUX_BTF) $(BPFTOOL)
 ifeq ($(VMLINUX_H),)
+ifeq ($(VMLINUX_BTF),)
+	$(error Cannot find a vmlinux for VMLINUX_BTF at any of "$(VMLINUX_BTF_PATHS)",\
+		build the kernel or set VMLINUX_BTF or VMLINUX_H variable)
+endif
 	$(Q)$(BPFTOOL) btf dump file $(VMLINUX_BTF) format c > $@
 else
 	$(Q)cp "$(VMLINUX_H)" $@
 endif
 
-ifeq ($(VMLINUX_BTF),)
-	$(error Cannot find a vmlinux for VMLINUX_BTF at any of "$(VMLINUX_BTF_PATHS)",\
-		build the kernel or set VMLINUX_BTF variable)
-endif
-
 clean-files += vmlinux.h
 
 # Get Clang's default includes on this system, as opposed to those seen by



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux