Re: [PATCH 05/12] mkfs: extend opt_params with a value field

Luis R. Rodriguez
2017-04-26T01:04:59Z

On Tue, Apr 25, 2017 at 11:39:00AM +0200, Jan Tulak wrote:
> And rather than submitting repeatedly new versions of the whole
> patch... how about this?
>
> *
> * value OPTIONAL
> * The actual value used in computations and for creating the filesystem.
> * It is filled with user input and anything you write here now is

I think its easier to read if you are clear from the start user input is
optional, and so a default value is used first, and use input overrides
these initial system defaults.

> * overwritten if the user specifies the subopt. But he does not,
> then whatever

"But he does not", I guess you meant, "But if he does not"...

> * you put there is used as the default. Can be omitted if the default
> * is 0.

Hm, how about:

The actual value used in computations for creating the filesystem.
This is initialized with sensible default values, if initialized to 0
the value is considered disabled. User input can optionally override
default values. If the field is a string and not a number, the value
is set to a positive non-zero number when user input has been supplied.

> * (If the field is a string and not a number, this value is set to
> * a positive non-zero number on an user input.)
>
> And for the commit message, a bit shortened version:
>
> Add a new field int opt_params - value - which is the actual value
> used in computations and for creating the filesystem. It is filled
> with user input if the user specifies the subopt. But he does not,
> then whatever you put there is used as the default.

Modulo "But he does not"/ "but if no user input is not passed then
the originally set defaults will be used"

Luis