Re: [GIT PULL] Ceph fixes for 5.1-rc7

Linus Torvalds
2019-04-26T16:36:24Z

On Fri, Apr 26, 2019 at 9:25 AM Jeff Layton <jlayton@kernel.org> wrote:
>
> Is it really ok to union the count and rcu_head there?

It should be fine, because the rcu_count should only ever be used once
the count has gone to zero and the name cannot be found any more.

And while RCU path walking may find and use the *name* after the
dentry has been killed off (but not free'd yet), all the actual
external_name() accesses should be serialized by the dentry lock, so
there's no access to those fields once the dentry is dead.

At least that's how it's supposed to work. Al would be the final
arbiter on this.

Linus