On 01.12.2020 09:21, Juergen Gross wrote: > Add a getsize() function pointer to struct hypfs_funcs for being able > to have dynamically filled entries without the need to take the hypfs > lock each time the contents are being generated. > > For directories add a findentry callback to the vector and modify > hypfs_get_entry_rel() to use it. > > Signed-off-by: Juergen Gross <jgr...@suse.com>
Reviewed-by: Jan Beulich <jbeul...@suse.com> with maybe one further small adjustment: > @@ -176,15 +188,41 @@ static int hypfs_get_path_user(char *buf, > return 0; > } > > +struct hypfs_entry *hypfs_leaf_findentry(const struct hypfs_entry_dir *dir, > + const char *name, > + unsigned int name_len) > +{ > + return ERR_PTR(-ENOENT); > +} ENOENT seems odd to me here. There looks to be no counterpart to EISDIR, so maybe ENODATA, EACCES, or EPERM? Jan