Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update(cmake,driver): bumped libbpf to latest release (1.2.2). #1197

Merged
merged 1 commit into from
Jul 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions cmake/modules/libbpf.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ else()
libbpf
PREFIX "${PROJECT_BINARY_DIR}/libbpf-prefix"
DEPENDS zlib libelf
URL "https://github.com/libbpf/libbpf/archive/refs/tags/v1.0.1.tar.gz"
URL "https://github.com/libbpf/libbpf/archive/refs/tags/v1.2.2.tar.gz"
URL_HASH
"SHA256=3d6afde67682c909e341bf194678a8969f17628705af25f900d5f68bd299cb03"
"SHA256=32b0c41eabfbbe8e0c8aea784d7495387ff9171b5a338480a8fbaceb9da8d5e5"
CONFIGURE_COMMAND mkdir -p build root
BUILD_COMMAND ${CMAKE_MAKE_PROGRAM} BUILD_STATIC_ONLY=y OBJDIR=${LIBBPF_BUILD_DIR}/build DESTDIR=${LIBBPF_BUILD_DIR}/root NO_PKG_CONFIG=1 "EXTRA_CFLAGS=-I${LIBELF_INCLUDE} -I${ZLIB_INCLUDE}" "LDFLAGS=-Wl,-Bstatic" "EXTRA_LDFLAGS=-L${LIBELF_SRC}/libelf/libelf -L${ZLIB_SRC}" -C ${LIBBPF_SRC}/libbpf/src install install_uapi_headers
INSTALL_COMMAND ""
Expand Down
4 changes: 4 additions & 0 deletions driver/modern_bpf/helpers/base/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
* to the others `PT_REGS_PARAM...`
*/

#ifndef PT_REGS_PARM6_CORE_SYSCALL
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep them when building with system libbpf that is < 1.2.0 thus does not contain the change.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is the case in some of our CI jobs.


#if defined(bpf_target_x86)
#define __PT_PARM6_REG r9
#elif defined(bpf_target_arm64)
Expand All @@ -32,6 +34,8 @@
#define PT_REGS_PARM6_CORE(x) BPF_CORE_READ(__PT_REGS_CAST(x), __PT_PARM6_REG)
#define PT_REGS_PARM6_CORE_SYSCALL(x) PT_REGS_PARM6_CORE(x)

#endif

/*=============================== LIBBPF MISSING TRACING DEFINITION ===========================*/

/*=============================== DEBUG MACRO ===========================*/
Expand Down
Loading