On Wed, Jan 06, 2021 at 03:25:30PM -0800, Andrii Nakryiko wrote:
> >
> > If I am not mistaken (which is completely possible), I think that
> > providing such a macro will
> > not cause any more confusion than the bpf_probe_read_{,user}
> > distinction already does,
> > since BPF_CORE_READ_USER to BPF_CORE_READ is the same as bpf_probe_read_user
> > to bpf_probe_read.
> 
> I think the biggest source of confusion is that USER part in
> BPF_CORE_READ_USER refers to reading data from user address space, not
> really user structs (which is kind of natural instinct here). CO-RE
> *always* works only with kernel types, which is obvious if you have a
> lot of experience with using CO-RE, but not initially, unfortunately.

Please send a patch to add such clarifying comment.

Reply via email to