Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/ic Put helper functions for debugging under the corr...



details:   https://anonhg.NetBSD.org/src/rev/1e6123e3d0cb
branches:  trunk
changeset: 789969:1e6123e3d0cb
user:      joerg <joerg%NetBSD.org@localhost>
date:      Sat Sep 14 13:09:18 2013 +0000

description:
Put helper functions for debugging under the corresponding debug
options.

diffstat:

 sys/dev/ic/hd64570.c  |  8 ++++++--
 sys/dev/ic/rtwphyio.c |  6 ++++--
 2 files changed, 10 insertions(+), 4 deletions(-)

diffs (84 lines):

diff -r f30234567740 -r 1e6123e3d0cb sys/dev/ic/hd64570.c
--- a/sys/dev/ic/hd64570.c      Sat Sep 14 13:08:31 2013 +0000
+++ b/sys/dev/ic/hd64570.c      Sat Sep 14 13:09:18 2013 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: hd64570.c,v 1.44 2013/03/01 18:25:55 joerg Exp $       */
+/*     $NetBSD: hd64570.c,v 1.45 2013/09/14 13:09:18 joerg Exp $       */
 
 /*
  * Copyright (c) 1999 Christian E. Hopps
@@ -65,7 +65,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: hd64570.c,v 1.44 2013/03/01 18:25:55 joerg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: hd64570.c,v 1.45 2013/09/14 13:09:18 joerg Exp $");
 
 #include "opt_inet.h"
 
@@ -215,6 +215,7 @@
        return sca_read_2(scp->sca, scp->dmac_off + reg);
 }
 
+#if SCA_DEBUG_LEVEL > 0
 /*
  * read the chain pointer
  */
@@ -226,6 +227,7 @@
        return (bus_space_read_2(sc->scu_memt, sc->scu_memh,
            sca_page_addr(sc, dp) + offsetof(struct sca_desc, sd_chainp)));
 }
+#endif
 
 /*
  * write the chain pointer
@@ -241,6 +243,7 @@
                    + offsetof(struct sca_desc, sd_chainp), cp);
 }
 
+#if SCA_DEBUG_LEVEL > 0
 /*
  * read the buffer pointer
  */
@@ -260,6 +263,7 @@
        }
        return (address);
 }
+#endif
 
 /*
  * write the buffer pointer
diff -r f30234567740 -r 1e6123e3d0cb sys/dev/ic/rtwphyio.c
--- a/sys/dev/ic/rtwphyio.c     Sat Sep 14 13:08:31 2013 +0000
+++ b/sys/dev/ic/rtwphyio.c     Sat Sep 14 13:09:18 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rtwphyio.c,v 1.17 2009/10/19 23:19:39 rmind Exp $ */
+/* $NetBSD: rtwphyio.c,v 1.18 2013/09/14 13:09:18 joerg Exp $ */
 /*-
  * Copyright (c) 2004, 2005 David Young.  All rights reserved.
  *
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rtwphyio.c,v 1.17 2009/10/19 23:19:39 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rtwphyio.c,v 1.18 2013/09/14 13:09:18 joerg Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -224,6 +224,7 @@
 #undef EXTRACT_NIBBLE
 }
 
+#ifdef RTW_DEBUG
 static inline const char *
 rtw_rfchipid_string(enum rtw_rfchipid rfchipid)
 {
@@ -242,6 +243,7 @@
                return "unknown";
        }
 }
+#endif
 
 /* Bang bits over the 3-wire interface. */
 int



Home | Main Index | Thread Index | Old Index