Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src Revert printf return value change.
details: https://anonhg.NetBSD.org/src/rev/4c291ce6d2e9
branches: trunk
changeset: 357116:4c291ce6d2e9
user: joerg <joerg%NetBSD.org@localhost>
date: Fri Oct 27 12:25:14 2017 +0000
description:
Revert printf return value change.
diffstat:
share/man/man9/kprintf.9 | 4 ++--
sys/arch/x86/x86/intr.c | 6 +++---
sys/ddb/db_interface.h | 4 ++--
sys/ddb/db_panic.c | 4 ++--
sys/kern/init_main.c | 6 +++---
sys/kern/subr_autoconf.c | 8 ++++----
sys/kern/subr_disk.c | 6 +++---
sys/kern/subr_prf.c | 7 +++----
sys/kern/vfs_subr.c | 8 ++++----
sys/kern/vfs_wapbl.c | 6 +++---
sys/sys/systm.h | 4 ++--
sys/ufs/ufs/ufs_lookup.c | 6 +++---
12 files changed, 34 insertions(+), 35 deletions(-)
diffs (truncated from 316 to 300 lines):
diff -r e3c90ef7bcce -r 4c291ce6d2e9 share/man/man9/kprintf.9
--- a/share/man/man9/kprintf.9 Fri Oct 27 12:01:08 2017 +0000
+++ b/share/man/man9/kprintf.9 Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: kprintf.9,v 1.35 2017/10/27 11:15:03 utkarsh009 Exp $
+.\" $NetBSD: kprintf.9,v 1.36 2017/10/27 12:25:14 joerg Exp $
.\"
.\" Copyright (c) 1998, 2002, 2007, 2011 The NetBSD Foundation, Inc.
.\" All rights reserved.
@@ -63,7 +63,7 @@
.In sys/systm.h
.Ft void
.Fn "device_printf" "device_t" "const char *format" "..."
-.Ft int
+.Ft void
.Fn "printf" "const char *format" "..."
.Ft void
.Fn "printf_nolog" "const char *format" "..."
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/arch/x86/x86/intr.c
--- a/sys/arch/x86/x86/intr.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/arch/x86/x86/intr.c Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: intr.c,v 1.104 2017/10/27 09:59:16 utkarsh009 Exp $ */
+/* $NetBSD: intr.c,v 1.105 2017/10/27 12:25:14 joerg Exp $ */
/*-
* Copyright (c) 2007, 2008, 2009 The NetBSD Foundation, Inc.
@@ -133,7 +133,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.104 2017/10/27 09:59:16 utkarsh009 Exp $");
+__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.105 2017/10/27 12:25:14 joerg Exp $");
#include "opt_intrdebug.h"
#include "opt_multiprocessor.h"
@@ -1374,7 +1374,7 @@
CPU_INFO_ITERATOR cii;
void (*pr)(const char *, ...);
- pr = (void *)printf;
+ pr = printf;
#ifdef DDB
extern int db_active;
if (db_active) {
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/ddb/db_interface.h
--- a/sys/ddb/db_interface.h Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/ddb/db_interface.h Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_interface.h,v 1.34 2017/10/27 09:59:16 utkarsh009 Exp $ */
+/* $NetBSD: db_interface.h,v 1.35 2017/10/27 12:25:15 joerg Exp $ */
/*-
* Copyright (c) 1995 The NetBSD Foundation, Inc.
@@ -75,6 +75,6 @@
#define db_stacktrace() \
db_stack_trace_print((db_expr_t)(intptr_t)__builtin_frame_address(0), \
- true, 65535, "", (void *)printf)
+ true, 65535, "", printf)
#endif /* _DDB_DB_INTERFACE_H_ */
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/ddb/db_panic.c
--- a/sys/ddb/db_panic.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/ddb/db_panic.c Fri Oct 27 12:25:14 2017 +0000
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: db_panic.c,v 1.4 2017/10/27 09:59:16 utkarsh009 Exp $");
+__KERNEL_RCSID(0, "$NetBSD: db_panic.c,v 1.5 2017/10/27 12:25:15 joerg Exp $");
#include <sys/types.h>
#include <sys/cpu.h>
@@ -52,7 +52,7 @@
cpu_index(curcpu()));
db_stack_trace_print(
(db_expr_t)(intptr_t)__builtin_frame_address(0),
- true, 65535, "", (void *)printf);
+ true, 65535, "", printf);
printf("cpu%u: End traceback...\n",
cpu_index(curcpu()));
intrace = 0;
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/kern/init_main.c
--- a/sys/kern/init_main.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/kern/init_main.c Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: init_main.c,v 1.491 2017/10/27 09:59:16 utkarsh009 Exp $ */
+/* $NetBSD: init_main.c,v 1.492 2017/10/27 12:25:15 joerg Exp $ */
/*-
* Copyright (c) 2008, 2009 The NetBSD Foundation, Inc.
@@ -97,7 +97,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: init_main.c,v 1.491 2017/10/27 09:59:16 utkarsh009 Exp $");
+__KERNEL_RCSID(0, "$NetBSD: init_main.c,v 1.492 2017/10/27 12:25:15 joerg Exp $");
#include "opt_ddb.h"
#include "opt_inet.h"
@@ -1117,7 +1117,7 @@
printf_nolog("%s\n", notice);
pr = aprint_normal;
} else {
- pr = (void *)printf;
+ pr = printf;
}
memset(pbuf, 0, sizeof(pbuf));
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/kern/subr_autoconf.c
--- a/sys/kern/subr_autoconf.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/kern/subr_autoconf.c Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: subr_autoconf.c,v 1.254 2017/10/27 09:59:16 utkarsh009 Exp $ */
+/* $NetBSD: subr_autoconf.c,v 1.255 2017/10/27 12:25:15 joerg Exp $ */
/*
* Copyright (c) 1996, 2000 Christopher G. Demetriou
@@ -77,7 +77,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: subr_autoconf.c,v 1.254 2017/10/27 09:59:16 utkarsh009 Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_autoconf.c,v 1.255 2017/10/27 12:25:15 joerg Exp $");
#ifdef _KERNEL_OPT
#include "opt_ddb.h"
@@ -258,7 +258,7 @@
const char *style, bool dopanic)
{
void (*pr)(const char *, ...) __printflike(1, 2) =
- dopanic ? panic : (void *)printf;
+ dopanic ? panic : printf;
int i, error = 0, e2 __diagused;
for (i = 0; cfdriverv[i] != NULL; i++) {
@@ -290,7 +290,7 @@
{
const struct cfattachinit *cfai = NULL;
void (*pr)(const char *, ...) __printflike(1, 2) =
- dopanic ? panic : (void *)printf;
+ dopanic ? panic : printf;
int j = 0, error = 0, e2 __diagused;
for (cfai = &cfattachv[0]; cfai->cfai_name != NULL; cfai++) {
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/kern/subr_disk.c
--- a/sys/kern/subr_disk.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/kern/subr_disk.c Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: subr_disk.c,v 1.120 2017/10/27 09:59:16 utkarsh009 Exp $ */
+/* $NetBSD: subr_disk.c,v 1.121 2017/10/27 12:25:15 joerg Exp $ */
/*-
* Copyright (c) 1996, 1997, 1999, 2000, 2009 The NetBSD Foundation, Inc.
@@ -67,7 +67,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: subr_disk.c,v 1.120 2017/10/27 09:59:16 utkarsh009 Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_disk.c,v 1.121 2017/10/27 12:25:15 joerg Exp $");
#include <sys/param.h>
#include <sys/kernel.h>
@@ -138,7 +138,7 @@
log(pri, fmt);
pr = addlog;
} else
- pr = (void *)printf;
+ pr = printf;
(*pr)("%s%d%c: %s %sing fsbn ", dname, unit, partname, what,
bp->b_flags & B_READ ? "read" : "writ");
sn = bp->b_blkno;
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/kern/subr_prf.c
--- a/sys/kern/subr_prf.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/kern/subr_prf.c Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: subr_prf.c,v 1.161 2017/10/27 09:59:16 utkarsh009 Exp $ */
+/* $NetBSD: subr_prf.c,v 1.162 2017/10/27 12:25:15 joerg Exp $ */
/*-
* Copyright (c) 1986, 1988, 1991, 1993
@@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: subr_prf.c,v 1.161 2017/10/27 09:59:16 utkarsh009 Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_prf.c,v 1.162 2017/10/27 12:25:15 joerg Exp $");
#ifdef _KERNEL_OPT
#include "opt_ddb.h"
@@ -1032,7 +1032,7 @@
/*
* printf: print a message to the console and the log
*/
-int
+void
printf(const char *fmt, ...)
{
va_list ap;
@@ -1047,7 +1047,6 @@
if (!panicstr)
logwakeup();
- return 0;
}
/*
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/kern/vfs_subr.c
--- a/sys/kern/vfs_subr.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/kern/vfs_subr.c Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vfs_subr.c,v 1.469 2017/10/27 09:59:16 utkarsh009 Exp $ */
+/* $NetBSD: vfs_subr.c,v 1.470 2017/10/27 12:25:15 joerg Exp $ */
/*-
* Copyright (c) 1997, 1998, 2004, 2005, 2007, 2008 The NetBSD Foundation, Inc.
@@ -68,7 +68,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vfs_subr.c,v 1.469 2017/10/27 09:59:16 utkarsh009 Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vfs_subr.c,v 1.470 2017/10/27 12:25:15 joerg Exp $");
#ifdef _KERNEL_OPT
#include "opt_ddb.h"
@@ -1131,7 +1131,7 @@
if (label != NULL)
printf("%s: ", label);
- vprint_common(vp, "\t", (void *)printf);
+ vprint_common(vp, "\t", printf);
if (vp->v_data != NULL) {
printf("\t");
VOP_PRINT(vp);
@@ -1512,7 +1512,7 @@
uvm_object_printit(&vp->v_uobj, full, pr);
(*pr)("\n");
- vprint_common(vp, "", (void *)printf);
+ vprint_common(vp, "", printf);
if (full) {
struct buf *bp;
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/kern/vfs_wapbl.c
--- a/sys/kern/vfs_wapbl.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/kern/vfs_wapbl.c Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vfs_wapbl.c,v 1.99 2017/10/27 09:59:16 utkarsh009 Exp $ */
+/* $NetBSD: vfs_wapbl.c,v 1.100 2017/10/27 12:25:15 joerg Exp $ */
/*-
* Copyright (c) 2003, 2008, 2009 The NetBSD Foundation, Inc.
@@ -36,7 +36,7 @@
#define WAPBL_INTERNAL
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vfs_wapbl.c,v 1.99 2017/10/27 09:59:16 utkarsh009 Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vfs_wapbl.c,v 1.100 2017/10/27 12:25:15 joerg Exp $");
#include <sys/param.h>
#include <sys/bitops.h>
@@ -2167,7 +2167,7 @@
#endif
if (!wl)
return;
- wapbl_print(wl, 1, (void *)printf);
+ wapbl_print(wl, 1, printf);
}
#endif
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/sys/systm.h
--- a/sys/sys/systm.h Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/sys/systm.h Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: systm.h,v 1.273 2017/10/27 09:59:17 utkarsh009 Exp $ */
+/* $NetBSD: systm.h,v 1.274 2017/10/27 12:25:15 joerg Exp $ */
/*-
* Copyright (c) 1982, 1988, 1991, 1993
@@ -221,7 +221,7 @@
void printf_nolog(const char *, ...) __printflike(1, 2);
-int printf(const char *, ...) __printflike(1, 2);
+void printf(const char *, ...) __printflike(1, 2);
int snprintf(char *, size_t, const char *, ...) __printflike(3, 4);
diff -r e3c90ef7bcce -r 4c291ce6d2e9 sys/ufs/ufs/ufs_lookup.c
--- a/sys/ufs/ufs/ufs_lookup.c Fri Oct 27 12:01:08 2017 +0000
+++ b/sys/ufs/ufs/ufs_lookup.c Fri Oct 27 12:25:14 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ufs_lookup.c,v 1.147 2017/10/27 09:59:17 utkarsh009 Exp $ */
+/* $NetBSD: ufs_lookup.c,v 1.148 2017/10/27 12:25:15 joerg Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -37,7 +37,7 @@
*/
Home |
Main Index |
Thread Index |
Old Index