diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2025-07-30 19:58:50 +0300 | 
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2025-07-30 19:58:50 +0300 | 
| commit | d9104cec3e8fe4b458b74709853231385779001f (patch) | |
| tree | 1ffc3baa0e963d3301765a5d6cbd5410c8796ee4 /drivers/net/netkit.c | |
| parent | 8be4d31cb8aaeea27bde4b7ddb26e28a89062ebf (diff) | |
| parent | cd7c97f4584a93578f87ea6ff427f74e9a943cdf (diff) | |
| download | linux-d9104cec3e8fe4b458b74709853231385779001f.tar.xz | |
Merge tag 'bpf-next-6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next
Pull bpf updates from Alexei Starovoitov:
 - Remove usermode driver (UMD) framework (Thomas Weißschuh)
 - Introduce Strongly Connected Component (SCC) in the verifier to
   detect loops and refine register liveness (Eduard Zingerman)
 - Allow 'void *' cast using bpf_rdonly_cast() and corresponding
   '__arg_untrusted' for global function parameters (Eduard Zingerman)
 - Improve precision for BPF_ADD and BPF_SUB operations in the verifier
   (Harishankar Vishwanathan)
 - Teach the verifier that constant pointer to a map cannot be NULL
   (Ihor Solodrai)
 - Introduce BPF streams for error reporting of various conditions
   detected by BPF runtime (Kumar Kartikeya Dwivedi)
 - Teach the verifier to insert runtime speculation barrier (lfence on
   x86) to mitigate speculative execution instead of rejecting the
   programs (Luis Gerhorst)
 - Various improvements for 'veristat' (Mykyta Yatsenko)
 - For CONFIG_DEBUG_KERNEL config warn on internal verifier errors to
   improve bug detection by syzbot (Paul Chaignon)
 - Support BPF private stack on arm64 (Puranjay Mohan)
 - Introduce bpf_cgroup_read_xattr() kfunc to read xattr of cgroup's
   node (Song Liu)
 - Introduce kfuncs for read-only string opreations (Viktor Malik)
 - Implement show_fdinfo() for bpf_links (Tao Chen)
 - Reduce verifier's stack consumption (Yonghong Song)
 - Implement mprog API for cgroup-bpf programs (Yonghong Song)
* tag 'bpf-next-6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (192 commits)
  selftests/bpf: Migrate fexit_noreturns case into tracing_failure test suite
  selftests/bpf: Add selftest for attaching tracing programs to functions in deny list
  bpf: Add log for attaching tracing programs to functions in deny list
  bpf: Show precise rejected function when attaching fexit/fmod_ret to __noreturn functions
  bpf: Fix various typos in verifier.c comments
  bpf: Add third round of bounds deduction
  selftests/bpf: Test invariants on JSLT crossing sign
  selftests/bpf: Test cross-sign 64bits range refinement
  selftests/bpf: Update reg_bound range refinement logic
  bpf: Improve bounds when s64 crosses sign boundary
  bpf: Simplify bounds refinement from s32
  selftests/bpf: Enable private stack tests for arm64
  bpf, arm64: JIT support for private stack
  bpf: Move bpf_jit_get_prog_name() to core.c
  bpf, arm64: Fix fp initialization for exception boundary
  umd: Remove usermode driver framework
  bpf/preload: Don't select USERMODE_DRIVER
  selftests/bpf: Fix test dynptr/test_dynptr_memset_xdp_chunks failure
  selftests/bpf: Fix test dynptr/test_dynptr_copy_xdp failure
  selftests/bpf: Increase xdp data size for arm64 64K page size
  ...
Diffstat (limited to 'drivers/net/netkit.c')
| -rw-r--r-- | drivers/net/netkit.c | 10 | 
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/net/netkit.c b/drivers/net/netkit.c index d072a7968f56..492be60f2e70 100644 --- a/drivers/net/netkit.c +++ b/drivers/net/netkit.c @@ -32,7 +32,6 @@ struct netkit {  struct netkit_link {  	struct bpf_link link;  	struct net_device *dev; -	u32 location;  };  static __always_inline int @@ -733,8 +732,8 @@ static void netkit_link_fdinfo(const struct bpf_link *link, struct seq_file *seq  	seq_printf(seq, "ifindex:\t%u\n", ifindex);  	seq_printf(seq, "attach_type:\t%u (%s)\n", -		   nkl->location, -		   nkl->location == BPF_NETKIT_PRIMARY ? "primary" : "peer"); +		   link->attach_type, +		   link->attach_type == BPF_NETKIT_PRIMARY ? "primary" : "peer");  }  static int netkit_link_fill_info(const struct bpf_link *link, @@ -749,7 +748,7 @@ static int netkit_link_fill_info(const struct bpf_link *link,  	rtnl_unlock();  	info->netkit.ifindex = ifindex; -	info->netkit.attach_type = nkl->location; +	info->netkit.attach_type = link->attach_type;  	return 0;  } @@ -775,8 +774,7 @@ static int netkit_link_init(struct netkit_link *nkl,  			    struct bpf_prog *prog)  {  	bpf_link_init(&nkl->link, BPF_LINK_TYPE_NETKIT, -		      &netkit_link_lops, prog); -	nkl->location = attr->link_create.attach_type; +		      &netkit_link_lops, prog, attr->link_create.attach_type);  	nkl->dev = dev;  	return bpf_link_prime(&nkl->link, link_primer);  }  | 
