Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 16 Aug 2016 07:51:05 +0000 (UTC)
From:      Adrian Chadd <adrian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r304207 - head/sys/mips/mips
Message-ID:  <201608160751.u7G7p5GB073084@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: adrian
Date: Tue Aug 16 07:51:05 2016
New Revision: 304207
URL: https://svnweb.freebsd.org/changeset/base/304207

Log:
  [mips] fix use-before-initialised.
  
  Found by: gcc-5.3

Modified:
  head/sys/mips/mips/cpu.c

Modified: head/sys/mips/mips/cpu.c
==============================================================================
--- head/sys/mips/mips/cpu.c	Tue Aug 16 07:45:35 2016	(r304206)
+++ head/sys/mips/mips/cpu.c	Tue Aug 16 07:51:05 2016	(r304207)
@@ -164,6 +164,8 @@ mips_get_identity(struct mips_cpuinfo *c
 	cfg1 = mips_rd_config1();
 
 	/* Get the Config2 and Config3 registers as well. */
+	cfg2 = 0;
+	cfg3 = 0;
 	if (cfg1 & MIPS_CONFIG1_M) {
 		cfg2 = mips_rd_config2();
 		if (cfg2 & MIPS_CONFIG2_M)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201608160751.u7G7p5GB073084>