[PATCH-next] afs: Remove logically dead code
David Howells
dhowells at redhat.com
Mon Nov 18 07:18:19 PST 2024
Advait Dhamorikar <advaitdhamorikar at gmail.com> wrote:
> iterate_folioq(&iter, iov_iter_count(&iter), dvnode, ctx,
> afs_dir_iterate_step);
>
> - if (ret == -ESTALE)
> - afs_invalidate_dir(dvnode, afs_dir_invalid_iter_stale);
> return ret;
Removing this is the wrong thing to do. However, you're correct that ret is
never set to -ESTALE.
A better solution, I think, is to check the result of iterate_folioq(),
invalidating the dir and returning -ESTALE if 0 and if the iterator count is
not 0.
David
More information about the linux-afs
mailing list