Subject: port-sparc/12839: functions zs_{getc,putc} in sparc/dev/zs.c declared static breaks kgdb
To: None <gnats-bugs@gnats.netbsd.org>
From: None <heas@shrubbery.net>
List: netbsd-bugs
Date: 05/04/2001 17:01:50
>Number: 12839
>Category: port-sparc
>Synopsis: functions zs_{getc,putc} in sparc/dev/zs.c declared static breaks kgdb
>Confidential: no
>Severity: serious
>Priority: high
>Responsible: port-sparc-maintainer
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri May 04 17:02:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator: heas
>Release: 1.5V
>Organization:
>Environment:
NetBSD guelah 1.5V NetBSD 1.5V (guelah2) #1: Wed May 2 15:04:50 PDT 2001 root@guelah:/u5/current/src/sys/arch/sparc/compile/guelah2 sparc
>Description:
functions zs_{getc,putc} in sparc/dev/zs.c are declared static,
which breaks KGDB at kernel link-time for the sparc port.
zs_kgdb.o: In function `zs_kgdb_init':
zs_kgdb.o(.text+0x188): undefined reference to `zs_getc'
zs_kgdb.o(.text+0x18c): undefined reference to `zs_putc'
zs_kgdb.o(.text+0x190): undefined reference to `zs_getc'
zs_kgdb.o(.text+0x194): undefined reference to `zs_putc'
>How-To-Repeat:
try to build a 1.5V kernel with KGDB enabled.
>Fix:
not sure this is the proper way to fix this;
guelah [114] pwd
/u5/current/src/sys/arch/sparc/dev
guelah [115] cvs diff zs.c
Index: zs.c
===================================================================
RCS file: /cvsroot/syssrc/sys/arch/sparc/dev/zs.c,v
retrieving revision 1.81
diff -r1.81 zs.c
793,794c793,794
< static int zs_getc __P((void *arg));
< static void zs_putc __P((void *arg, int c));
---
> int zs_getc __P((void *arg));
> void zs_putc __P((void *arg, int c));
>Release-Note:
>Audit-Trail:
>Unformatted: