<div dir="ltr">Hello, thanks for the fast reply. <div><br><i>>NACK, all linux filesystems use Opt_xxx. EROFS should obey this practice.<br></i>I wasn't aware of that convention, my apologies.</div><div><br>Should I fix that, keep the other changes and resend as v2, or <br>are you not interested in style patches? I'm interested in contributing to this<br>driver, but as I get familiar with it I was planning on making it pass<br>checkpatch as much as possible.<br><br>Thanks,<br>Karen Palacio.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">El mar., 16 jul. 2019 a las 14:03, Gao Xiang (<<a href="mailto:hsiangkao@aol.com">hsiangkao@aol.com</a>>) escribió:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
<br>
On 2019/7/17 ????12:35, Karen Palacio wrote:<br>
> Fix camel case use in variable names,<br>
> Fix multiple assignments done in a single line,<br>
> Fix end of line containing '('.<br>
<br>
One type one patch...<br>
<br>
> <br>
> Signed-off-by: Karen Palacio <<a href="mailto:karen.palacio.1994@gmail.com" target="_blank">karen.palacio.1994@gmail.com</a>><br>
> ---<br>
> drivers/staging/erofs/super.c | 55 ++++++++++++++++++++++---------------------<br>
> 1 file changed, 28 insertions(+), 27 deletions(-)<br>
> <br>
> diff --git a/drivers/staging/erofs/super.c b/drivers/staging/erofs/super.c<br>
> index 5449441..e281125 100644<br>
> --- a/drivers/staging/erofs/super.c<br>
> +++ b/drivers/staging/erofs/super.c<br>
> @@ -228,21 +228,21 @@ static void default_options(struct erofs_sb_info *sbi)<br>
> }<br>
> <br>
> enum {<br>
> - Opt_user_xattr,<br>
> - Opt_nouser_xattr,<br>
> - Opt_acl,<br>
> - Opt_noacl,<br>
> - Opt_fault_injection,<br>
> - Opt_err<br>
> + opt_user_xattr,<br>
> + opt_nouser_xattr,<br>
> + opt_acl,<br>
> + opt_noacl,<br>
> + opt_fault_injection,<br>
> + opt_err<br>
<br>
NACK, all linux filesystems use Opt_xxx. EROFS should obey this practice.<br>
<br>
fs/ext4/super.c<br>
1436 enum {<br>
1437 Opt_bsd_df, Opt_minix_df, Opt_grpid, Opt_nogrpid,<br>
1438 Opt_resgid, Opt_resuid, Opt_sb, Opt_err_cont,<br>
Opt_err_panic, Opt_err_ro,<br>
1439 Opt_nouid32, Opt_debug, Opt_removed,<br>
1440 Opt_user_xattr, Opt_nouser_xattr, Opt_acl, Opt_noacl,<br>
1441 Opt_auto_da_alloc, Opt_noauto_da_alloc, Opt_noload,<br>
1442 Opt_commit, Opt_min_batch_time, Opt_max_batch_time,<br>
Opt_journal_dev,<br>
1443 Opt_journal_path, Opt_journal_checksum,<br>
Opt_journal_async_commit,<br>
1444 Opt_abort, Opt_data_journal, Opt_data_ordered,<br>
Opt_data_writeback,<br>
1445 Opt_data_err_abort, Opt_data_err_ignore,<br>
Opt_test_dummy_encryption,<br>
1446 Opt_usrjquota, Opt_grpjquota, Opt_offusrjquota,<br>
Opt_offgrpjquota,<br>
1447 Opt_jqfmt_vfsold, Opt_jqfmt_vfsv0, Opt_jqfmt_vfsv1, Opt_quota,<br>
<br>
fs/btrfs/super.c<br>
294 enum {<br>
295 Opt_acl, Opt_noacl,<br>
296 Opt_clear_cache,<br>
297 Opt_commit_interval,<br>
298 Opt_compress,<br>
299 Opt_compress_force,<br>
300 Opt_compress_force_type,<br>
301 Opt_compress_type,<br>
302 Opt_degraded,<br>
303 Opt_device,<br>
304 Opt_fatal_errors,<br>
<br>
Thanks,<br>
Gao Xiang<br>
<br>
<br>
> };<br>
> <br>
> static match_table_t erofs_tokens = {<br>
> - {Opt_user_xattr, "user_xattr"},<br>
> - {Opt_nouser_xattr, "nouser_xattr"},<br>
> - {Opt_acl, "acl"},<br>
> - {Opt_noacl, "noacl"},<br>
> - {Opt_fault_injection, "fault_injection=%u"},<br>
> - {Opt_err, NULL}<br>
> + {opt_user_xattr, "user_xattr"},<br>
> + {opt_nouser_xattr, "nouser_xattr"},<br>
> + {opt_acl, "acl"},<br>
> + {opt_noacl, "noacl"},<br>
> + {opt_fault_injection, "fault_injection=%u"},<br>
> + {opt_err, NULL}<br>
> };<br>
> <br>
> static int parse_options(struct super_block *sb, char *options)<br>
> @@ -260,41 +260,42 @@ static int parse_options(struct super_block *sb, char *options)<br>
> if (!*p)<br>
> continue;<br>
> <br>
> - args[0].to = args[0].from = NULL;<br>
> + args[0].to = NULL;<br>
> + args[0].from = NULL;<br>
> token = match_token(p, erofs_tokens, args);<br>
> <br>
> switch (token) {<br>
> #ifdef CONFIG_EROFS_FS_XATTR<br>
> - case Opt_user_xattr:<br>
> + case opt_user_xattr:<br>
> set_opt(EROFS_SB(sb), XATTR_USER);<br>
> break;<br>
> - case Opt_nouser_xattr:<br>
> + case opt_nouser_xattr:<br>
> clear_opt(EROFS_SB(sb), XATTR_USER);<br>
> break;<br>
> #else<br>
> - case Opt_user_xattr:<br>
> + case opt_user_xattr:<br>
> infoln("user_xattr options not supported");<br>
> break;<br>
> - case Opt_nouser_xattr:<br>
> + case opt_nouser_xattr:<br>
> infoln("nouser_xattr options not supported");<br>
> break;<br>
> #endif<br>
> #ifdef CONFIG_EROFS_FS_POSIX_ACL<br>
> - case Opt_acl:<br>
> + case opt_acl:<br>
> set_opt(EROFS_SB(sb), POSIX_ACL);<br>
> break;<br>
> - case Opt_noacl:<br>
> + case opt_noacl:<br>
> clear_opt(EROFS_SB(sb), POSIX_ACL);<br>
> break;<br>
> #else<br>
> - case Opt_acl:<br>
> + case opt_acl:<br>
> infoln("acl options not supported");<br>
> break;<br>
> - case Opt_noacl:<br>
> + case opt_noacl:<br>
> infoln("noacl options not supported");<br>
> break;<br>
> #endif<br>
> - case Opt_fault_injection:<br>
> + case opt_fault_injection:<br>
> err = erofs_build_fault_attr(EROFS_SB(sb), args);<br>
> if (err)<br>
> return err;<br>
> @@ -525,7 +526,6 @@ static void erofs_put_super(struct super_block *sb)<br>
> sb->s_fs_info = NULL;<br>
> }<br>
> <br>
> -<br>
> struct erofs_mount_private {<br>
> const char *dev_name;<br>
> char *options;<br>
> @@ -541,9 +541,9 @@ static int erofs_fill_super(struct super_block *sb,<br>
> priv->options, silent);<br>
> }<br>
> <br>
> -static struct dentry *erofs_mount(<br>
> - struct file_system_type *fs_type, int flags,<br>
> - const char *dev_name, void *data)<br>
> +static struct dentry *erofs_mount(struct file_system_type *fs_type,<br>
> + int flags,<br>
> + const char *dev_name, void *data)<br>
> {<br>
> struct erofs_mount_private priv = {<br>
> .dev_name = dev_name,<br>
> @@ -623,7 +623,8 @@ static int erofs_statfs(struct dentry *dentry, struct kstatfs *buf)<br>
> buf->f_type = sb->s_magic;<br>
> buf->f_bsize = EROFS_BLKSIZ;<br>
> buf->f_blocks = sbi->blocks;<br>
> - buf->f_bfree = buf->f_bavail = 0;<br>
> + buf->f_bfree = 0;<br>
> + buf->f_bavail = 0;<br>
> <br>
> buf->f_files = ULLONG_MAX;<br>
> buf->f_ffree = ULLONG_MAX - sbi->inos;<br>
> <br>
</blockquote></div>