Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 14 Jan 2020 11:24:06 +0000 (UTC)
From:      Edward Tomasz Napierala <trasz@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r356727 - head/sys/compat/linux
Message-ID:  <202001141124.00EBO6Gp033317@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: trasz
Date: Tue Jan 14 11:24:06 2020
New Revision: 356727
URL: https://svnweb.freebsd.org/changeset/base/356727

Log:
  Make linux getcpu(2) report the domain.
  
  Submitted by:	markj
  Reviewed by:	markj
  MFC after:	2 weeks
  Sponsored by:	The FreeBSD Foundation
  Differential Revision:	https://reviews.freebsd.org/D23144

Modified:
  head/sys/compat/linux/linux_misc.c

Modified: head/sys/compat/linux/linux_misc.c
==============================================================================
--- head/sys/compat/linux/linux_misc.c	Tue Jan 14 10:13:44 2020	(r356726)
+++ head/sys/compat/linux/linux_misc.c	Tue Jan 14 11:24:06 2020	(r356727)
@@ -2354,7 +2354,7 @@ linux_getcpu(struct thread *td, struct linux_getcpu_ar
 
 	cpu = td->td_oncpu; /* Make sure it doesn't change during copyout(9) */
 	error = 0;
-	node = 0; /* XXX: Fake NUMA node 0 for now */
+	node = cpuid_to_pcpu[cpu]->pc_domain;
 
 	if (args->cpu != NULL)
 		error = copyout(&cpu, args->cpu, sizeof(l_int));



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