opkg

statically linked package installer
git clone anongit@rnpnr.xyz:opkg.git
Log | Files | Refs | Feed | Submodules | README | LICENSE

0004-Make-struct-bpf_timer-include-a-named-member.patch (801B)


      1 From 3685e3c0cb5029b4e17eee6a53d2214190738c24 Mon Sep 17 00:00:00 2001
      2 From: Michael Forney <mforney@mforney.org>
      3 Date: Thu, 2 Dec 2021 14:49:08 -0800
      4 Subject: [PATCH] Make struct bpf_timer include a named member
      5 
      6 A struct without any named members is undefined behavior by C11
      7 6.7.2.1p8.
      8 
      9 Signed-off-by: Michael Forney <mforney@mforney.org>
     10 ---
     11  include/uapi/linux/bpf.h | 5 ++---
     12  1 file changed, 2 insertions(+), 3 deletions(-)
     13 
     14 diff --git a/include/uapi/linux/bpf.h b/include/uapi/linux/bpf.h
     15 index ed8261560f2b..fb60bc7bb305 100644
     16 --- a/include/uapi/linux/bpf.h
     17 +++ b/include/uapi/linux/bpf.h
     18 @@ -6968,9 +6968,8 @@ struct bpf_spin_lock {
     19  };
     20  
     21  struct bpf_timer {
     22 -	__u64 :64;
     23 -	__u64 :64;
     24 -} __attribute__((aligned(8)));
     25 +	__u64	reserved[2];
     26 +};
     27  
     28  struct bpf_dynptr {
     29  	__u64 :64;
     30 -- 
     31 2.37.3
     32