diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2012-05-28 17:03:37 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2012-05-28 17:03:37 +0000 |
commit | f7d37f7b04b87ce1b862155e780dd96ccc984618 (patch) | |
tree | 6d20f97d8f0e3bbea8de11968b32a597af3d4df8 /sys/arch | |
parent | f784c121c2d583beac63bb17fcd2e1c341d75633 (diff) |
The link state code does not work correctly on Indigo (IP20) and E++ GIO boards
and will report the link being down too aggressively. Better to always report
the link as up - these systems and boards are single media only so it won't
harm much.
Unbreaks dhcp in the installer on these interfaces; found the hard way by
sebastia@
Diffstat (limited to 'sys/arch')
-rw-r--r-- | sys/arch/sgi/hpc/if_sq.c | 10 | ||||
-rw-r--r-- | sys/arch/sgi/hpc/if_sqvar.h | 3 |
2 files changed, 9 insertions, 4 deletions
diff --git a/sys/arch/sgi/hpc/if_sq.c b/sys/arch/sgi/hpc/if_sq.c index df697555416..c760ac3dab4 100644 --- a/sys/arch/sgi/hpc/if_sq.c +++ b/sys/arch/sgi/hpc/if_sq.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_sq.c,v 1.7 2012/05/27 14:27:08 miod Exp $ */ +/* $OpenBSD: if_sq.c,v 1.8 2012/05/28 17:03:35 miod Exp $ */ /* $NetBSD: if_sq.c,v 1.42 2011/07/01 18:53:47 dyoung Exp $ */ /* @@ -441,12 +441,14 @@ sq_attach(struct device *parent, struct device *self, void *aux) } } else { /* - * HPC1/1.5: IP20 on-board, or E++: AUI connector only + * HPC1/1.5: IP20 on-board, or E++: AUI connector only, + * and career information unreliable. */ ifmedia_init(&sc->sc_ifmedia, 0, sq_ifmedia_change_singlemedia, sq_ifmedia_status_singlemedia); media = IFM_ETHER | IFM_10_5; + sc->sc_flags |= SQF_NOLINKDOWN; } ifmedia_add(&sc->sc_ifmedia, media, 0, NULL); @@ -1064,8 +1066,10 @@ sq_intr(void *arg) /* * Check for loss of carrier detected during transmission if we * can detect it. + * Unfortunately, this does not work on IP20 and E++ designs. */ - if (sc->sc_type == SQ_TYPE_80C03) { + if (sc->sc_type == SQ_TYPE_80C03 && + !ISSET(sc->sc_flags, SQF_NOLINKDOWN)) { sqe = sq_seeq_read(sc, SEEQ_SQE) & (SQE_FLAG | SQE_NOCARR); if (sqe != 0) { sq_seeq_write(sc, SEEQ_TXCMD, diff --git a/sys/arch/sgi/hpc/if_sqvar.h b/sys/arch/sgi/hpc/if_sqvar.h index 9bf5df1323b..9af015b2351 100644 --- a/sys/arch/sgi/hpc/if_sqvar.h +++ b/sys/arch/sgi/hpc/if_sqvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: if_sqvar.h,v 1.3 2012/05/27 14:27:08 miod Exp $ */ +/* $OpenBSD: if_sqvar.h,v 1.4 2012/05/28 17:03:36 miod Exp $ */ /* $NetBSD: sqvar.h,v 1.12 2011/01/25 13:12:39 tsutsui Exp $ */ /* @@ -118,6 +118,7 @@ struct sq_softc { int sc_type; int sc_flags; #define SQF_LINKUP 0x00000001 +#define SQF_NOLINKDOWN 0x00000002 struct sq_control* sc_control; #define sc_rxdesc sc_control->rx_desc |