Fix the internal video probe again.

This commit is contained in:
briggs 1995-07-30 21:35:00 +00:00
parent 80cd97e743
commit ff5fa674dd
6 changed files with 30 additions and 24 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: grf_iv.c,v 1.6 1995/07/28 01:34:58 briggs Exp $ */
/* $NetBSD: grf_iv.c,v 1.7 1995/07/30 21:36:23 briggs Exp $ */
/*
* Copyright (c) 1995 Allen Briggs. All rights reserved.
@ -65,13 +65,15 @@ grfiv_probe(sc, slotinfo)
if (int_video_start == 0 && mac68k_vidlog == 0) {
return 0;
}
if (slotinfo->slot <= 0xe) {
if (NUBUS_SLOT_TO_BASE(slotinfo->slot) > int_video_start)
return 0;
if (NUBUS_SLOT_TO_BASE(slotinfo->slot + 1) <= int_video_start)
return 0;
}
return 1;
if ( (NUBUS_SLOT_TO_BASE(slotinfo->slot) <= int_video_start)
&& (int_video_start < NUBUS_SLOT_TO_BASE(slotinfo->slot + 1)))
return 1;
if (slotinfo->slot == NUBUS_INT_VIDEO_PSUEDO_SLOT)
return 1;
return 0;
}
extern int

View File

@ -1,4 +1,4 @@
/* $NetBSD: nubus.c,v 1.12 1995/06/21 02:59:08 briggs Exp $ */
/* $NetBSD: nubus.c,v 1.13 1995/07/30 21:35:00 briggs Exp $ */
/*
* Copyright (c) 1995 Allen Briggs. All rights reserved.
@ -85,8 +85,8 @@ nubusattach(parent, self, aux)
* Kludge for internal video.
*/
if (int_video_start) {
int int_video_slot = 0xe;
fmtblock.top = NUBUS_SLOT_TO_BASE(int_video_slot+1);
int int_video_slot = NUBUS_INT_VIDEO_PSUEDO_SLOT;
fmtblock.top = NUBUS_SLOT_TO_BASE(int_video_slot);
fmtblock.slot = int_video_slot;
fmtblock.bytelanes = 0x0F;
fmtblock.step = 4;

View File

@ -1,4 +1,4 @@
/* $NetBSD: nubus.h,v 1.8 1995/07/01 23:40:40 briggs Exp $ */
/* $NetBSD: nubus.h,v 1.9 1995/07/30 21:35:51 briggs Exp $ */
/*
* Copyright (c) 1995 Allen Briggs. All rights reserved.
@ -212,6 +212,7 @@ typedef struct _NUBUS_EXEC_BLOCK {
#define NUBUS_MIN_SLOT 0x9
#define NUBUS_MAX_SLOT 0xE
#define NUBUS_INT_VIDEO_PSUEDO_SLOT 0xF
#define NUBUS_ROM_TEST_PATTERN 0x5A932BC7
#define NUBUS_BASE_TO_SLOT(x) (((((x)-NuBusBase) >> 24) & 0x0F) + \

View File

@ -1,4 +1,4 @@
/* $NetBSD: nubus.c,v 1.12 1995/06/21 02:59:08 briggs Exp $ */
/* $NetBSD: nubus.c,v 1.13 1995/07/30 21:35:00 briggs Exp $ */
/*
* Copyright (c) 1995 Allen Briggs. All rights reserved.
@ -85,8 +85,8 @@ nubusattach(parent, self, aux)
* Kludge for internal video.
*/
if (int_video_start) {
int int_video_slot = 0xe;
fmtblock.top = NUBUS_SLOT_TO_BASE(int_video_slot+1);
int int_video_slot = NUBUS_INT_VIDEO_PSUEDO_SLOT;
fmtblock.top = NUBUS_SLOT_TO_BASE(int_video_slot);
fmtblock.slot = int_video_slot;
fmtblock.bytelanes = 0x0F;
fmtblock.step = 4;

View File

@ -1,4 +1,4 @@
/* $NetBSD: nubus.h,v 1.8 1995/07/01 23:40:40 briggs Exp $ */
/* $NetBSD: nubus.h,v 1.9 1995/07/30 21:35:51 briggs Exp $ */
/*
* Copyright (c) 1995 Allen Briggs. All rights reserved.
@ -212,6 +212,7 @@ typedef struct _NUBUS_EXEC_BLOCK {
#define NUBUS_MIN_SLOT 0x9
#define NUBUS_MAX_SLOT 0xE
#define NUBUS_INT_VIDEO_PSUEDO_SLOT 0xF
#define NUBUS_ROM_TEST_PATTERN 0x5A932BC7
#define NUBUS_BASE_TO_SLOT(x) (((((x)-NuBusBase) >> 24) & 0x0F) + \

View File

@ -1,4 +1,4 @@
/* $NetBSD: grf_obio.c,v 1.6 1995/07/28 01:34:58 briggs Exp $ */
/* $NetBSD: grf_obio.c,v 1.7 1995/07/30 21:36:23 briggs Exp $ */
/*
* Copyright (c) 1995 Allen Briggs. All rights reserved.
@ -65,13 +65,15 @@ grfiv_probe(sc, slotinfo)
if (int_video_start == 0 && mac68k_vidlog == 0) {
return 0;
}
if (slotinfo->slot <= 0xe) {
if (NUBUS_SLOT_TO_BASE(slotinfo->slot) > int_video_start)
return 0;
if (NUBUS_SLOT_TO_BASE(slotinfo->slot + 1) <= int_video_start)
return 0;
}
return 1;
if ( (NUBUS_SLOT_TO_BASE(slotinfo->slot) <= int_video_start)
&& (int_video_start < NUBUS_SLOT_TO_BASE(slotinfo->slot + 1)))
return 1;
if (slotinfo->slot == NUBUS_INT_VIDEO_PSUEDO_SLOT)
return 1;
return 0;
}
extern int