Module Name:    src
Committed By:   tsutsui
Date:           Tue Apr 21 09:02:33 UTC 2020

Modified Files:
        src/sys/arch/hp300/hp300: machdep.c

Log Message:
Fix garbages in dmesg caused by uninitialized variables slipped in r1.228.

Noticed in HP9000/362 dmesg:
 https://dmesgd.nycbug.org/index.cgi?do=view&id=5459

Should be pulled up to netbsd-8 and netbsd-9.


To generate a diff of this commit:
cvs rdiff -u -r1.232 -r1.233 src/sys/arch/hp300/hp300/machdep.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/hp300/hp300/machdep.c
diff -u src/sys/arch/hp300/hp300/machdep.c:1.232 src/sys/arch/hp300/hp300/machdep.c:1.233
--- src/sys/arch/hp300/hp300/machdep.c:1.232	Tue Dec 31 13:07:10 2019
+++ src/sys/arch/hp300/hp300/machdep.c	Tue Apr 21 09:02:33 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: machdep.c,v 1.232 2019/12/31 13:07:10 ad Exp $	*/
+/*	$NetBSD: machdep.c,v 1.233 2020/04/21 09:02:33 tsutsui Exp $	*/
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -39,7 +39,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.232 2019/12/31 13:07:10 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.233 2020/04/21 09:02:33 tsutsui Exp $");
 
 #include "opt_ddb.h"
 #include "opt_compat_netbsd.h"
@@ -433,6 +433,7 @@ identifycpu(void)
 	/*
 	 * ...and the FPU type.
 	 */
+	fpu[0] = '\0';
 	switch (fputype) {
 	case FPU_68040:
 		strlcpy(fpu, "+FPU", sizeof(fpu));
@@ -458,6 +459,7 @@ identifycpu(void)
 	/*
 	 * ...and finally, the cache type.
 	 */
+	cache[0] = '\0';
 	if (cputype == CPU_68040)
 		snprintf(cache, sizeof(cache),
 		    ", 4k on-chip physical I/D caches");

Reply via email to