[PATCH 4/7] staging: erofs: return -EINVAL when specifying fault rate to 0

Dan Carpenter dan.carpenter at oracle.com
Thu Sep 13 00:25:31 AEST 2018


On Wed, Sep 12, 2018 at 10:05:26PM +0800, cgxu519 wrote:
> On 09/12/2018 05:16 PM, Dan Carpenter wrote:
> > On Wed, Sep 12, 2018 at 01:10:31PM +0800, Chengguang Xu wrote:
> > > Set fault rate to 0 is useless and confusable, so add check to
> > > avoid it.
> > > 
> > I would have assumed setting rate to zero just disabled it.
> 
> I think currently it is useless because we have not implemented
> option parsing in remount yet, maybe it's better adding another
> option 'no_fault_injection' to explicitly disable it.

That's like the AC on my car, where I can't turn the fan from one to
zero, I have to press disable.  I don't like the explicit disable, I
wish they would just remove that button.

But I also don't think most people will ever use the fault injection
interface so it doesn't really matter.  Do whatever seems good to you.

regards,
dan carpenter



More information about the Linux-erofs mailing list