Skip to content

Commit

Permalink
update(cmake,driver): bumped libbpf to latest release (1.2.2).
Browse files Browse the repository at this point in the history
Cleaned up some now useless lines in `modern_bpf/helpers/base/common.h`.

Signed-off-by: Federico Di Pierro <nierro92@gmail.com>
  • Loading branch information
FedeDP committed Jul 13, 2023
1 parent 121d918 commit 76c956a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
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

#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

0 comments on commit 76c956a

Please sign in to comment.