> Thanks for the suggestions, I will experiment with a read-write lock,
> meanwhile,
> adding the documentation and testing for the lockless scheme.
Read-write locks are usually not worth it for short critical sections,
in fact they can be slower due to cache line effects.
> Sorry, I may not pro
> Sorry, I know nothing about the ThreadSanitizer and related annotation,
> could you provide some information about it, thanks.
Documentation/dev-tools/kcsan.rst
> > Would be good to have some commentary why doing so
> > many write operations with merely a rcu_read_lock as protection is safe.
>
Liao Chang writes:
> +
> +/*
> + * xol_recycle_insn_slot - recycle a slot from the garbage collection list.
> + */
> +static int xol_recycle_insn_slot(struct xol_area *area)
> +{
> + struct uprobe_task *utask;
> + int slot = UINSNS_PER_PAGE;
> +
> + rcu_read_lock();
> + list_for_ea