* [PATCH] btrfs: ref-verify: use 'inline void' keyword ordering
@ 2021-02-19 6:54 Randy Dunlap
2021-02-22 11:47 ` Geert Uytterhoeven
2021-02-22 17:40 ` David Sterba
0 siblings, 2 replies; 3+ messages in thread
From: Randy Dunlap @ 2021-02-19 6:54 UTC (permalink / raw)
To: linux-kernel
Cc: Randy Dunlap, Josef Bacik, David Sterba, Chris Mason, linux-btrfs,
Andrew Morton
Fix build warnings of function signature when CONFIG_STACKTRACE is not
enabled by reordering the 'inline' and 'void' keywords.
../fs/btrfs/ref-verify.c:221:1: warning: ‘inline’ is not at beginning of declaration [-Wold-style-declaration]
static void inline __save_stack_trace(struct ref_action *ra)
../fs/btrfs/ref-verify.c:225:1: warning: ‘inline’ is not at beginning of declaration [-Wold-style-declaration]
static void inline __print_stack_trace(struct btrfs_fs_info *fs_info,
Fixes: fd708b81d972 ("Btrfs: add a extent ref verify tool")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Josef Bacik <jbacik@fb.com>
Cc: David Sterba <dsterba@suse.com>
Cc: Chris Mason <clm@fb.com>
Cc: linux-btrfs@vger.kernel.org
Cc: Andrew Morton <akpm@linux-foundation.org>
---
Found in mmotm; applies to mainline.
Apparently we are doing more '-W' checking than when this change was
made in 2017.
fs/btrfs/ref-verify.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- mmotm-2021-0218-1829.orig/fs/btrfs/ref-verify.c
+++ mmotm-2021-0218-1829/fs/btrfs/ref-verify.c
@@ -218,11 +218,11 @@ static void __print_stack_trace(struct b
stack_trace_print(ra->trace, ra->trace_len, 2);
}
#else
-static void inline __save_stack_trace(struct ref_action *ra)
+static inline void __save_stack_trace(struct ref_action *ra)
{
}
-static void inline __print_stack_trace(struct btrfs_fs_info *fs_info,
+static inline void __print_stack_trace(struct btrfs_fs_info *fs_info,
struct ref_action *ra)
{
btrfs_err(fs_info, " ref-verify: no stacktrace support");
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] btrfs: ref-verify: use 'inline void' keyword ordering
2021-02-19 6:54 [PATCH] btrfs: ref-verify: use 'inline void' keyword ordering Randy Dunlap
@ 2021-02-22 11:47 ` Geert Uytterhoeven
2021-02-22 17:40 ` David Sterba
1 sibling, 0 replies; 3+ messages in thread
From: Geert Uytterhoeven @ 2021-02-22 11:47 UTC (permalink / raw)
To: Randy Dunlap
Cc: Linux Kernel Mailing List, Josef Bacik, David Sterba, Chris Mason,
linux-btrfs, Andrew Morton
On Fri, Feb 19, 2021 at 7:57 AM Randy Dunlap <rdunlap@infradead.org> wrote:
> Fix build warnings of function signature when CONFIG_STACKTRACE is not
> enabled by reordering the 'inline' and 'void' keywords.
>
> ../fs/btrfs/ref-verify.c:221:1: warning: ‘inline’ is not at beginning of declaration [-Wold-style-declaration]
> static void inline __save_stack_trace(struct ref_action *ra)
> ../fs/btrfs/ref-verify.c:225:1: warning: ‘inline’ is not at beginning of declaration [-Wold-style-declaration]
> static void inline __print_stack_trace(struct btrfs_fs_info *fs_info,
>
> Fixes: fd708b81d972 ("Btrfs: add a extent ref verify tool")
> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
> Cc: Josef Bacik <jbacik@fb.com>
> Cc: David Sterba <dsterba@suse.com>
> Cc: Chris Mason <clm@fb.com>
> Cc: linux-btrfs@vger.kernel.org
> Cc: Andrew Morton <akpm@linux-foundation.org>
> ---
> Found in mmotm; applies to mainline.
Thanks, fixes the warning in mainline for me.
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] btrfs: ref-verify: use 'inline void' keyword ordering
2021-02-19 6:54 [PATCH] btrfs: ref-verify: use 'inline void' keyword ordering Randy Dunlap
2021-02-22 11:47 ` Geert Uytterhoeven
@ 2021-02-22 17:40 ` David Sterba
1 sibling, 0 replies; 3+ messages in thread
From: David Sterba @ 2021-02-22 17:40 UTC (permalink / raw)
To: Randy Dunlap
Cc: linux-kernel, Josef Bacik, David Sterba, Chris Mason, linux-btrfs,
Andrew Morton
On Thu, Feb 18, 2021 at 10:54:17PM -0800, Randy Dunlap wrote:
> Fix build warnings of function signature when CONFIG_STACKTRACE is not
> enabled by reordering the 'inline' and 'void' keywords.
>
> ../fs/btrfs/ref-verify.c:221:1: warning: ‘inline’ is not at beginning of declaration [-Wold-style-declaration]
> static void inline __save_stack_trace(struct ref_action *ra)
> ../fs/btrfs/ref-verify.c:225:1: warning: ‘inline’ is not at beginning of declaration [-Wold-style-declaration]
> static void inline __print_stack_trace(struct btrfs_fs_info *fs_info,
>
> Fixes: fd708b81d972 ("Btrfs: add a extent ref verify tool")
> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
> Cc: Josef Bacik <jbacik@fb.com>
> Cc: David Sterba <dsterba@suse.com>
> Cc: Chris Mason <clm@fb.com>
> Cc: linux-btrfs@vger.kernel.org
> Cc: Andrew Morton <akpm@linux-foundation.org>
Added to misc-next thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-02-22 17:43 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-02-19 6:54 [PATCH] btrfs: ref-verify: use 'inline void' keyword ordering Randy Dunlap
2021-02-22 11:47 ` Geert Uytterhoeven
2021-02-22 17:40 ` David Sterba
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox