Subject: None
To: None <gnats-bugs@NetBSD.org>
From: jason downs <downsj@CSOS.ORST.EDU>
List: port-hp300
Date: 09/13/1994 18:52:26
>Submitter-Id: net
>Originator:
>Organization:
Computer Science Outreach Services, Oregon State University
>Confidential: no
>Synopsis: USELEDS does not compile, ethernet not fully supported
>Severity: serious
>Priority: medium
>Category: port-hp300
>Class: sw-bug
>Release: NetBSD 1.0_BETA-current
>Environment:
System: NetBSD nemesis 1.0_BETA NetBSD 1.0_BETA (NEMESIS) #9: Wed Sep 7 13:33:55 PDT 1994 downsj@nemesis:/usr/src/sys/arch/hp300/compile/NEMESIS hp300
>Description:
a. the USELEDS (documented) kernel option does not even compile.
b. the ethernet driver does not use the leds once USELEDS works.
>How-To-Repeat:
compile a kernel with the USELEDS option.
>Fix:
The following patches have been tested on a 433S. The blinkey
lights look a little more like the machine is alive, now.
(from /sys/arch/hp300:)
*** hp300/led.h.orig Sun May 22 23:14:54 1994
--- hp300/led.h Tue Sep 13 17:03:45 1994
***************
*** 48,54 ****
#define LED_DISK 0x20 /* for disk activity */
#define LED_PULSE 0x10 /* heartbeat */
! #ifdef KERNEL
extern char *ledaddr;
extern int inledcontrol;
#endif
--- 48,54 ----
#define LED_DISK 0x20 /* for disk activity */
#define LED_PULSE 0x10 /* heartbeat */
! #if defined(KERNEL) && !defined(LOCORE)
extern char *ledaddr;
extern int inledcontrol;
#endif
*** hp300/locore.s.orig Thu Jul 7 01:23:58 1994
--- hp300/locore.s Tue Sep 13 18:49:02 1994
***************
*** 480,485 ****
--- 480,489 ----
moveq #T_TRACE,d0
jra fault
+ #ifdef USELEDS
+ #include <hp300/hp300/led.h>
+ #endif
+
/*
* The sigreturn() syscall comes here. It requires special handling
* because we must open a hole in the stack to fill in the (possibly much
*** dev/if_le.c.orig Wed Jul 27 01:19:05 1994
--- dev/if_le.c Tue Sep 13 18:30:33 1994
***************
*** 81,86 ****
--- 81,89 ----
#include <hp300/dev/device.h>
#include <hp300/dev/if_lereg.h>
+ #ifdef USELEDS
+ #include <hp300/hp300/led.h>
+ #endif
#define ETHER_MIN_LEN 64
#define ETHER_MAX_LEN 1518
***************
*** 578,583 ****
--- 581,591 ----
register int tmd = (sc->sc_last_td - sc->sc_no_td + NTBUF) % NTBUF;
struct mds *cdm = &sc->sc_td[tmd];
+ #ifdef USELEDS
+ if (inledcontrol == 0)
+ ledcontrol(0, 0, LED_LANXMT);
+ #endif
+
if (cdm->flags & LE_OWN) {
/* Race condition with loop below. */
#ifdef LEDEBUG
***************
*** 642,647 ****
--- 650,660 ----
register struct le_softc *sc = &le_softc[unit];
register int rmd = sc->sc_last_rd;
struct mds *cdm = &sc->sc_rd[rmd];
+
+ #ifdef USELEDS
+ if (inledcontrol == 0)
+ ledcontrol(0, 0, LED_LANRCV);
+ #endif
if (cdm->flags & LE_OWN) {
/* Race condition with loop below. */