Date: Sat, 28 Sep 2019 02:15:23 +0000 (UTC) From: Alexander Motin <mav@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org Subject: svn commit: r352830 - stable/12/sys/kern Message-ID: <201909280215.x8S2FN0o099640@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mav Date: Sat Sep 28 02:15:23 2019 New Revision: 352830 URL: https://svnweb.freebsd.org/changeset/base/352830 Log: MFC r352579: Allocate callout wheel from the respective memory domain. Modified: stable/12/sys/kern/kern_timeout.c Directory Properties: stable/12/ (props changed) Modified: stable/12/sys/kern/kern_timeout.c ============================================================================== --- stable/12/sys/kern/kern_timeout.c Sat Sep 28 01:42:59 2019 (r352829) +++ stable/12/sys/kern/kern_timeout.c Sat Sep 28 02:15:23 2019 (r352830) @@ -50,6 +50,7 @@ __FBSDID("$FreeBSD$"); #include <sys/systm.h> #include <sys/bus.h> #include <sys/callout.h> +#include <sys/domainset.h> #include <sys/file.h> #include <sys/interrupt.h> #include <sys/kernel.h> @@ -320,8 +321,9 @@ callout_cpu_init(struct callout_cpu *cc, int cpu) mtx_init(&cc->cc_lock, "callout", NULL, MTX_SPIN | MTX_RECURSE); SLIST_INIT(&cc->cc_callfree); cc->cc_inited = 1; - cc->cc_callwheel = malloc(sizeof(struct callout_list) * callwheelsize, - M_CALLOUT, M_WAITOK); + cc->cc_callwheel = malloc_domainset(sizeof(struct callout_list) * + callwheelsize, M_CALLOUT, + DOMAINSET_PREF(pcpu_find(cpu)->pc_domain), M_WAITOK); for (i = 0; i < callwheelsize; i++) LIST_INIT(&cc->cc_callwheel[i]); TAILQ_INIT(&cc->cc_expireq);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201909280215.x8S2FN0o099640>