Date: Fri, 16 Jul 2021 02:42:31 GMT From: Mark Johnston <markj@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: c1aff72cfa30 - main - callout: Make cc_cpu local to kern_timeout.c Message-ID: <202107160242.16G2gViW080580@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=c1aff72cfa30fa27efe867a4feb667f1963e8cf7 commit c1aff72cfa30fa27efe867a4feb667f1963e8cf7 Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2021-07-16 02:40:23 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2021-07-16 02:41:10 +0000 callout: Make cc_cpu local to kern_timeout.c No functional change intended. MFC after: 1 week Sponsored by: The FreeBSD Foundation --- sys/kern/kern_timeout.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/kern/kern_timeout.c b/sys/kern/kern_timeout.c index cc1521adf151..d9cf2784f642 100644 --- a/sys/kern/kern_timeout.c +++ b/sys/kern/kern_timeout.c @@ -190,14 +190,14 @@ struct callout_cpu { #define cc_migration_time(cc, dir) cc->cc_exec_entity[dir].ce_migration_time #define cc_migration_prec(cc, dir) cc->cc_exec_entity[dir].ce_migration_prec -struct callout_cpu cc_cpu[MAXCPU]; +static struct callout_cpu cc_cpu[MAXCPU]; #define CPUBLOCK MAXCPU #define CC_CPU(cpu) (&cc_cpu[(cpu)]) #define CC_SELF() CC_CPU(PCPU_GET(cpuid)) #else -struct callout_cpu cc_cpu; -#define CC_CPU(cpu) &cc_cpu -#define CC_SELF() &cc_cpu +static struct callout_cpu cc_cpu; +#define CC_CPU(cpu) (&cc_cpu) +#define CC_SELF() (&cc_cpu) #endif #define CC_LOCK(cc) mtx_lock_spin(&(cc)->cc_lock) #define CC_UNLOCK(cc) mtx_unlock_spin(&(cc)->cc_lock)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202107160242.16G2gViW080580>