Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/sparc64/dev The FFB interrupt mapping registers nee...



details:   https://anonhg.NetBSD.org/src/rev/c164de119d6d
branches:  trunk
changeset: 533098:c164de119d6d
user:      eeh <eeh%NetBSD.org@localhost>
date:      Fri Jun 21 02:48:42 2002 +0000

description:
The FFB interrupt mapping registers need to compare IGN as well as INO since
they are totally programmable.

diffstat:

 sys/arch/sparc64/dev/psycho.c |  15 +++++++++++++--
 1 files changed, 13 insertions(+), 2 deletions(-)

diffs (43 lines):

diff -r 52e635bb6123 -r c164de119d6d sys/arch/sparc64/dev/psycho.c
--- a/sys/arch/sparc64/dev/psycho.c     Fri Jun 21 02:36:00 2002 +0000
+++ b/sys/arch/sparc64/dev/psycho.c     Fri Jun 21 02:48:42 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: psycho.c,v 1.50 2002/06/20 18:26:24 eeh Exp $  */
+/*     $NetBSD: psycho.c,v 1.51 2002/06/21 02:48:42 eeh Exp $  */
 
 /*
  * Copyright (c) 2001, 2002 Eduardo E. Horvath
@@ -490,6 +490,7 @@
                /* Point the strbuf_ctl at the iommu_state */
                pp->pp_sb.sb_is = sc->sc_is;
 
+               sc->sc_is->is_sb[0] = sc->sc_is->is_sb[1] = NULL;
                if (PROM_getproplen(sc->sc_node, "no-streaming-cache") < 0) {
                        struct strbuf_ctl *sb = &pp->pp_sb;
                        vaddr_t va = (vaddr_t)&pp->pp_flush[0x40];
@@ -1050,7 +1051,7 @@
                /* Hunt thru obio first */
                for (intrmapptr = &sc->sc_regs->scsi_int_map,
                             intrclrptr = &sc->sc_regs->scsi_clr_int;
-                    intrmapptr <= &sc->sc_regs->ffb1_int_map;
+                    intrmapptr < &sc->sc_regs->ffb0_int_map;
                     intrmapptr++, intrclrptr++) {
                        if (INTINO(*intrmapptr) == ino)
                                goto found;
@@ -1066,6 +1067,16 @@
                                goto found;
                        }
                }
+
+               /* Finally check the two FFB slots */
+               intrclrptr = NULL; /* XXX? */
+               for (intrmapptr = &sc->sc_regs->ffb0_int_map;
+                    intrmapptr <= &sc->sc_regs->ffb1_int_map;
+                    intrmapptr++) {
+                       if (INTVEC(*intrmapptr) == ino)
+                               goto found;
+               }
+
                printf("Cannot find interrupt vector %lx\n", vec);
                return (NULL);
 



Home | Main Index | Thread Index | Old Index