Subject: Problem in mac68k -current
To: current users <current-users@NetBSD.ORG>
From: Paul Goyette <>
List: current-users
Date: 05/25/1997 12:46:11
For some reason, autoconfig isn't getting my video card set up right
(again!).  I've been seeing this problem for a couple of weeks now (ever
since I started trying to get -current with 1.2E), and I've finally
tracked it down some:

In sys/arch/mac68k/dev/ite.c in function ite_match(), I've inserted the
following printf() line:

	static int
	itematch(parent, cf, aux)
		struct device *parent;
		struct cfdata *cf;
		void *aux;
		struct grfbus_attach_args *ga = aux;
		struct grfmode *gm = ga->ga_grfmode;
		vm_offset_t pa;

		if (strcmp(ga->ga_name, "ite"))
			return 0;
		pa = pmap_extract(pmap_kernel(), (vm_offset_t)(gm->fbbase + gm->fboff));
>>>>		printf("itematch: pa = %p, vidphys = %p\n", 
>>>>			(void *) pa, (void *) mac68k_vidphys); /* PRG */
		return (pa == (vm_offset_t)mac68k_vidphys);

For some strange reason, the pmap_extract() call returns a value of
0xfd000800 while mac68k_vidphys contains 0xfd000400.  The latter value
agrees with what the booter passes in.

So, does anyone know why the pmap_extract() return value is 0x400 higher
than it (apparently) should be?  :)  Is it maybe some sort of "rounding
up to the next page boundary" error?

This problem doesn't cause too many problems in single user mode (ie, the
console is still quite useable), but as soon as I try to start up xdm it
core dumps.  If I log in and try startx, it just hangs and I have to
reboot the system.

| Paul Goyette       | PGP Public Key fingerprint:  | E-mail addresses:     |
| Network Consultant |     0E 40 D2 FC 2A 13 74 A0  |    |
| and kernel hacker  |     E4 69 D5 BE 65 E4 56 C6  | |