Re: [PATCH 09/17] file: Implement fnext_task

From: Alexei Starovoitov
Date: Wed Aug 19 2020 - 11:55:08 EST


On Wed, Aug 19, 2020 at 6:25 AM Eric W. Biederman <ebiederm@xxxxxxxxxxxx> wrote:
>
> The bug in the existing code is that bpf_iter does get_file instead
> of get_file_rcu. Does anyone have any sense of how to add debugging
> to get_file to notice when it is being called in the wrong context?

That bug is already fixed in bpf tree.
See commit cf28f3bbfca0 ("bpf: Use get_file_rcu() instead of
get_file() for task_file iterator")