On Sun, Mar 7, 2021 at 7:18 PM Yonghong Song <yhs@xxxxxx> wrote: > > > > On 3/7/21 4:09 AM, Tal Lossos wrote: > > bpf_fd_inode_storage_lookup_elem returned NULL when getting a bad FD, > > which caused -ENOENT in bpf_map_copy_value. > > EBADF is better than ENOENT for a bad FD behaviour. > > > > The patch was partially contributed by CyberArk Software, Inc. > > > > Signed-off-by: Tal Lossos <tallossos@xxxxxxxxx> > > Acked-by: Yonghong Song <yhs@xxxxxx> Thanks this makes sense and is consistent with sk_storage (which uses sockfd_lookup) and task_storage (which uses pidfd_get_pid) which return an -EBADF as well. Acked-by: KP Singh <kpsingh@xxxxxxxxxx>