from Rodney W. Grimes (rgrimes@agora.rain.com) (patchkit patch 117):

This patch adds the symbol names to icu.s that vmstat expects
the interrupt counters to be called.  It also adds code to config
so that the names of the interrupts are written at the end of vectors.s
so vmstat can report real device names.  It also cleans up and enables
the logging of stray interrupts.  The counters for false interrupts
are added but the fix for them is not (the fix I have is not done
very good.) A false interrupt is when a device asserts it's interrupt
signal, then removes it before the 8259 can latch it.  This is the number
one cause of stray IRQ7's and IRQ15's.

	Additional device probe information is now printed.  This includes
ending I/O address (many drivers do not return the correct value from a
probe this still needs to be fixed), memory address and size, driver
flags passed in by config.
This commit is contained in:
cgd 1993-04-09 13:27:46 +00:00
parent 0856d94781
commit 9dc3975ffe
4 changed files with 94 additions and 17 deletions

View File

@ -34,15 +34,6 @@
* SUCH DAMAGE.
*
* @(#)locore.s 7.3 (Berkeley) 5/13/91
*
* PATCHES MAGIC LEVEL PATCH THAT GOT US HERE
* -------------------- ----- ----------------------
* CURRENT PATCH LEVEL: 2 00064
* -------------------- ----- ----------------------
*
* 06 Aug 92 Pace Willisson Allow VGA memory to be mapped
* 28 Nov 92 Frank MacLachlan Aligned addresses and data
* on 32bit boundaries.
*/
@ -1584,6 +1575,7 @@ IDTVEC(syscall)
movw $0x10,%ax # switch to kernel segments
movw %ax,%ds
movw %ax,%es
incl _cnt+V_SYSCALL # kml 3/25/93
call _syscall
call _spl0
movw __udatasel,%ax # switch back to user segments

View File

@ -35,14 +35,6 @@
* SUCH DAMAGE.
*
* @(#)icu.s 7.2 (Berkeley) 5/21/91
*
* PATCHES MAGIC LEVEL PATCH THAT GOT US HERE
* -------------------- ----- ----------------------
* CURRENT PATCH LEVEL: 1 00064
* -------------------- ----- ----------------------
*
* 28 Nov 92 Frank MacLachlan Aligned addresses and data
* on 32bit boundaries.
*/
/*
@ -65,7 +57,22 @@ _biomask: .long 0
.globl _netmask
_netmask: .long 0
.globl _isa_intr
/*
* This is the names of the counters for vmstat added by
* rgrimes@agora.rain.com (Rodney W. Grimes) 10/30/1992
* Added false and stray counters 3/25/1993 rgrimes
*/
.globl _intrcnt, _eintrcnt /* Added to make vmstat happy */
.globl _isa_false7_intrcnt, _isa_false15_intrcnt, _isa_stray_intrcnt
_intrcnt: /* Added to make vmstat happy */
_isa_false7_intrcnt:
.space 4 /* false IRQ7's */
_isa_false15_intrcnt:
.space 4 /* false IRQ15's */
_isa_stray_intrcnt:
.space 4 /* stray interrupts */
_isa_intr: .space 16*4
_eintrcnt: /* Added to make vmstat happy */
.text
/*

View File

@ -395,5 +395,44 @@ VEC(clk)\n\
}
}
}
/*
* This is to output the names of the interrupts for vmstat
* added by rgrimes@agora.rain.com (Rodney W. Grimes) 10/30/1992
* Added false and stray interrupt counter names 3/25/93 rwgrimes
*/
fprintf(fp,"\
/* These are the names of the interupt vector counters */\n\n\
.text\n\
.globl _intrnames,_eintrnames\n\
_intrnames:\n\
.asciz \"false7\"\n\
.asciz \"false15\"\n\
.asciz \"stray\"\n\
.asciz \"clk\"\n");
count=0;
for (dp = dtab; dp != 0; dp = dp->d_next) {
mp = dp->d_conn;
if (mp != 0 && /* mp != (struct device *)-1 &&*/
eq(mp->d_name, "isa")) {
struct idlst *id, *id2;
for (id = dp->d_vec; id; id = id->id_next) {
for (id2 = dp->d_vec; id2; id2 = id2->id_next) {
if (id2 == id) {
if(dp->d_irq == -1) continue;
fprintf(fp,"\t.asciz\t\"%s%d\"\n",
dp->d_name, dp->d_unit);
count++;
break;
}
if (!strcmp(id->id, id2->id))
break;
}
}
}
}
fprintf(fp,"_eintrnames:\n\n\n");
(void) fclose(fp);
}

View File

@ -395,5 +395,44 @@ VEC(clk)\n\
}
}
}
/*
* This is to output the names of the interrupts for vmstat
* added by rgrimes@agora.rain.com (Rodney W. Grimes) 10/30/1992
* Added false and stray interrupt counter names 3/25/93 rwgrimes
*/
fprintf(fp,"\
/* These are the names of the interupt vector counters */\n\n\
.text\n\
.globl _intrnames,_eintrnames\n\
_intrnames:\n\
.asciz \"false7\"\n\
.asciz \"false15\"\n\
.asciz \"stray\"\n\
.asciz \"clk\"\n");
count=0;
for (dp = dtab; dp != 0; dp = dp->d_next) {
mp = dp->d_conn;
if (mp != 0 && /* mp != (struct device *)-1 &&*/
eq(mp->d_name, "isa")) {
struct idlst *id, *id2;
for (id = dp->d_vec; id; id = id->id_next) {
for (id2 = dp->d_vec; id2; id2 = id2->id_next) {
if (id2 == id) {
if(dp->d_irq == -1) continue;
fprintf(fp,"\t.asciz\t\"%s%d\"\n",
dp->d_name, dp->d_unit);
count++;
break;
}
if (!strcmp(id->id, id2->id))
break;
}
}
}
}
fprintf(fp,"_eintrnames:\n\n\n");
(void) fclose(fp);
}