Skip to contentSkip to conversation

freebsd/contigmem: fix function parameter list

PATCH Applied Bruce Richardson 3 participants 3 messages May 22, 2023 – May 24, 2023

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 freebsd/contigmem: fix function parameter list

Functions which take no parameters should explicitly have "(void)" as the parameter list, rather than "()".

Reported upstream on FreeBSD ports collection [1].

[1] https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=271524

Fixes 764bf26873b9 ("add FreeBSD support")
---
 kernel/freebsd/contigmem/contigmem.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
kernel/freebsd/contigmem/contigmem.c +2 -2
index bd72f4d620..7dd87599d9 100644
@@ -111,7 +111,7 @@ static struct cdevsw contigmem_ops = {
 };
 
 static int
-contigmem_load()
+contigmem_load(void)
 {
 	char index_string[8], description[32];
 	int  i, error = 0;
@@ -178,7 +178,7 @@ contigmem_load()
 }
 
 static int
-contigmem_unload()
+contigmem_unload(void)
 {
 	int i;
 
Signature · 1 line
2.39.2
Acked-by on v1 1/1
#1 lore raw
Quoted 5 lines · Bruce Richardson

Functions which take no parameters should explicitly have "(void)" as the parameter list, rather than "()".

Reported upstream on FreeBSD ports collection [1].

Quoted 8 lines

[1] https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=271524

Fixes 764bf26873b9 ("add FreeBSD support")

---

#2 lore raw

22/05/2023 18:02, Tyler Retzlaff:

Quoted 8 lines · Bruce Richardson
Quoted 7 lines

Functions which take no parameters should explicitly have "(void)" as the parameter list, rather than "()".

Reported upstream on FreeBSD ports collection [1].

[1] https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=271524

Quoted 7 lines
Quoted 6 lines
Fixes 764bf26873b9 ("add FreeBSD support")

---

Applied, thanks.