* [PATCH 1/1 linux-next] fs/hfsplus/options.c: use standard option prefix
@ 2015-06-05 19:40 Fabian Frederick
2015-06-06 13:31 ` Richard Weinberger
0 siblings, 1 reply; 4+ messages in thread
From: Fabian Frederick @ 2015-06-05 19:40 UTC (permalink / raw)
To: linux-kernel; +Cc: Andrew Morton, Fabian Frederick, linux-fsdevel
All filesystems use Opt_ prefix for match_table_t enums
Signed-off-by: Fabian Frederick <fabf@skynet.be>
---
fs/hfsplus/options.c | 68 ++++++++++++++++++++++++++--------------------------
1 file changed, 34 insertions(+), 34 deletions(-)
diff --git a/fs/hfsplus/options.c b/fs/hfsplus/options.c
index c90b72e..d295ae6 100644
--- a/fs/hfsplus/options.c
+++ b/fs/hfsplus/options.c
@@ -19,29 +19,29 @@
#include "hfsplus_fs.h"
enum {
- opt_creator, opt_type,
- opt_umask, opt_uid, opt_gid,
- opt_part, opt_session, opt_nls,
- opt_nodecompose, opt_decompose,
- opt_barrier, opt_nobarrier,
- opt_force, opt_err
+ Opt_creator, Opt_type,
+ Opt_umask, Opt_uid, Opt_gid,
+ Opt_part, Opt_session, Opt_nls,
+ Opt_nodecompose, Opt_decompose,
+ Opt_barrier, Opt_nobarrier,
+ Opt_force, Opt_err
};
static const match_table_t tokens = {
- { opt_creator, "creator=%s" },
- { opt_type, "type=%s" },
- { opt_umask, "umask=%o" },
- { opt_uid, "uid=%u" },
- { opt_gid, "gid=%u" },
- { opt_part, "part=%u" },
- { opt_session, "session=%u" },
- { opt_nls, "nls=%s" },
- { opt_decompose, "decompose" },
- { opt_nodecompose, "nodecompose" },
- { opt_barrier, "barrier" },
- { opt_nobarrier, "nobarrier" },
- { opt_force, "force" },
- { opt_err, NULL }
+ { Opt_creator, "creator=%s" },
+ { Opt_type, "type=%s" },
+ { Opt_umask, "umask=%o" },
+ { Opt_uid, "uid=%u" },
+ { Opt_gid, "gid=%u" },
+ { Opt_part, "part=%u" },
+ { Opt_session, "session=%u" },
+ { Opt_nls, "nls=%s" },
+ { Opt_decompose, "decompose" },
+ { Opt_nodecompose, "nodecompose" },
+ { Opt_barrier, "barrier" },
+ { Opt_nobarrier, "nobarrier" },
+ { Opt_force, "force" },
+ { Opt_err, NULL }
};
/* Initialize an options object to reasonable defaults */
@@ -83,7 +83,7 @@ int hfsplus_parse_options_remount(char *input, int *force)
token = match_token(p, tokens, args);
switch (token) {
- case opt_force:
+ case Opt_force:
*force = 1;
break;
default:
@@ -111,26 +111,26 @@ int hfsplus_parse_options(char *input, struct hfsplus_sb_info *sbi)
token = match_token(p, tokens, args);
switch (token) {
- case opt_creator:
+ case Opt_creator:
if (match_fourchar(&args[0], &sbi->creator)) {
pr_err("creator requires a 4 character value\n");
return 0;
}
break;
- case opt_type:
+ case Opt_type:
if (match_fourchar(&args[0], &sbi->type)) {
pr_err("type requires a 4 character value\n");
return 0;
}
break;
- case opt_umask:
+ case Opt_umask:
if (match_octal(&args[0], &tmp)) {
pr_err("umask requires a value\n");
return 0;
}
sbi->umask = (umode_t)tmp;
break;
- case opt_uid:
+ case Opt_uid:
if (match_int(&args[0], &tmp)) {
pr_err("uid requires an argument\n");
return 0;
@@ -141,7 +141,7 @@ int hfsplus_parse_options(char *input, struct hfsplus_sb_info *sbi)
return 0;
}
break;
- case opt_gid:
+ case Opt_gid:
if (match_int(&args[0], &tmp)) {
pr_err("gid requires an argument\n");
return 0;
@@ -152,19 +152,19 @@ int hfsplus_parse_options(char *input, struct hfsplus_sb_info *sbi)
return 0;
}
break;
- case opt_part:
+ case Opt_part:
if (match_int(&args[0], &sbi->part)) {
pr_err("part requires an argument\n");
return 0;
}
break;
- case opt_session:
+ case Opt_session:
if (match_int(&args[0], &sbi->session)) {
pr_err("session requires an argument\n");
return 0;
}
break;
- case opt_nls:
+ case Opt_nls:
if (sbi->nls) {
pr_err("unable to change nls mapping\n");
return 0;
@@ -180,19 +180,19 @@ int hfsplus_parse_options(char *input, struct hfsplus_sb_info *sbi)
}
kfree(p);
break;
- case opt_decompose:
+ case Opt_decompose:
clear_bit(HFSPLUS_SB_NODECOMPOSE, &sbi->flags);
break;
- case opt_nodecompose:
+ case Opt_nodecompose:
set_bit(HFSPLUS_SB_NODECOMPOSE, &sbi->flags);
break;
- case opt_barrier:
+ case Opt_barrier:
clear_bit(HFSPLUS_SB_NOBARRIER, &sbi->flags);
break;
- case opt_nobarrier:
+ case Opt_nobarrier:
set_bit(HFSPLUS_SB_NOBARRIER, &sbi->flags);
break;
- case opt_force:
+ case Opt_force:
set_bit(HFSPLUS_SB_FORCE, &sbi->flags);
break;
default:
--
2.4.2
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1 linux-next] fs/hfsplus/options.c: use standard option prefix
2015-06-05 19:40 [PATCH 1/1 linux-next] fs/hfsplus/options.c: use standard option prefix Fabian Frederick
@ 2015-06-06 13:31 ` Richard Weinberger
2015-06-14 9:21 ` Fabian Frederick
0 siblings, 1 reply; 4+ messages in thread
From: Richard Weinberger @ 2015-06-06 13:31 UTC (permalink / raw)
To: Fabian Frederick; +Cc: LKML, Andrew Morton, linux-fsdevel
On Fri, Jun 5, 2015 at 9:40 PM, Fabian Frederick <fabf@skynet.be> wrote:
> All filesystems use Opt_ prefix for match_table_t enums
And needs hfsplus this patch?
It should not matter whether a filesystem is using opt_ or Opt_.
--
Thanks,
//richard
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1 linux-next] fs/hfsplus/options.c: use standard option prefix
2015-06-06 13:31 ` Richard Weinberger
@ 2015-06-14 9:21 ` Fabian Frederick
2015-06-14 12:16 ` Richard Weinberger
0 siblings, 1 reply; 4+ messages in thread
From: Fabian Frederick @ 2015-06-14 9:21 UTC (permalink / raw)
To: Richard Weinberger; +Cc: Andrew Morton, LKML, linux-fsdevel
> On 06 June 2015 at 15:31 Richard Weinberger <richard.weinberger@gmail.com>
> wrote:
>
>
> On Fri, Jun 5, 2015 at 9:40 PM, Fabian Frederick <fabf@skynet.be> wrote:
> > All filesystems use Opt_ prefix for match_table_t enums
>
> And needs hfsplus this patch?
> It should not matter whether a filesystem is using opt_ or Opt_.
It's the only one using different prefix.
This can also lead to grep/stat issues.
Regards,
Fabian
>
> --
> Thanks,
> //richard
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1 linux-next] fs/hfsplus/options.c: use standard option prefix
2015-06-14 9:21 ` Fabian Frederick
@ 2015-06-14 12:16 ` Richard Weinberger
0 siblings, 0 replies; 4+ messages in thread
From: Richard Weinberger @ 2015-06-14 12:16 UTC (permalink / raw)
To: Fabian Frederick; +Cc: Andrew Morton, LKML, linux-fsdevel
Am 14.06.2015 um 11:21 schrieb Fabian Frederick:
>
>
>> On 06 June 2015 at 15:31 Richard Weinberger <richard.weinberger@gmail.com>
>> wrote:
>>
>>
>> On Fri, Jun 5, 2015 at 9:40 PM, Fabian Frederick <fabf@skynet.be> wrote:
>>> All filesystems use Opt_ prefix for match_table_t enums
>>
>> And needs hfsplus this patch?
>> It should not matter whether a filesystem is using opt_ or Opt_.
> It's the only one using different prefix.
> This can also lead to grep/stat issues.
That's right. Making code more grep friendly is a good thing.
This has to go into the commit message.
Thanks,
//richard
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-06-14 12:16 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-05 19:40 [PATCH 1/1 linux-next] fs/hfsplus/options.c: use standard option prefix Fabian Frederick
2015-06-06 13:31 ` Richard Weinberger
2015-06-14 9:21 ` Fabian Frederick
2015-06-14 12:16 ` Richard Weinberger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).