Re: [PATCH bpf v2 06/11] bpf: verify callbacks as if they are called unknown number of times

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

 



On Fri, Nov 17, 2023 at 5:34 PM Eduard Zingerman <eddyz87@xxxxxxxxx> wrote:
>
> - as calls to bpf_*_iter_next(), calls to callback invoking functions
>   are marked as checkpoints;
...
> +static void mark_callback_iter_next(struct bpf_verifier_env *env, int idx)
> +{
> +       env->insn_aux_data[idx].callback_iter = true;
> +}
> +
> +static bool is_callback_iter_next(struct bpf_verifier_env *env, int insn_idx)
> +{
> +       return env->insn_aux_data[insn_idx].callback_iter;
> +}

I think you're trying to make it similar to is_iter_next_kfunc(),
but in this context the _iter_next is confusing. Especially _next suffix.
Maybe
s/bool callback_iter/bool calls_callback/ ?
s/is_callback_iter_next/calls_callback/ ?
s/mark_callback_iter_next/mark_calls_callback/ ?

callback_iter_depth isn't quite accurate either.
Maybe callback_nest_level ?





[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