Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/x86/x86 use DPRINTF instead of #define INTRDEBUG an...



details:   https://anonhg.NetBSD.org/src/rev/76f99dbe809d
branches:  trunk
changeset: 823290:76f99dbe809d
user:      knakahara <knakahara%NetBSD.org@localhost>
date:      Tue Apr 18 11:44:37 2017 +0000

description:
use DPRINTF instead of #define INTRDEBUG and printf().

diffstat:

 sys/arch/x86/x86/intr.c |  16 ++++++----------
 1 files changed, 6 insertions(+), 10 deletions(-)

diffs (47 lines):

diff -r 1388204de550 -r 76f99dbe809d sys/arch/x86/x86/intr.c
--- a/sys/arch/x86/x86/intr.c   Tue Apr 18 11:35:34 2017 +0000
+++ b/sys/arch/x86/x86/intr.c   Tue Apr 18 11:44:37 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: intr.c,v 1.97 2017/03/19 22:19:05 riastradh Exp $      */
+/*     $NetBSD: intr.c,v 1.98 2017/04/18 11:44:37 knakahara 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.97 2017/03/19 22:19:05 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.98 2017/04/18 11:44:37 knakahara Exp $");
 
 #include "opt_intrdebug.h"
 #include "opt_multiprocessor.h"
@@ -1081,12 +1081,10 @@
        (*pic->pic_hwunmask)(pic, pin);
        mutex_exit(&cpu_lock);
 
-#ifdef INTRDEBUG
-       printf("allocated pic %s type %s pin %d level %d to %s slot %d "
+       DPRINTF(("allocated pic %s type %s pin %d level %d to %s slot %d "
            "idt entry %d\n",
            pic->pic_name, type == IST_EDGE ? "edge" : "level", pin, level,
-           device_xname(ci->ci_dev), slot, idt_vec);
-#endif
+           device_xname(ci->ci_dev), slot, idt_vec));
 
        return (ih);
 }
@@ -1168,11 +1166,9 @@
        /* If the source is free we can drop it now. */
        intr_source_free(ci, ih->ih_slot, pic, idtvec);
 
-#ifdef INTRDEBUG
-       printf("%s: remove slot %d (pic %s pin %d vec %d)\n",
+       DPRINTF(("%s: remove slot %d (pic %s pin %d vec %d)\n",
            device_xname(ci->ci_dev), ih->ih_slot, pic->pic_name,
-           ih->ih_pin, idtvec);
-#endif
+           ih->ih_pin, idtvec));
 }
 
 static int



Home | Main Index | Thread Index | Old Index