From 713494609e7314a0cb9bf1c54cb0a5955793c2ee Mon Sep 17 00:00:00 2001 From: Alessandro Decina Date: Wed, 24 Feb 2021 03:15:56 +0000 Subject: [PATCH] aya-bpf-bindings: remove unused code --- bpf/aya-bpf-bindings/src/aarch64/mod.rs | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/bpf/aya-bpf-bindings/src/aarch64/mod.rs b/bpf/aya-bpf-bindings/src/aarch64/mod.rs index 0f1a2630..bd6ebbcb 100644 --- a/bpf/aya-bpf-bindings/src/aarch64/mod.rs +++ b/bpf/aya-bpf-bindings/src/aarch64/mod.rs @@ -1,21 +1,3 @@ pub mod bindings; pub mod getters; pub mod helpers; - -use aya_bpf_cty::{c_long, c_void}; -use core::mem::{self, MaybeUninit}; - -#[inline] -unsafe fn bpf_probe_read(src: *const T) -> Result { - let mut v: MaybeUninit = MaybeUninit::uninit(); - let ret = helpers::bpf_probe_read( - v.as_mut_ptr() as *mut c_void, - mem::size_of::() as u32, - src as *const c_void, - ); - if ret < 0 { - return Err(ret); - } - - Ok(v.assume_init()) -}