svn commit: r235261 - head/sys/boot/fdt

Tim Kientzle kientzle at FreeBSD.org
Fri May 11 04:18:40 UTC 2012


Author: kientzle
Date: Fri May 11 04:18:39 2012
New Revision: 235261
URL: http://svn.freebsd.org/changeset/base/235261

Log:
  Don't hang if there is no /cpus node in the device tree.

Modified:
  head/sys/boot/fdt/fdt_loader_cmd.c

Modified: head/sys/boot/fdt/fdt_loader_cmd.c
==============================================================================
--- head/sys/boot/fdt/fdt_loader_cmd.c	Fri May 11 04:10:23 2012	(r235260)
+++ head/sys/boot/fdt/fdt_loader_cmd.c	Fri May 11 04:18:39 2012	(r235261)
@@ -317,6 +317,8 @@ fixup_cpubusfreqs(unsigned long cpufreq,
 
 	/* We want to modify every subnode of /cpus */
 	o = fdt_path_offset(fdtp, "/cpus");
+	if (o < 0)
+		return;
 
 	/* maxo should contain offset of node next to /cpus */
 	depth = 0;


More information about the svn-src-all mailing list