Subject: port-mac68k/8983: mac68k kernel build broken in 1-4 branch
To: None <gnats-bugs@gnats.netbsd.org>
From: Frederick Bruckman <fb@enteract.com>
List: netbsd-bugs
Date: 12/11/1999 14:15:36
>Number:         8983
>Category:       port-mac68k
>Synopsis:       mac68k kernel build broken 1-4 branch
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    port-mac68k-maintainer (NetBSD/mac68k Portmaster)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Dec 11 14:15:00 1999
>Last-Modified:
>Originator:     Frederick Bruckman
>Organization:

>Release:        netbsd-1-4, Dec 11, 1999
>Environment:
	
System: NetBSD corwin.home 1.4.1 NetBSD 1.4.1 (CORWIN) #6:
Thu Dec 9 12:18:56 CST 1999
fredb@corwin.home:/usr/src/sys/arch/mac68k/compile/CORWIN mac68k


>Description:
	
	Build breaks as follows (lines wrapped for clarity):

cc  -O3 -m68040 -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes
  -Wpointer-arith -Wno-main -msoft-float -I. -I../../../../arch
  -I../../../.. -nostdinc -DHZ="0x3c" -DTICK="0x411c" -DTICKADJ="0x24"
  -DM68040 -DFPSP -DLKM -DDIAGNOSTIC -DMAXUSERS=16 -D_KERNEL -Dmac68k
  -c ../../../../arch/mac68k/mac68k/sys_machdep.c
  ../../../../arch/mac68k/mac68k/sys_machdep.c: In function `cachectl1':
  ../../../../arch/mac68k/mac68k/sys_machdep.c:219:
  too many arguments to function `pmap_extract'
*** Error code 1

Stop.

	<code/input/activities to reproduce the problem (multiple lines)>
>How-To-Repeat:
>Fix:
	
	Evidently, the last pull-up to sys_machdep.c failed to take into
	account that the semantics of pmap_extract() have changed since 1-4.
	The following patch addresses that while preserving the intention.

Index: sys_machdep.c
===================================================================
RCS file: /cvsroot/syssrc/sys/arch/mac68k/mac68k/sys_machdep.c,v
retrieving revision 1.13.4.1
diff -c -r1.13.4.1 sys_machdep.c
*** sys_machdep.c	1999/11/29 21:36:28	1.13.4.1
--- sys_machdep.c	1999/12/11 22:11:06
***************
*** 215,223 ****
  			 */
  			if (!doall &&
  			    (pa == 0 || ((int)addr & PGOFSET) == 0)) {
! 				if (pmap_extract(p->p_vmspace->vm_map.pmap,
! 				    addr, &pa) == FALSE)
! 					doall = 1;
  			}
  			switch (req) {
  			case CC_EXTPURGE|CC_IPURGE:
--- 215,224 ----
  			 */
  			if (!doall &&
  			    (pa == 0 || ((int)addr & PGOFSET) == 0)) {
! 				if (!pa ==
! 				    pmap_extract(p->p_vmspace->vm_map.pmap,
! 					addr))
! 					    doall = 1;
  			}
  			switch (req) {
  			case CC_EXTPURGE|CC_IPURGE:

>Audit-Trail:
>Unformatted: