Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/pmax make the argument to prom getenv() cnd the pri...



details:   https://anonhg.NetBSD.org/src/rev/dc7f46203948
branches:  trunk
changeset: 581451:dc7f46203948
user:      drochner <drochner%NetBSD.org@localhost>
date:      Wed Jun 01 18:32:07 2005 +0000

description:
make the argument to prom getenv() cnd the printf() format const
remove variable names from prototypes

diffstat:

 sys/arch/pmax/include/dec_prom.h     |  90 ++++++++++++++++++------------------
 sys/arch/pmax/pmax/machdep.h         |   4 +-
 sys/arch/pmax/pmax/promcall.c        |   6 +-
 sys/arch/pmax/stand/common/callvec.c |  74 ++++++++++++++--------------
 4 files changed, 87 insertions(+), 87 deletions(-)

diffs (244 lines):

diff -r 5fd09d7f8919 -r dc7f46203948 sys/arch/pmax/include/dec_prom.h
--- a/sys/arch/pmax/include/dec_prom.h  Wed Jun 01 18:29:16 2005 +0000
+++ b/sys/arch/pmax/include/dec_prom.h  Wed Jun 01 18:32:07 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: dec_prom.h,v 1.18 2003/08/07 16:29:11 agc Exp $        */
+/*     $NetBSD: dec_prom.h,v 1.19 2005/06/01 18:32:07 drochner Exp $   */
 
 /*
  * Copyright (c) 1992, 1993
@@ -92,50 +92,50 @@
 typedef void (*psig_t)(int);
 
 struct callback {
-       void    *(*_memcpy) __P((void *s1, void *s2, int n));           /* 00 */
-       void    *(*_memset) __P((void *s1, int c, int n));              /* 04 */
-       char    *(*_strcat) __P((char *s1, char *s2));                  /* 08 */
-       int     (*_strcmp) __P((char *s1, char *s2));                   /* 0c */
-       char    *(*_strcpy) __P((char *s1, char *s2));                  /* 10 */
-       int     (*_strlen) __P((char *s1));                             /* 14 */
-       char    *(*_strncat) __P((char *s1, char *s2, int n));          /* 18 */
-       char    *(*_strncpy) __P((char *s1, char *s2, int n));          /* 1c */
-       int     (*_strncmp) __P((char *s1, char *s2, int n));           /* 20 */
-       int     (*_getchar) __P((void));                                /* 24 */
-       char    *(*_gets) __P((char *s));                               /* 28 */
-       int     (*_puts) __P((char *s));                                /* 2c */
-       int     (*_printf) __P((char *fmt, ...));                       /* 30 */
-       int     (*_sprintf) __P((char *s, char *fmt, ...));             /* 34 */
-       int     (*_io_poll) __P((void));                                /* 38 */
-       long    (*_strtol) __P((char *s, char **endptr, int base));     /* 3c */
-       psig_t  (*_signal) __P((int sig, psig_t func));                 /* 40 */
-       int     (*_raise) __P((int sig));                               /* 44 */
-       long    (*_time) __P((long *tod));                              /* 48 */
-       int     (*_setjmp) __P((jmp_buf env));                          /* 4c */
-       void    (*_longjmp) __P((jmp_buf env, int value));              /* 50 */
-       int     (*_bootinit) __P((char *fname));                        /* 54 */
-       int     (*_bootread) __P((int b, void *buffer, int n));         /* 58 */
-       int     (*_bootwrite) __P((int b, void *buffer, int n));        /* 5c */
-       int     (*_setenv) __P((char *name, char *value));              /* 60 */
-       char    *(*_getenv) __P((char *name));                          /* 64 */
-       int     (*_unsetenv) __P((char *name));                         /* 68 */
-       u_long  (*_slot_address) __P((int sn));                         /* 6c */
-       void    (*_wbflush) __P((void));                                /* 70 */
-       void    (*_msdelay) __P((int delay));                           /* 74 */
-       void    (*_leds) __P((int value));                              /* 78 */
-       void    (*_clear_cache) __P((char *addr, int len));             /* 7c */
-       int     (*_getsysid) __P((void));                               /* 80 */
-       int     (*_getbitmap) __P((memmap *map));                       /* 84 */
-       int     (*_disableintr) __P((int sn));                          /* 88 */
-       int     (*_enableintr) __P((int sn));                           /* 8c */
-       int     (*_testintr) __P((int sn));                             /* 90 */
-       void    *_reserved_data;                                        /* 94 */
-       int     (*_console_init) __P((void));                           /* 98 */
-       void    (*_halt) __P((int *v, int cnt));                        /* 9c */
-       void    (*_showfault) __P((void));                              /* a0 */
-       tcinfo  *(*_gettcinfo) __P((void));     /*XXX* bogus proto */   /* a4 */
-       int     (*_execute_cmd) __P((char *cmd));                       /* a8 */
-       void    (*_rex) __P((char cmd));                                /* ac */
+       void    *(*_memcpy) __P((void *, void *, int));         /* 00 */
+       void    *(*_memset) __P((void *, int, int));            /* 04 */
+       char    *(*_strcat) __P((char *, char *));              /* 08 */
+       int     (*_strcmp) __P((char *, char *));               /* 0c */
+       char    *(*_strcpy) __P((char *, char *));              /* 10 */
+       int     (*_strlen) __P((char *));                       /* 14 */
+       char    *(*_strncat) __P((char *, char *, int));        /* 18 */
+       char    *(*_strncpy) __P((char *, char *, int));        /* 1c */
+       int     (*_strncmp) __P((char *, char *, int));         /* 20 */
+       int     (*_getchar) __P((void));                        /* 24 */
+       char    *(*_gets) __P((char *));                        /* 28 */
+       int     (*_puts) __P((char *));                         /* 2c */
+       int     (*_printf) __P((const char *, ...));            /* 30 */
+       int     (*_sprintf) __P((char *, char *, ...));         /* 34 */
+       int     (*_io_poll) __P((void));                        /* 38 */
+       long    (*_strtol) __P((char *, char **, int));         /* 3c */
+       psig_t  (*_signal) __P((int, psig_t));                  /* 40 */
+       int     (*_raise) __P((int));                           /* 44 */
+       long    (*_time) __P((long *));                         /* 48 */
+       int     (*_setjmp) __P((jmp_buf));                      /* 4c */
+       void    (*_longjmp) __P((jmp_buf, int));                /* 50 */
+       int     (*_bootinit) __P((char *));                     /* 54 */
+       int     (*_bootread) __P((int, void *, int));           /* 58 */
+       int     (*_bootwrite) __P((int, void *, int));          /* 5c */
+       int     (*_setenv) __P((char *, char *));               /* 60 */
+       char    *(*_getenv) __P((const char *));                /* 64 */
+       int     (*_unsetenv) __P((char *));                     /* 68 */
+       u_long  (*_slot_address) __P((int));                    /* 6c */
+       void    (*_wbflush) __P((void));                        /* 70 */
+       void    (*_msdelay) __P((int));                         /* 74 */
+       void    (*_leds) __P((int));                            /* 78 */
+       void    (*_clear_cache) __P((char *, int));             /* 7c */
+       int     (*_getsysid) __P((void));                       /* 80 */
+       int     (*_getbitmap) __P((memmap *));                  /* 84 */
+       int     (*_disableintr) __P((int));                     /* 88 */
+       int     (*_enableintr) __P((int));                      /* 8c */
+       int     (*_testintr) __P((int));                        /* 90 */
+       void    *_reserved_data;                                /* 94 */
+       int     (*_console_init) __P((void));                   /* 98 */
+       void    (*_halt) __P((int *, int));                     /* 9c */
+       void    (*_showfault) __P((void));                      /* a0 */
+       tcinfo  *(*_gettcinfo) __P((void)); /*XXX* bogus proto */ /* a4 */
+       int     (*_execute_cmd) __P((char *));                  /* a8 */
+       void    (*_rex) __P((char));                            /* ac */
        /* b0 to d4 reserved */
 };
 
diff -r 5fd09d7f8919 -r dc7f46203948 sys/arch/pmax/pmax/machdep.h
--- a/sys/arch/pmax/pmax/machdep.h      Wed Jun 01 18:29:16 2005 +0000
+++ b/sys/arch/pmax/pmax/machdep.h      Wed Jun 01 18:32:07 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: machdep.h,v 1.9 2001/08/24 15:33:17 mhitch Exp $ */
+/* $NetBSD: machdep.h,v 1.10 2005/06/01 18:32:08 drochner Exp $ */
 
 /*
  * Copyright (c) 1998 Jonathan Stone.  All rights reserved.
@@ -40,6 +40,6 @@
 void    prom_halt __P((int, char *)) __attribute__((__noreturn__));
 void    prom_haltbutton __P((void));
 int     prom_scsiid __P((int));
-char   *prom_getenv __P((char *));
+char   *prom_getenv __P((const char *));
 int     prom_systype __P((void));
 int     prom_getbitmap __P((struct memmap *));
diff -r 5fd09d7f8919 -r dc7f46203948 sys/arch/pmax/pmax/promcall.c
--- a/sys/arch/pmax/pmax/promcall.c     Wed Jun 01 18:29:16 2005 +0000
+++ b/sys/arch/pmax/pmax/promcall.c     Wed Jun 01 18:32:07 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: promcall.c,v 1.9 2003/08/07 16:29:14 agc Exp $ */
+/*     $NetBSD: promcall.c,v 1.10 2005/06/01 18:32:08 drochner Exp $   */
 
 /*
  * Copyright (c) 1992, 1993
@@ -77,7 +77,7 @@
  */
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
-__KERNEL_RCSID(0, "$NetBSD: promcall.c,v 1.9 2003/08/07 16:29:14 agc Exp $");
+__KERNEL_RCSID(0, "$NetBSD: promcall.c,v 1.10 2005/06/01 18:32:08 drochner Exp $");
 
 #include <sys/param.h>
 #include <sys/device.h>
@@ -199,7 +199,7 @@
  */
 char *
 prom_getenv(name)
-       char *name;
+       const char *name;
 {
        return (*callv->_getenv)(name);
 }
diff -r 5fd09d7f8919 -r dc7f46203948 sys/arch/pmax/stand/common/callvec.c
--- a/sys/arch/pmax/stand/common/callvec.c      Wed Jun 01 18:29:16 2005 +0000
+++ b/sys/arch/pmax/stand/common/callvec.c      Wed Jun 01 18:32:07 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: callvec.c,v 1.14 2003/08/07 16:29:15 agc Exp $ */
+/*     $NetBSD: callvec.c,v 1.15 2005/06/01 18:32:08 drochner Exp $    */
 
 /*-
  * Copyright (c) 1992, 1993
@@ -37,50 +37,50 @@
 #include <machine/dec_prom.h>
 
 const struct callback callvec = {
-       (void *(*) __P((void *s1, void *s2, int n)))0,
-       (void *(*) __P((void *s1, int c, int n)))0,
-       (char *(*) __P((char *s1, char *s2)))DEC_PROM_STRCAT,
-       (int (*) __P((char *s1, char *s2)))DEC_PROM_STRCMP,
-       (char *(*) __P((char *s1, char *s2)))DEC_PROM_STRCPY,
-       (int (*) __P((char *s1)))DEC_PROM_STRLEN,
-       (char *(*) __P((char *s1, char *s2, int n)))0,
-       (char *(*) __P((char *s1, char *s2, int n)))0,
-       (int (*) __P((char *s1, char *s2, int n)))0,
+       (void *(*) __P((void *, void *, int)))0,
+       (void *(*) __P((void *, int, int)))0,
+       (char *(*) __P((char *, char *)))DEC_PROM_STRCAT,
+       (int (*) __P((char *, char *)))DEC_PROM_STRCMP,
+       (char *(*) __P((char *, char *)))DEC_PROM_STRCPY,
+       (int (*) __P((char *)))DEC_PROM_STRLEN,
+       (char *(*) __P((char *, char *, int)))0,
+       (char *(*) __P((char *, char *, int)))0,
+       (int (*) __P((char *, char *, int)))0,
        (int (*) __P((void)))DEC_PROM_GETCHAR,
-       (char *(*) __P((char *s)))DEC_PROM_GETS,
-       (int (*) __P((char *s)))DEC_PROM_PUTS,
-       (int (*) __P((char *fmt, ...)))DEC_PROM_PRINTF,
-       (int (*) __P((char *s, char *fmt, ...)))0,
+       (char *(*) __P((char *)))DEC_PROM_GETS,
+       (int (*) __P((char *)))DEC_PROM_PUTS,
+       (int (*) __P((const char *, ...)))DEC_PROM_PRINTF,
+       (int (*) __P((char *, char *, ...)))0,
        (int (*) __P((void)))0,
-       (long (*) __P((char *s, char **endptr, int base)))0,
-       (psig_t (*) __P((int sig, psig_t func)))0,
-       (int (*) __P((int sig)))0,
-       (long (*) __P((long *tod)))0,
-       (int (*) __P((jmp_buf env)))0,
-       (void (*) __P((jmp_buf env, int value)))0,
-       (int (*) __P(( char *fname)))0,
-       (int (*) __P((int b, void *buffer, int n)))0,
-       (int (*) __P((int b, void *buffer, int n)))0,
-       (int (*) __P((char *name, char *value)))DEC_PROM_SETENV2,
-       (char *(*) __P((char *name)))DEC_PROM_GETENV2,
-       (int (*) __P((char *name)))DEC_PROM_UNSETENV,
-       (u_long (*) __P((int sn)))0,
+       (long (*) __P((char *, char **, int)))0,
+       (psig_t (*) __P((int, psig_t)))0,
+       (int (*) __P((int)))0,
+       (long (*) __P((long *)))0,
+       (int (*) __P((jmp_buf)))0,
+       (void (*) __P((jmp_buf, int)))0,
+       (int (*) __P(( char *)))0,
+       (int (*) __P((int, void *, int)))0,
+       (int (*) __P((int, void *, int)))0,
+       (int (*) __P((char *, char *)))DEC_PROM_SETENV2,
+       (char *(*) __P((const char *)))DEC_PROM_GETENV2,
+       (int (*) __P((char *)))DEC_PROM_UNSETENV,
+       (u_long (*) __P((int)))0,
        (void (*) __P((void)))0,
-       (void (*) __P((int delay)))0,
-       (void (*) __P((int value)))0,
-       (void (*) __P((char *addr, int len)))DEC_PROM_CLEARCACHE,
+       (void (*) __P((int)))0,
+       (void (*) __P((int)))0,
+       (void (*) __P((char *, int)))DEC_PROM_CLEARCACHE,
        (int (*) __P((void)))0,
-       (int (*) __P((memmap *map)))0,
-       (int (*) __P((int sn)))0,
-       (int (*) __P((int sn)))0,
-       (int (*) __P((int sn)))0,
+       (int (*) __P((memmap *)))0,
+       (int (*) __P((int)))0,
+       (int (*) __P((int)))0,
+       (int (*) __P((int)))0,
        (void *)0,
        (int (*) __P((void)))0,
-       (void (*) __P((int *v, int cnt)))0,
+       (void (*) __P((int *, int)))0,
        (void (*) __P((void)))0,
        (tcinfo *(*) __P((void)))0,     /* XXX what are the args for this?*/
-       (int (*) __P((char *cmd)))0,
-       (void (*) __P((char cmd)))0,
+       (int (*) __P((char *)))0,
+       (void (*) __P((char)))0,
 };
 
 const   struct callback *callv = &callvec;



Home | Main Index | Thread Index | Old Index