[PATCH 4/5] erofs-utils: remove unnecessary codes and comments

Gao Xiang hsiangkao at linux.alibaba.com
Fri Sep 3 13:17:29 AEST 2021


On Wed, Sep 01, 2021 at 12:51:15AM +0800, Huang Jianan wrote:
> From: Huang Jianan <huangjianan at oppo.com>
> 
> Signed-off-by: Huang Jianan <huangjianan at oppo.com>
> ---
>  lib/inode.c | 4 ----
>  lib/zmap.c  | 1 -
>  2 files changed, 5 deletions(-)
> 
> diff --git a/lib/inode.c b/lib/inode.c
> index 62047d3..f001016 100644
> --- a/lib/inode.c
> +++ b/lib/inode.c
> @@ -677,11 +677,7 @@ out:
>  		 * Don't leave DATA buffers which were written in the global
>  		 * buffer list. It will make balloc() slowly.
>  		 */
> -#if 0
> -		bh->op = &erofs_drop_directly_bhops;
> -#else
>  		erofs_bdrop(bh, false);
> -#endif
>  		inode->bh_data = NULL;
>  	}
>  	return 0;
> diff --git a/lib/zmap.c b/lib/zmap.c
> index fdc84af..88da515 100644
> --- a/lib/zmap.c
> +++ b/lib/zmap.c
> @@ -423,7 +423,6 @@ static int z_erofs_get_extent_compressedlen(struct z_erofs_maprecorder *m,
>  			goto err_bonus_cblkcnt;
>  		if (m->compressedlcs)
>  			break;
> -		/* fallthrough */

I don't think this should be removed. On the kernel side, we use
"fallthrough;" instead.

Could we add all the missing "/* fallthrough */"?

Thanks,
Gao Xiang

>  	default:
>  		erofs_err("cannot found CBLKCNT @ lcn %lu of nid %llu",
>  			  lcn, vi->nid | 0ULL);
> -- 
> 2.25.1


More information about the Linux-erofs mailing list