* [PATCH] MIPS: BCM47XX: drop unneeded semicolon
@ 2026-08-01 19:10 Julia Lawall
2026-08-02 15:17 ` Philippe Mathieu-Daudé
2026-08-03 13:10 ` Thomas Bogendoerfer
0 siblings, 2 replies; 3+ messages in thread
From: Julia Lawall @ 2026-08-01 19:10 UTC (permalink / raw)
To: Hauke Mehrtens
Cc: kernel-janitors, Rafał Miłecki, Thomas Bogendoerfer,
linux-mips, linux-kernel
When a function-like macro expands to an expression, that expression
doesn't need a semicolon after it. All uses have been verified to
have their own semicolons.
This was found using the following Coccinelle semantic patch:
@r@
identifier i : script:ocaml() { String.lowercase_ascii i = i };
expression e;
@@
*#define i(...) e;
Signed-off-by: Julia Lawall <Julia.Lawall@inria.fr>
---
arch/mips/bcm47xx/buttons.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/mips/bcm47xx/buttons.c b/arch/mips/bcm47xx/buttons.c
index 46994f9bb..e76ca34c8 100644
--- a/arch/mips/bcm47xx/buttons.c
+++ b/arch/mips/bcm47xx/buttons.c
@@ -512,7 +512,7 @@ static int __init bcm47xx_buttons_copy(const struct gpio_keys_button *buttons,
}
#define bcm47xx_copy_bdata(dev_buttons) \
- bcm47xx_buttons_copy(dev_buttons, ARRAY_SIZE(dev_buttons));
+ bcm47xx_buttons_copy(dev_buttons, ARRAY_SIZE(dev_buttons))
int __init bcm47xx_buttons_register(void)
{
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH] MIPS: BCM47XX: drop unneeded semicolon
2026-08-01 19:10 [PATCH] MIPS: BCM47XX: drop unneeded semicolon Julia Lawall
@ 2026-08-02 15:17 ` Philippe Mathieu-Daudé
2026-08-03 13:10 ` Thomas Bogendoerfer
1 sibling, 0 replies; 3+ messages in thread
From: Philippe Mathieu-Daudé @ 2026-08-02 15:17 UTC (permalink / raw)
To: Julia Lawall, Hauke Mehrtens
Cc: kernel-janitors, Rafał Miłecki, Thomas Bogendoerfer,
linux-mips, linux-kernel
On 1/8/26 21:10, Julia Lawall wrote:
> When a function-like macro expands to an expression, that expression
> doesn't need a semicolon after it. All uses have been verified to
> have their own semicolons.
>
> This was found using the following Coccinelle semantic patch:
>
> @r@
> identifier i : script:ocaml() { String.lowercase_ascii i = i };
> expression e;
> @@
>
> *#define i(...) e;
>
> Signed-off-by: Julia Lawall <Julia.Lawall@inria.fr>
>
> ---
> arch/mips/bcm47xx/buttons.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] MIPS: BCM47XX: drop unneeded semicolon
2026-08-01 19:10 [PATCH] MIPS: BCM47XX: drop unneeded semicolon Julia Lawall
2026-08-02 15:17 ` Philippe Mathieu-Daudé
@ 2026-08-03 13:10 ` Thomas Bogendoerfer
1 sibling, 0 replies; 3+ messages in thread
From: Thomas Bogendoerfer @ 2026-08-03 13:10 UTC (permalink / raw)
To: Julia Lawall
Cc: Hauke Mehrtens, kernel-janitors, Rafał Miłecki,
linux-mips, linux-kernel
On Sat, Aug 01, 2026 at 09:10:02PM +0200, Julia Lawall wrote:
> When a function-like macro expands to an expression, that expression
> doesn't need a semicolon after it. All uses have been verified to
> have their own semicolons.
>
> This was found using the following Coccinelle semantic patch:
>
> @r@
> identifier i : script:ocaml() { String.lowercase_ascii i = i };
> expression e;
> @@
>
> *#define i(...) e;
>
> Signed-off-by: Julia Lawall <Julia.Lawall@inria.fr>
>
> ---
> arch/mips/bcm47xx/buttons.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/mips/bcm47xx/buttons.c b/arch/mips/bcm47xx/buttons.c
> index 46994f9bb..e76ca34c8 100644
> --- a/arch/mips/bcm47xx/buttons.c
> +++ b/arch/mips/bcm47xx/buttons.c
> @@ -512,7 +512,7 @@ static int __init bcm47xx_buttons_copy(const struct gpio_keys_button *buttons,
> }
>
> #define bcm47xx_copy_bdata(dev_buttons) \
> - bcm47xx_buttons_copy(dev_buttons, ARRAY_SIZE(dev_buttons));
> + bcm47xx_buttons_copy(dev_buttons, ARRAY_SIZE(dev_buttons))
not applicable to mips-next, because commit 27c61f8565a4 ("MIPS: BCM47XX:
Convert buttons to software nodes") removed it.
Thomas.
--
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea. [ RFC1925, 2.3 ]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-08-03 14:12 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-01 19:10 [PATCH] MIPS: BCM47XX: drop unneeded semicolon Julia Lawall
2026-08-02 15:17 ` Philippe Mathieu-Daudé
2026-08-03 13:10 ` Thomas Bogendoerfer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox