* [PATCH] fs: ext4: remove unused variable warning in parse_options()
@ 2019-11-11 2:25 Olof Johansson
2019-11-12 16:23 ` Ritesh Harjani
0 siblings, 1 reply; 3+ messages in thread
From: Olof Johansson @ 2019-11-11 2:25 UTC (permalink / raw)
To: tytso, adilger.kernel; +Cc: linux-ext4, linux-kernel, Olof Johansson
Commit c33fbe8f673c5 ("ext4: Enable blocksize < pagesize for
dioread_nolock") removed the only user of 'sbi' outside of the ifdef,
so it caused a new warning:
fs/ext4/super.c:2068:23: warning: unused variable 'sbi' [-Wunused-variable]
Fixes: c33fbe8f673c5 ("ext4: Enable blocksize < pagesize for dioread_nolock")
Signed-off-by: Olof Johansson <olof@lixom.net>
---
fs/ext4/super.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/ext4/super.c b/fs/ext4/super.c
index f3279210f0ba9..ee8c42d8a04f0 100644
--- a/fs/ext4/super.c
+++ b/fs/ext4/super.c
@@ -2065,7 +2065,7 @@ static int parse_options(char *options, struct super_block *sb,
unsigned int *journal_ioprio,
int is_remount)
{
- struct ext4_sb_info *sbi = EXT4_SB(sb);
+ struct ext4_sb_info __maybe_unused *sbi = EXT4_SB(sb);
char *p, __maybe_unused *usr_qf_name, __maybe_unused *grp_qf_name;
substring_t args[MAX_OPT_ARGS];
int token;
--
2.11.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] fs: ext4: remove unused variable warning in parse_options()
2019-11-11 2:25 [PATCH] fs: ext4: remove unused variable warning in parse_options() Olof Johansson
@ 2019-11-12 16:23 ` Ritesh Harjani
2019-11-14 22:59 ` Theodore Y. Ts'o
0 siblings, 1 reply; 3+ messages in thread
From: Ritesh Harjani @ 2019-11-12 16:23 UTC (permalink / raw)
To: Olof Johansson, tytso, adilger.kernel; +Cc: linux-ext4, linux-kernel, Jan Kara
On 11/11/19 7:55 AM, Olof Johansson wrote:
> Commit c33fbe8f673c5 ("ext4: Enable blocksize < pagesize for
> dioread_nolock") removed the only user of 'sbi' outside of the ifdef,
> so it caused a new warning:
>
> fs/ext4/super.c:2068:23: warning: unused variable 'sbi' [-Wunused-variable]
>
> Fixes: c33fbe8f673c5 ("ext4: Enable blocksize < pagesize for dioread_nolock")
> Signed-off-by: Olof Johansson <olof@lixom.net>
hmm, I see that I had CONFIG_QUOTA enabled, so missed this.
Thanks for the patch.
You may add:
Reviewed-by: Ritesh Harjani <riteshh@linux.ibm.com>
> ---
> fs/ext4/super.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/ext4/super.c b/fs/ext4/super.c
> index f3279210f0ba9..ee8c42d8a04f0 100644
> --- a/fs/ext4/super.c
> +++ b/fs/ext4/super.c
> @@ -2065,7 +2065,7 @@ static int parse_options(char *options, struct super_block *sb,
> unsigned int *journal_ioprio,
> int is_remount)
> {
> - struct ext4_sb_info *sbi = EXT4_SB(sb);
> + struct ext4_sb_info __maybe_unused *sbi = EXT4_SB(sb);
> char *p, __maybe_unused *usr_qf_name, __maybe_unused *grp_qf_name;
> substring_t args[MAX_OPT_ARGS];
> int token;
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] fs: ext4: remove unused variable warning in parse_options()
2019-11-12 16:23 ` Ritesh Harjani
@ 2019-11-14 22:59 ` Theodore Y. Ts'o
0 siblings, 0 replies; 3+ messages in thread
From: Theodore Y. Ts'o @ 2019-11-14 22:59 UTC (permalink / raw)
To: Ritesh Harjani
Cc: Olof Johansson, adilger.kernel, linux-ext4, linux-kernel, Jan Kara
On Tue, Nov 12, 2019 at 09:53:39PM +0530, Ritesh Harjani wrote:
>
>
> On 11/11/19 7:55 AM, Olof Johansson wrote:
> > Commit c33fbe8f673c5 ("ext4: Enable blocksize < pagesize for
> > dioread_nolock") removed the only user of 'sbi' outside of the ifdef,
> > so it caused a new warning:
> >
> > fs/ext4/super.c:2068:23: warning: unused variable 'sbi' [-Wunused-variable]
> >
> > Fixes: c33fbe8f673c5 ("ext4: Enable blocksize < pagesize for dioread_nolock")
> > Signed-off-by: Olof Johansson <olof@lixom.net>
>
> hmm, I see that I had CONFIG_QUOTA enabled, so missed this.
> Thanks for the patch.
>
> You may add:
> Reviewed-by: Ritesh Harjani <riteshh@linux.ibm.com>
Thanks, applied.
- Ted
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-11-14 22:59 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-11 2:25 [PATCH] fs: ext4: remove unused variable warning in parse_options() Olof Johansson
2019-11-12 16:23 ` Ritesh Harjani
2019-11-14 22:59 ` Theodore Y. Ts'o
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).