Source-Changes-HG archive

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

[src/trunk]: src/sys Replace more printfs with aprint_normal / aprint_verbose



details:   https://anonhg.NetBSD.org/src/rev/721ea5e8c9ed
branches:  trunk
changeset: 751273:721ea5e8c9ed
user:      hubertf <hubertf%NetBSD.org@localhost>
date:      Sun Jan 31 00:43:37 2010 +0000

description:
Replace more printfs with aprint_normal / aprint_verbose
Makes "boot -z" go mostly silent for me.

diffstat:

 sys/arch/x86/x86/pmap.c         |   6 +++---
 sys/arch/x86/x86/x86_autoconf.c |   8 ++++----
 sys/dev/pci/agp_via.c           |  10 +++++-----
 sys/kern/cnmagic.c              |   6 +++---
 sys/kern/init_main.c            |   8 ++++----
 sys/kern/kern_ksyms.c           |   6 +++---
 sys/netipsec/ipsec.c            |   8 ++++----
 sys/netipsec/key.c              |   6 +++---
 sys/netkey/key.c                |   6 +++---
 9 files changed, 32 insertions(+), 32 deletions(-)

diffs (274 lines):

diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/arch/x86/x86/pmap.c
--- a/sys/arch/x86/x86/pmap.c   Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/arch/x86/x86/pmap.c   Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pmap.c,v 1.99 2010/01/10 12:10:23 jym Exp $    */
+/*     $NetBSD: pmap.c,v 1.100 2010/01/31 00:43:37 hubertf Exp $       */
 
 /*
  * Copyright (c) 2007 Manuel Bouyer.
@@ -149,7 +149,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.99 2010/01/10 12:10:23 jym Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.100 2010/01/31 00:43:37 hubertf Exp $");
 
 #include "opt_user_ldt.h"
 #include "opt_lockdebug.h"
@@ -1380,7 +1380,7 @@
                        tlbflush();
                }
 #if defined(DEBUG)
-               printf("kernel text is mapped with "
+               aprint_normal("kernel text is mapped with "
                    "%lu large pages and %lu normal pages\n",
                    (unsigned long)howmany(kva - KERNBASE, NBPD_L2),
                    (unsigned long)howmany((vaddr_t)&__data_start - kva,
diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/arch/x86/x86/x86_autoconf.c
--- a/sys/arch/x86/x86/x86_autoconf.c   Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/arch/x86/x86/x86_autoconf.c   Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: x86_autoconf.c,v 1.48 2010/01/08 19:43:26 dyoung Exp $ */
+/*     $NetBSD: x86_autoconf.c,v 1.49 2010/01/31 00:43:37 hubertf Exp $        */
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: x86_autoconf.c,v 1.48 2010/01/08 19:43:26 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: x86_autoconf.c,v 1.49 2010/01/31 00:43:37 hubertf Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -554,11 +554,11 @@
 
        if (booted_wedge) {
                KASSERT(booted_device != NULL);
-               printf("boot device: %s (%s)\n",
+               aprint_normal("boot device: %s (%s)\n",
                    device_xname(booted_wedge), device_xname(booted_device));
                setroot(booted_wedge, 0);
        } else {
-               printf("boot device: %s\n",
+               aprint_normal("boot device: %s\n",
                    booted_device ? device_xname(booted_device) : "<unknown>");
                setroot(booted_device, booted_partition);
        }
diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/dev/pci/agp_via.c
--- a/sys/dev/pci/agp_via.c     Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/dev/pci/agp_via.c     Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: agp_via.c,v 1.17 2008/06/09 06:49:54 freza Exp $       */
+/*     $NetBSD: agp_via.c,v 1.18 2010/01/31 00:43:37 hubertf Exp $     */
 
 /*-
  * Copyright (c) 2000 Doug Rabson
@@ -29,7 +29,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: agp_via.c,v 1.17 2008/06/09 06:49:54 freza Exp $");
+__KERNEL_RCSID(0, "$NetBSD: agp_via.c,v 1.18 2010/01/31 00:43:37 hubertf Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -107,14 +107,14 @@
                agpsel = pci_conf_read(pa->pa_pc, pa->pa_tag, AGP_VIA_AGPSEL);
                if ((agpsel & (1 << 9)) == 0) {
                        asc->regs = via_v3_regs;
-                       printf(" (v3)");
+                       aprint_normal(" (v3)");
                } else {
                        asc->regs = via_v2_regs;
-                       printf(" (v2 compat mode)");
+                       aprint_normal(" (v2 compat mode)");
                }
        } else {
                asc->regs = via_v2_regs;
-               printf(" (v2)");
+               aprint_normal(" (v2)");
        }
 
        if (agp_map_aperture(pa, sc, AGP_APBASE) != 0) {
diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/kern/cnmagic.c
--- a/sys/kern/cnmagic.c        Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/kern/cnmagic.c        Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: cnmagic.c,v 1.10 2009/10/19 18:12:37 snj Exp $ */
+/*     $NetBSD: cnmagic.c,v 1.11 2010/01/31 00:43:37 hubertf Exp $     */
 
 /*
  * Copyright (c) 2000 Eduardo Horvath
@@ -26,7 +26,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cnmagic.c,v 1.10 2009/10/19 18:12:37 snj Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cnmagic.c,v 1.11 2010/01/31 00:43:37 hubertf Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -105,7 +105,7 @@
                        /* Transition to the next state. */
 #ifdef DEBUG
                        if (!cold)
-                               printf("mag %d %x:%x\n", i, c, n);
+                               aprint_normal("mag %d %x:%x\n", i, c, n);
 #endif
                        m[i] = ENCODE_STATE(c, n);
                        break;
diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/kern/init_main.c
--- a/sys/kern/init_main.c      Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/kern/init_main.c      Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: init_main.c,v 1.414 2010/01/19 22:08:00 pooka Exp $    */
+/*     $NetBSD: init_main.c,v 1.415 2010/01/31 00:43:37 hubertf 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.414 2010/01/19 22:08:00 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: init_main.c,v 1.415 2010/01/31 00:43:37 hubertf Exp $");
 
 #include "opt_ddb.h"
 #include "opt_ipsec.h"
@@ -937,7 +937,7 @@
                        *flagsp++ = '\0';
                        i = flagsp - flags;
 #ifdef DEBUG
-                       printf("init: copying out flags `%s' %d\n", flags, i);
+                       aprint_normal("init: copying out flags `%s' %d\n", flags, i);
 #endif
                        arg1 = STACK_ALLOC(ucp, i);
                        ucp = STACK_MAX(arg1, i);
@@ -949,7 +949,7 @@
                 */
                i = strlen(path) + 1;
 #ifdef DEBUG
-               printf("init: copying out path `%s' %d\n", path, i);
+               aprint_normal("init: copying out path `%s' %d\n", path, i);
 #else
                if (boothowto & RB_ASKNAME || path != initpaths[0])
                        printf("init: trying %s\n", path);
diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/kern/kern_ksyms.c
--- a/sys/kern/kern_ksyms.c     Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/kern/kern_ksyms.c     Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kern_ksyms.c,v 1.52 2009/11/25 13:16:55 pooka Exp $    */
+/*     $NetBSD: kern_ksyms.c,v 1.53 2010/01/31 00:43:37 hubertf Exp $  */
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -71,7 +71,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_ksyms.c,v 1.52 2009/11/25 13:16:55 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_ksyms.c,v 1.53 2010/01/31 00:43:37 hubertf Exp $");
 
 #if defined(_KERNEL) && defined(_KERNEL_OPT)
 #include "opt_ddb.h"
@@ -403,7 +403,7 @@
            &kernel_symtab, start);
 
 #ifdef DEBUG
-       printf("Loaded initial symtab at %p, strtab at %p, # entries %ld\n",
+       aprint_normal("Loaded initial symtab at %p, strtab at %p, # entries %ld\n",
            kernel_symtab.sd_symstart, kernel_symtab.sd_strstart,
            (long)kernel_symtab.sd_symsize/sizeof(Elf_Sym));
 #endif
diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/netipsec/ipsec.c
--- a/sys/netipsec/ipsec.c      Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/netipsec/ipsec.c      Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ipsec.c,v 1.46 2009/07/30 14:41:59 jakllsch Exp $      */
+/*     $NetBSD: ipsec.c,v 1.47 2010/01/31 00:43:38 hubertf Exp $       */
 /*     $FreeBSD: /usr/local/www/cvsroot/FreeBSD/src/sys/netipsec/ipsec.c,v 1.2.2.2 2003/07/01 01:38:13 sam Exp $       */
 /*     $KAME: ipsec.c,v 1.103 2001/05/24 07:14:18 sakane Exp $ */
 
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ipsec.c,v 1.46 2009/07/30 14:41:59 jakllsch Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ipsec.c,v 1.47 2010/01/31 00:43:38 hubertf Exp $");
 
 /*
  * IPsec controller part.
@@ -2280,7 +2280,7 @@
 
        ipsecstat_percpu = percpu_alloc(sizeof(uint64_t) * IPSEC_NSTATS);
 
-       printf("initializing IPsec...");
+       aprint_verbose("initializing IPsec...");
        ah_attach();
        esp_attach();
        ipcomp_attach();
@@ -2288,6 +2288,6 @@
 #ifdef TCP_SIGNATURE
        tcpsignature_attach();
 #endif
-       printf(" done\n");
+       aprint_verbose(" done\n");
 }
 #endif /* __NetBSD__ */
diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/netipsec/key.c
--- a/sys/netipsec/key.c        Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/netipsec/key.c        Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: key.c,v 1.62 2009/03/18 15:14:32 cegger Exp $  */
+/*     $NetBSD: key.c,v 1.63 2010/01/31 00:43:38 hubertf Exp $ */
 /*     $FreeBSD: src/sys/netipsec/key.c,v 1.3.2.3 2004/02/14 22:23:23 bms Exp $        */
 /*     $KAME: key.c,v 1.191 2001/06/27 10:46:49 sakane Exp $   */
        
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: key.c,v 1.62 2009/03/18 15:14:32 cegger Exp $");
+__KERNEL_RCSID(0, "$NetBSD: key.c,v 1.63 2010/01/31 00:43:38 hubertf Exp $");
 
 /*
  * This code is referd to RFC 2367
@@ -7676,7 +7676,7 @@
        /* initialize key statistics */
        keystat.getspi_count = 1;
 
-       printf("IPsec: Initialized Security Association Processing.\n");
+       aprint_verbose("IPsec: Initialized Security Association Processing.\n");
 
        return (0);
 }
diff -r aa6cce1334b5 -r 721ea5e8c9ed sys/netkey/key.c
--- a/sys/netkey/key.c  Sun Jan 31 00:38:36 2010 +0000
+++ b/sys/netkey/key.c  Sun Jan 31 00:43:37 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: key.c,v 1.175 2009/05/11 11:00:51 skd Exp $    */
+/*     $NetBSD: key.c,v 1.176 2010/01/31 00:43:37 hubertf Exp $        */
 /*     $KAME: key.c,v 1.310 2003/09/08 02:23:44 itojun Exp $   */
 
 /*
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: key.c,v 1.175 2009/05/11 11:00:51 skd Exp $");
+__KERNEL_RCSID(0, "$NetBSD: key.c,v 1.176 2010/01/31 00:43:37 hubertf Exp $");
 
 #include "opt_inet.h"
 #include "opt_ipsec.h"
@@ -7909,7 +7909,7 @@
        /* initialize key statistics */
        keystat.getspi_count = 1;
 
-       printf("IPsec: Initialized Security Association Processing.\n");
+       aprint_verbose("IPsec: Initialized Security Association Processing.\n");
 
        return (0);
 }



Home | Main Index | Thread Index | Old Index