[PATCH] staging: erofs: using switch-case while checking the inode type.

Gao Xiang hsiangkao at aol.com
Fri Aug 30 04:57:10 AEST 2019


Hi Dan,

On Thu, Aug 29, 2019 at 11:13:53PM +0800, Gao Xiang wrote:
> Hi Dan,
> 
> On Thu, Aug 29, 2019 at 06:04:36PM +0300, Dan Carpenter wrote:
> > On Thu, Aug 29, 2019 at 10:15:22PM +0800, Gao Xiang wrote:
> > > I am very happy that you send a patch about this, but we have
> > > to take care of handling "fall through" properly at least,
> > > and I don't want to introduce some extra compile warnings
> > > instead at this time.
> > 
> > I can't apply the patch so I maybe missed something.  I don't see
> > a fall through issue.  We have the code so you could use ^^^^^^^^ to
> > indicate which lines have a fall through problem.
> > 
> > > 
> > > EROFS is sensitive for now and I have no idea what the "real"
> > > point is.
> > 
> > What does "sensitive" mean here?  Now that it's out of staging we
> > aren't applying clean up patches?

Again, due to language obstacle, I have to give a detailed explanation
of what "sensitive" meant here.

I meant it seems all topic had no relationship with EROFS at all, but
someone mentioned erofs in different topics, I have no idea what is
wrong with EROFS, and I have no idea where it is like POS.

As your unlikely/likely concern, I think I discussed with you earlier,
in fact, most of EROFS unlikely is due to error handling paths, which are
meaningful in my thought.

If you argue that it has little performance difference, I think unlikely
in IS_ERR can also be killed as well since for most use cases in Linux
it is true that they are little performance difference at all. But I
think totally it will have some impact.

Anyway, I didn't find some formal standard about this, and I remove all
of these as you like.

Thanks,
Gao Xiang

> 
> Of course not, I mean we should avoid "fall through" problem
> but I have no time to verify this patch since I am fixing what
> hch said as well.
> 
> Thanks,
> Gao Xiang
> 
> > 
> > regards,
> > dan carpenter
> > 


More information about the Linux-erofs mailing list