Add RBV monitor sense code (formerly commented out in rbv_vidstatus())

to the match function, and print out more detailed information when
attaching RBV video.
This commit is contained in:
scottr 1999-01-06 07:08:19 +00:00
parent dd22f79d3e
commit 46b2a0ebce

View File

@ -1,4 +1,4 @@
/* $NetBSD: grf_obio.c,v 1.40 1998/08/21 13:46:31 scottr Exp $ */
/* $NetBSD: grf_obio.c,v 1.41 1999/01/06 07:08:19 scottr Exp $ */
/*
* Copyright (C) 1998 Scott Reynolds
@ -177,6 +177,12 @@ grfiv_match(parent, cf, aux)
bus_space_unmap(oa->oa_tag, bsh, 0x1000);
break;
case MACH_CLASSIIci:
case MACH_CLASSIIsi:
if (mac68k_vidlen == 0 ||
(via2_reg(rMonitor) & RBVMonitorMask) == RBVMonIDNone)
found = 0;
break;
default:
if (mac68k_vidlen == 0)
found = 0;
@ -268,6 +274,34 @@ grfiv_attach(parent, self, aux)
printf(" @ %lx: Civic video subsystem\n",
sc->sc_basepa + sc->sc_fbofs);
break;
case MACH_CLASSIIci:
case MACH_CLASSIIsi:
sc->sc_basepa = m68k_trunc_page(mac68k_vidphys);
sc->sc_fbofs = mac68k_vidphys & PGOFSET;
length = mac68k_vidlen + sc->sc_fbofs;
printf(" @ %lx: RBV video subsystem, ",
sc->sc_basepa + sc->sc_fbofs);
switch (via2_reg(rMonitor) & RBVMonitorMask) {
case RBVMonIDBWP:
printf("15\" monochrome portrait");
break;
case RBVMonIDRGB12:
printf("12\" color");
break;
case RBVMonIDRGB15:
printf("15\" color");
break;
case RBVMonIDStd:
printf("Macintosh II");
break;
default:
printf("unrecognized");
break;
}
printf(" display\n");
break;
default:
sc->sc_basepa = m68k_trunc_page(mac68k_vidphys);
sc->sc_fbofs = mac68k_vidphys & PGOFSET;