* [PATCH] [v3] parport: mfc3: avoid empty-body warning
@ 2024-04-05 14:42 Arnd Bergmann
2024-04-09 7:52 ` Geert Uytterhoeven
0 siblings, 1 reply; 2+ messages in thread
From: Arnd Bergmann @ 2024-04-05 14:42 UTC (permalink / raw)
To: Greg Kroah-Hartman; +Cc: Arnd Bergmann, Sudip Mukherjee, linux-kernel
From: Arnd Bergmann <arnd@arndb.de>
on m68k builds, the mfc3 driver causes a warning about an empty if() block:
drivers/parport/parport_mfc3.c: In function 'control_pc_to_mfc3':
drivers/parport/parport_mfc3.c:106:37: warning: suggest braces around empty body in an 'if' statement [-Wempty-body]
Remove it in favor of a simpler comment.
Acked-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Link: https://lore.kernel.org/lkml/20230727122448.2479942-1-arnd@kernel.org/
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
This one was still missing from my series to enable more warnings by default
in Makefile.extrawarn.
Greg, can you take this through the char-misc tree for 6.10?
---
drivers/parport/parport_mfc3.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/parport/parport_mfc3.c b/drivers/parport/parport_mfc3.c
index f4d0da741e85..bb1817218d7b 100644
--- a/drivers/parport/parport_mfc3.c
+++ b/drivers/parport/parport_mfc3.c
@@ -102,8 +102,7 @@ static unsigned char control_pc_to_mfc3(unsigned char control)
ret |= 128;
if (control & PARPORT_CONTROL_AUTOFD) /* AUTOLF */
ret &= ~64;
- if (control & PARPORT_CONTROL_STROBE) /* Strobe */
- /* Handled directly by hardware */;
+ /* PARPORT_CONTROL_STROBE handled directly by hardware */
return ret;
}
--
2.39.2
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] [v3] parport: mfc3: avoid empty-body warning
2024-04-05 14:42 [PATCH] [v3] parport: mfc3: avoid empty-body warning Arnd Bergmann
@ 2024-04-09 7:52 ` Geert Uytterhoeven
0 siblings, 0 replies; 2+ messages in thread
From: Geert Uytterhoeven @ 2024-04-09 7:52 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Greg Kroah-Hartman, Arnd Bergmann, Sudip Mukherjee, linux-kernel
Hi Arnd,
Thanks for your patch!
On Fri, Apr 5, 2024 at 4:43 PM Arnd Bergmann <arnd@kernel.org> wrote:
> From: Arnd Bergmann <arnd@arndb.de>
>
> on m68k builds, the mfc3 driver causes a warning about an empty if() block:
>
> drivers/parport/parport_mfc3.c: In function 'control_pc_to_mfc3':
> drivers/parport/parport_mfc3.c:106:37: warning: suggest braces around empty body in an 'if' statement [-Wempty-body]
>
> Remove it in favor of a simpler comment.
>
> Acked-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
> Link: https://lore.kernel.org/lkml/20230727122448.2479942-1-arnd@kernel.org/
Why the Link-tag, pointing to v2?
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
For the actual patch:
Reviewed-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] 2+ messages in thread
end of thread, other threads:[~2024-04-09 7:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-05 14:42 [PATCH] [v3] parport: mfc3: avoid empty-body warning Arnd Bergmann
2024-04-09 7:52 ` Geert Uytterhoeven
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®