Subject: port-mips/5956: mips/trap.c referes explicitly to bcopy
To: None <gnats-bugs@gnats.netbsd.org>
From: Erik Bertelsen <erik@aarhus1.uni-c.dk>
List: netbsd-bugs
Date: 08/12/1998 14:35:14
>Number:         5956
>Category:       port-mips
>Synopsis:       mips/trap.c referes explicitly to bcopy
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    gnats-admin (GNATS administrator)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Aug 12 05:50:01 1998
>Last-Modified:
>Originator:     Erik Bertelsen
>Organization:
	
>Release:        NetBSD-current 11 Aug 1998
>Environment:
	
System: NetBSD aarhus1.uni-c.dk 1.3F NetBSD 1.3F (AARHUS1) #60: Thu Jul 16 20:33:00 MEST 1998 erik@aarhus1.uni-c.dk:/home/src/sys/arch/pmax/compile/AARHUS1 pmax


>Description:
When compiling a current kernel on a pmax, the following diagnostics
are issued for mips/mips/trap.c:

cc  -O2 -Wall -Werror -Wstrict-prototypes -Wmissing-prototypes -Wno-uninitialized -mno-abicalls -mno-half-pic -I. -I../../../../arch -I../../../.. -nostdinc -DMIPS1 -DDIAGNOSTIC -DDEBUG -DCOMPAT_43 -DNKMEMCLUSTERS=1024 -DHZ=256 -DSYSVSHM -DSYSVSEM -DSYSVMSG -DMAXUSERS=16 -D_KERNEL  -D__pmax__ -Dpmax -G 0  -c ../../../../arch/mips/mips/trap.c
../../../../arch/mips/mips/trap.c: In function `stacktrace_subr':
../../../../arch/mips/mips/trap.c:1655: `bcopy' undeclared (first use this function)
../../../../arch/mips/mips/trap.c:1655: (Each undeclared identifier is reported only once
../../../../arch/mips/mips/trap.c:1655: for each function it appears in.)
*** Error code 1

The code looks like:

        else if (pcBetween(idle, cpu_switch))   {
		subr = (unsigned) idle;
		ra = 0;
		goto done;
	}
	else if (pcBetween(bcopy, setrunqueue)) {
		subr = (unsigned) bcopy;
	}  

>How-To-Repeat:
>Fix:
	This looks like highly context sensitive code, which I really dont't
	grok to propose a correct solution. Possible ideas range from just
	deleting the three lines around the reference to bcopy, but it might
	be the case that some other function should be tested instead (memcpy?).

	regards
	Erik Bertelsen
>Audit-Trail:
>Unformatted: