diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2004-10-13 22:49:25 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2004-10-13 22:49:25 +0000 |
commit | 8a5e40cfb633ac6ce6737691a77db6d5db661ac8 (patch) | |
tree | ee85a1437fd6d18c4de9bbb8d09486db13e56e44 /sys/dev/ic | |
parent | 1843b0af29c4edc6915d063a3365d73e7bce2965 (diff) |
Let the generic rtl code work if the bus-dependent code has decided to attach;
this lets the 8138-based cardbus devices to really attach.
8138-specific mii differences will need to be investigated; right now,
recognizing the 8138 as either 8139 or non-8139 causes it to lose the link
after a while, but nothing ifconfig can not reset...
From a discussion with and tested by BenoƮt Izac, who owns a 8138-based
cardbus device.
Diffstat (limited to 'sys/dev/ic')
-rw-r--r-- | sys/dev/ic/rtl81x9.c | 9 | ||||
-rw-r--r-- | sys/dev/ic/rtl81x9reg.h | 3 |
2 files changed, 5 insertions, 7 deletions
diff --git a/sys/dev/ic/rtl81x9.c b/sys/dev/ic/rtl81x9.c index 2d3df729908..131b53fca84 100644 --- a/sys/dev/ic/rtl81x9.c +++ b/sys/dev/ic/rtl81x9.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rtl81x9.c,v 1.33 2004/09/30 17:59:23 jason Exp $ */ +/* $OpenBSD: rtl81x9.c,v 1.34 2004/10/13 22:49:24 miod Exp $ */ /* * Copyright (c) 1997, 1998 @@ -1237,11 +1237,8 @@ rl_attach(sc) sc->rl_type = RL_8139; else if (rl_did == RT_DEVICEID_8129) sc->rl_type = RL_8129; - else { - printf("\n%s: unknown device id: %x\n", sc->sc_dev.dv_xname, - rl_did); - return (1); - } + else + sc->rl_type = RL_UNKNOWN; /* could be 8138 or other */ if (bus_dmamem_alloc(sc->sc_dmat, RL_RXBUFLEN + 32, PAGE_SIZE, 0, &sc->sc_rx_seg, 1, &rseg, BUS_DMA_NOWAIT)) { diff --git a/sys/dev/ic/rtl81x9reg.h b/sys/dev/ic/rtl81x9reg.h index 71de50c4d9b..c2e7e0e47c0 100644 --- a/sys/dev/ic/rtl81x9reg.h +++ b/sys/dev/ic/rtl81x9reg.h @@ -1,4 +1,4 @@ -/* $OpenBSD: rtl81x9reg.h,v 1.16 2004/09/30 17:37:54 jason Exp $ */ +/* $OpenBSD: rtl81x9reg.h,v 1.17 2004/10/13 22:49:24 miod Exp $ */ /* * Copyright (c) 1997, 1998 @@ -610,6 +610,7 @@ struct rl_mii_frame { #define RL_MII_WRITEOP 0x01 #define RL_MII_TURNAROUND 0x02 +#define RL_UNKNOWN 0 #define RL_8129 1 #define RL_8139 2 #define RL_8139CPLUS 3 |