2019-06-26 10:40:18

by Yue Hu

[permalink] [raw]
Subject: [PATCH RESEND] staging: erofs: remove unsupported ->datamode check in fill_inline_data()

From: Yue Hu <[email protected]>

Already check if ->datamode is supported in read_inode(), no need to check
again in the next fill_inline_data() only called by fill_inode().

Signed-off-by: Yue Hu <[email protected]>
Reviewed-by: Gao Xiang <[email protected]>
Reviewed-by: Chao Yu <[email protected]>
---
drivers/staging/erofs/inode.c | 2 --
1 file changed, 2 deletions(-)

diff --git a/drivers/staging/erofs/inode.c b/drivers/staging/erofs/inode.c
index e51348f..d6e1e16 100644
--- a/drivers/staging/erofs/inode.c
+++ b/drivers/staging/erofs/inode.c
@@ -129,8 +129,6 @@ static int fill_inline_data(struct inode *inode, void *data,
struct erofs_sb_info *sbi = EROFS_I_SB(inode);
const int mode = vi->datamode;

- DBG_BUGON(mode >= EROFS_INODE_LAYOUT_MAX);
-
/* should be inode inline C */
if (mode != EROFS_INODE_LAYOUT_INLINE)
return 0;
--
1.9.1


2019-06-26 10:52:46

by Gao Xiang

[permalink] [raw]
Subject: Re: [PATCH RESEND] staging: erofs: remove unsupported ->datamode check in fill_inline_data()

Hi Yue,

On 2019/6/26 18:39, Yue Hu wrote:
> From: Yue Hu <[email protected]>
>
> Already check if ->datamode is supported in read_inode(), no need to check
> again in the next fill_inline_data() only called by fill_inode().
>
> Signed-off-by: Yue Hu <[email protected]>
> Reviewed-by: Gao Xiang <[email protected]>
> Reviewed-by: Chao Yu <[email protected]>

Bump the patch version in the title as Greg said...
Otherwise, it is hard to differ which patch is the latest patch...

Thanks,
Gao Xiang

> ---
> drivers/staging/erofs/inode.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/staging/erofs/inode.c b/drivers/staging/erofs/inode.c
> index e51348f..d6e1e16 100644
> --- a/drivers/staging/erofs/inode.c
> +++ b/drivers/staging/erofs/inode.c
> @@ -129,8 +129,6 @@ static int fill_inline_data(struct inode *inode, void *data,
> struct erofs_sb_info *sbi = EROFS_I_SB(inode);
> const int mode = vi->datamode;
>
> - DBG_BUGON(mode >= EROFS_INODE_LAYOUT_MAX);
> -
> /* should be inode inline C */
> if (mode != EROFS_INODE_LAYOUT_INLINE)
> return 0;
>