introduce ->iterate(), ctx->pos, dir_emit()
authorAl Viro <viro@zeniv.linux.org.uk>
Sun, 14 May 2017 09:17:29 +0000 (09:17 +0000)
committerStricted <info@stricted.net>
Thu, 3 May 2018 16:37:22 +0000 (18:37 +0200)
commit0f63c0e88f76878a55b375f81e8b326a21dee2ef
tree337c6b026b46c1b0e370cd1d0c8929dc2ad97097
parent0f8376923b3d81d30f2fece378f879d65945fec8
introduce ->iterate(), ctx->pos, dir_emit()

New method - ->iterate(file, ctx).  That's the replacement for ->readdir();
it takes callback from ctx->actor, uses ctx->pos instead of file->f_pos and
calls dir_emit(ctx, ...) instead of filldir(data, ...).  It does *not*
update file->f_pos (or look at it, for that matter); iterate_dir() does the
update.

Note that dir_emit() takes the offset from ctx->pos (and eventually
filldir_t will lose that argument).

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
arch/parisc/hpux/fs.c
fs/coda/dir.c
fs/compat.c
fs/exportfs/expfs.c
fs/nfsd/nfs4recover.c
fs/readdir.c
include/linux/fs.h