Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/amiga/dev Workaround for the fake X-Surf autoconfig...
details: https://anonhg.NetBSD.org/src/rev/63c2cf65a099
branches: trunk
changeset: 778713:63c2cf65a099
user: rkujawa <rkujawa%NetBSD.org@localhost>
date: Mon Apr 09 19:55:00 2012 +0000
description:
Workaround for the fake X-Surf autoconfig entry, created by the Deneb firmware v11.
diffstat:
sys/arch/amiga/dev/if_ne_zbus.c | 17 +++++++++++++----
1 files changed, 13 insertions(+), 4 deletions(-)
diffs (45 lines):
diff -r 0799511b82f5 -r 63c2cf65a099 sys/arch/amiga/dev/if_ne_zbus.c
--- a/sys/arch/amiga/dev/if_ne_zbus.c Mon Apr 09 19:42:06 2012 +0000
+++ b/sys/arch/amiga/dev/if_ne_zbus.c Mon Apr 09 19:55:00 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: if_ne_zbus.c,v 1.14 2011/07/19 15:55:27 dyoung Exp $ */
+/* $NetBSD: if_ne_zbus.c,v 1.15 2012/04/09 19:55:00 rkujawa Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_ne_zbus.c,v 1.14 2011/07/19 15:55:27 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_ne_zbus.c,v 1.15 2012/04/09 19:55:00 rkujawa Exp $");
/*
* Thanks to Village Tronic for giving me a card.
@@ -86,6 +86,13 @@
#define NE_ARIADNE_II_ASICBASE 0x0310 /* 0x0620 */
#define NE_ARIADNE_II_ASICSIZE 0x10
+/*
+ * E3B Deneb firmware v11 creates fake X-Surf autoconfig entry.
+ * Do not attach ne driver to this fake card, otherwise kernel panic
+ * may occur.
+ */
+#define DENEB_XSURF_SERNO 0xC0FFEE01 /* Serial of the fake card */
+
int
ne_zbus_match(device_t parent, cfdata_t cf, void *aux)
{
@@ -96,8 +103,10 @@
return (1);
/* X-surf ethernet card */
- if (zap->manid == 4626 && zap->prodid == 23)
- return (1);
+ if (zap->manid == 4626 && zap->prodid == 23) {
+ if (zap->serno != DENEB_XSURF_SERNO)
+ return (1);
+ }
return (0);
}
Home |
Main Index |
Thread Index |
Old Index