[1/2] libgloss/riscv: Fix old style function declaration warnings

Message ID 20251201143333.513005-2-pincheng.plct@isrc.iscas.ac.cn
State New
Headers
Series libgloss: Fix build warnings for RISC-V |

Commit Message

Pincheng Wang Dec. 1, 2025, 2:33 p.m. UTC
  Signed-off-by: Pincheng Wang <pincheng.plct@isrc.iscas.ac.cn>
---
 libgloss/libnosys/sbrk.c           | 3 +--
 libgloss/riscv/semihost-sys_sbrk.c | 3 +--
 libgloss/riscv/sys_sbrk.c          | 3 +--
 3 files changed, 3 insertions(+), 6 deletions(-)
  

Patch

diff --git a/libgloss/libnosys/sbrk.c b/libgloss/libnosys/sbrk.c
index 86c130ab6..f48f27fa5 100644
--- a/libgloss/libnosys/sbrk.c
+++ b/libgloss/libnosys/sbrk.c
@@ -4,8 +4,7 @@ 
 #include <_syslist.h>
 
 void *
-_sbrk (incr)
-     int incr;
+_sbrk (int incr)
 {
    extern char   end; /* Set by linker.  */
    static char * heap_end;
diff --git a/libgloss/riscv/semihost-sys_sbrk.c b/libgloss/riscv/semihost-sys_sbrk.c
index cbd035832..8944e6572 100644
--- a/libgloss/riscv/semihost-sys_sbrk.c
+++ b/libgloss/riscv/semihost-sys_sbrk.c
@@ -12,8 +12,7 @@  char *heap_ptr;
  *         left of memory on the board.
  */
 char *
-_sbrk (nbytes)
-     int nbytes;
+_sbrk (int nbytes)
 {
   char *base;
 
diff --git a/libgloss/riscv/sys_sbrk.c b/libgloss/riscv/sys_sbrk.c
index 086509efa..48133ba88 100644
--- a/libgloss/riscv/sys_sbrk.c
+++ b/libgloss/riscv/sys_sbrk.c
@@ -10,8 +10,7 @@  char *heap_ptr;
  *         left of memory on the board.
  */
 char *
-_sbrk (nbytes)
-     int nbytes;
+_sbrk (int nbytes)
 {
   char        *base;