Source-Changes-HG archive

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

[src/netbsd-8]: src/sys/arch/hp300/hp300 Pull up following revision(s) (reque...



details:   https://anonhg.NetBSD.org/src/rev/8b3613b7cf9c
branches:  netbsd-8
changeset: 852423:8b3613b7cf9c
user:      martin <martin%NetBSD.org@localhost>
date:      Mon Jul 08 16:28:36 2019 +0000

description:
Pull up following revision(s) (requested by tsutsui in ticket #1284):

        sys/arch/hp300/hp300/autoconf.c: revision 1.106

Handle sti(4) graphics at sgc on HP9000/425t properly.  PR port-hp300/54255

Should be pulled up to netbsd-8.

diffstat:

 sys/arch/hp300/hp300/autoconf.c |  22 +++++++++++++++-------
 1 files changed, 15 insertions(+), 7 deletions(-)

diffs (68 lines):

diff -r f1fdeb930ebf -r 8b3613b7cf9c sys/arch/hp300/hp300/autoconf.c
--- a/sys/arch/hp300/hp300/autoconf.c   Sun Jun 30 19:00:38 2019 +0000
+++ b/sys/arch/hp300/hp300/autoconf.c   Mon Jul 08 16:28:36 2019 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: autoconf.c,v 1.105 2014/04/20 04:12:54 tsutsui Exp $   */
+/*     $NetBSD: autoconf.c,v 1.105.20.1 2019/07/08 16:28:36 martin Exp $       */
 
 /*-
  * Copyright (c) 1996, 1997, 2002 The NetBSD Foundation, Inc.
@@ -88,7 +88,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: autoconf.c,v 1.105 2014/04/20 04:12:54 tsutsui Exp $");
+__KERNEL_RCSID(0, "$NetBSD: autoconf.c,v 1.105.20.1 2019/07/08 16:28:36 martin Exp $");
 
 #include "dvbox.h"
 #include "gbox.h"
@@ -152,6 +152,7 @@
 #endif
 
 #if NSTI_SGC > 0
+#include <hp300/dev/sgcreg.h>
 #include <hp300/dev/sgcvar.h>
 #include <hp300/dev/sti_sgcvar.h>
 #endif
@@ -751,6 +752,9 @@
 void *conaddr;
 
 static bool cninit_deferred;
+#if NSTI_SGC > 0
+static int consslot = -1;
+#endif
 
 void
 hp300_cninit(void)
@@ -838,13 +842,18 @@
            machineid == HP_433) {
                struct bus_space_tag sgc_tag;
                bus_space_tag_t sgc_bst;
+               u_int slot;
 
                sgc_bst = &sgc_tag;
                memset(sgc_bst, 0, sizeof(struct bus_space_tag));
                sgc_bst->bustype = HP300_BUS_SPACE_SGC;
-               if (sti_sgc_cnprobe(sgc_bst, sgc_slottopa(0), 0)) {
-                       cninit_deferred = true;
-                       goto find_kbd;
+               for (slot = 0; slot < SGC_NSLOTS; slot++) {
+                       if (sti_sgc_cnprobe(sgc_bst, sgc_slottopa(slot),
+                           slot)) {
+                               cninit_deferred = true;
+                               consslot = slot;
+                               goto find_kbd;
+                       }
                }
        }
 #endif
@@ -926,8 +935,7 @@
                sgc_bst = &sgc_tag;
                memset(sgc_bst, 0, sizeof(struct bus_space_tag));
                sgc_bst->bustype = HP300_BUS_SPACE_SGC;
-               if (sti_sgc_cnprobe(sgc_bst, sgc_slottopa(0), 0))
-                       sti_sgc_cnattach(sgc_bst, sgc_slottopa(0), 0);
+               sti_sgc_cnattach(sgc_bst, sgc_slottopa(consslot), consslot);
        }
 #endif
 }



Home | Main Index | Thread Index | Old Index