-/* $OpenBSD: grf_iv.c,v 1.8 1997/03/08 16:16:51 briggs Exp $ */
+/* $OpenBSD: grf_iv.c,v 1.9 1997/03/12 13:26:37 briggs Exp $ */
/* $NetBSD: grf_iv.c,v 1.17 1997/02/20 00:23:27 scottr Exp $ */
/*
static int grfiv_mode __P((struct grf_softc *gp, int cmd, void *arg));
static caddr_t grfiv_phys __P((struct grf_softc *gp, vm_offset_t addr));
-static int grfiv_match __P((struct device *, struct cfdata *, void *));
+static int grfiv_match __P((struct device *, void *, void *));
static void grfiv_attach __P((struct device *, struct device *, void *));
static void grfiv_q700intr __P((void *client_data, int slot));
}
static int
-grfiv_match(parent, cf, aux)
+grfiv_match(parent, vcf, aux)
struct device *parent;
- struct cfdata *cf;
+ void *vcf;
void *aux;
{
char *addr = NULL;
- static int internal_video_found = 0;
- if (internal_video_found || (mac68k_vidlog == 0)) {
+ if (mac68k_vidlog == 0) {
return 0;
}
gm->hres = 80; /* XXX Hack */
gm->vres = 80; /* XXX Hack */
gm->fbsize = gm->rowbytes * gm->height;
- gm->fbbase = (caddr_t) mac68k_vidlog;
- gm->fboff = 0;
+ gm->fbbase = (caddr_t) (mac68k_vidlog & ~PGOFSET);
+ gm->fboff = mac68k_vidlog & PGOFSET;
/* Perform common video attachment. */
grf_establish(sc, NULL, grfiv_mode, grfiv_phys);
-/* $OpenBSD: ite.c,v 1.10 1997/03/08 16:16:54 briggs Exp $ */
+/* $OpenBSD: ite.c,v 1.11 1997/03/12 13:26:38 briggs Exp $ */
/* $NetBSD: ite.c,v 1.32 1997/02/20 00:23:25 scottr Exp $ */
/*
static void putc_square __P((char));
static void ite_putchar __P((char));
static int ite_pollforchar __P((void));
-static int itematch __P((struct device *, struct cfdata *, void *));
+static int itematch __P((struct device *, void *, void *));
static void iteattach __P((struct device *, struct device *, void *));
#define dprintf if (0) printf
};
static int
-itematch(parent, cf, aux)
+itematch(parent, vcf, aux)
struct device *parent;
- struct cfdata *cf;
+ void *vcf;
void *aux;
{
struct grfbus_attach_args *ga = aux;
if (strcmp(ga->ga_name, "ite"))
return 0;
- pa = pmap_extract(pmap_kernel(), (vm_offset_t) gm->fbbase);
+ pa = pmap_extract(pmap_kernel(), (vm_offset_t) gm->fbbase + gm->fboff);
return (pa == (vm_offset_t) mac68k_vidphys);
}