Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/usb #ifdef some variables just like their use
details: https://anonhg.NetBSD.org/src/rev/56669647eb60
branches: trunk
changeset: 789920:56669647eb60
user: martin <martin%NetBSD.org@localhost>
date: Thu Sep 12 21:03:11 2013 +0000
description:
#ifdef some variables just like their use
diffstat:
sys/dev/usb/if_axe.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diffs (44 lines):
diff -r 09b004ea54a6 -r 56669647eb60 sys/dev/usb/if_axe.c
--- a/sys/dev/usb/if_axe.c Thu Sep 12 20:47:59 2013 +0000
+++ b/sys/dev/usb/if_axe.c Thu Sep 12 21:03:11 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: if_axe.c,v 1.64 2013/01/22 12:40:42 jmcneill Exp $ */
+/* $NetBSD: if_axe.c,v 1.65 2013/09/12 21:03:11 martin Exp $ */
/* $OpenBSD: if_axe.c,v 1.96 2010/01/09 05:33:08 jsg Exp $ */
/*
@@ -89,7 +89,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1.64 2013/01/22 12:40:42 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1.65 2013/09/12 21:03:11 martin Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -464,7 +464,9 @@
static void
axe_ax88178_init(struct axe_softc *sc)
{
+#ifdef AXE_DEBUG
int gpio0 = 0, phymode = 0;
+#endif
uint16_t eeprom;
axe_cmd(sc, AXE_CMD_SROM_WR_ENABLE, 0, 0, NULL);
@@ -477,6 +479,7 @@
DPRINTF((" EEPROM is 0x%x\n", eeprom));
/* if EEPROM is invalid we have to use to GPIO0 */
+#ifdef AXE_DEBUG
if (eeprom == 0xffff) {
phymode = 0;
gpio0 = 1;
@@ -484,6 +487,7 @@
phymode = eeprom & 7;
gpio0 = (eeprom & 0x80) ? 0 : 1;
}
+#endif
DPRINTF(("use gpio0: %d, phymode %d\n", gpio0, phymode));
Home |
Main Index |
Thread Index |
Old Index