Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 3 Mar 2020 03:22:01 +0000 (UTC)
From:      Justin Hibbits <jhibbits@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r358565 - head/sys/powerpc/powernv
Message-ID:  <202003030322.0233M1uZ013441@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jhibbits
Date: Tue Mar  3 03:22:00 2020
New Revision: 358565
URL: https://svnweb.freebsd.org/changeset/base/358565

Log:
  powerpc/powernv: powernv_node_numa_domain() fix non-NUMA case
  
  If NUMA is not enabled in the kernel config, or is disabled at boot, this
  function should just return domain 0 regardless of what's in the device
  tree.
  
  Fixes a panic in iflib with NUMA disabled.
  
  Reported by:	luporl

Modified:
  head/sys/powerpc/powernv/platform_powernv.c

Modified: head/sys/powerpc/powernv/platform_powernv.c
==============================================================================
--- head/sys/powerpc/powernv/platform_powernv.c	Tue Mar  3 01:46:35 2020	(r358564)
+++ head/sys/powerpc/powernv/platform_powernv.c	Tue Mar  3 03:22:00 2020	(r358565)
@@ -517,6 +517,12 @@ powernv_node_numa_domain(platform_t platform, phandle_
 	cell_t associativity[5];
 	int i, res;
 
+#ifndef NUMA
+	return (0);
+#endif
+	if (vm_ndomains == 1)
+		return (0);
+
 	res = OF_getencprop(node, "ibm,associativity",
 		associativity, sizeof(associativity));
 



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