[Cbe-oss-dev] [patch 1/1] spufs: fix error handling in spufs_fill_dir()
Arnd Bergmann
arnd at arndb.de
Tue Jun 5 21:36:22 EST 2007
On Tuesday 05 June 2007, Sebastian Siewior wrote:
> +static void spufs_prune_incomplete_dir(struct dentry *dir)
> +{
> + struct dentry *child, *tmp;
> +
> + list_for_each_entry_safe(child, tmp, &dir->d_subdirs, d_u.d_child) {
> + dput(child);
> + }
> +
> + shrink_dcache_parent(dir);
> +}
> +
> static int spufs_fill_dir(struct dentry *dir, struct tree_descr *files,
> int mode, struct spu_context *ctx)
> {
> @@ -193,7 +213,7 @@ static int spufs_fill_dir(struct dentry
> }
> return 0;
> out:
> - spufs_prune_dir(dir);
> + spufs_prune_incomplete_dir(dir);
> return ret;
I think it would clearer to do the loop in place, instead of the function call.
The patch looks good otherwise.
Arnd <><
More information about the cbe-oss-dev
mailing list