Re: [PATCH v3 bpf-next 1/5] bpf: Rename __kptr_ref -> __kptr and __kptr -> __kptr_untrusted.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Feb 27, 2023 at 08:01:17PM -0800, Alexei Starovoitov wrote:
> From: Alexei Starovoitov <ast@xxxxxxxxxx>
> 
> __kptr meant to store PTR_UNTRUSTED kernel pointers inside bpf maps.
> The concept felt useful, but didn't get much traction,
> since bpf_rdonly_cast() was added soon after and bpf programs received
> a simpler way to access PTR_UNTRUSTED kernel pointers
> without going through restrictive __kptr usage.
> 
> Rename __kptr_ref -> __kptr and __kptr -> __kptr_untrusted to indicate
> its intended usage.
> The main goal of __kptr_untrusted was to read/write such pointers
> directly while bpf_kptr_xchg was a mechanism to access refcnted
> kernel pointers. The next patch will allow RCU protected __kptr access
> with direct read. At that point __kptr_untrusted will be deprecated.
> 
> Signed-off-by: Alexei Starovoitov <ast@xxxxxxxxxx>

Acked-by: David Vernet <void@xxxxxxxxxxxxx>



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux