From: kbuild test robot <lkp@intel.com>
To: Jiaxun Yang <jiaxun.yang@flygoat.com>
Cc: kbuild-all@lists.01.org, linux-mips@vger.kernel.org,
"dietmar.eggemann@arm.com, Jiaxun Yang" <jiaxun.yang@flygoat.com>,
"Thomas Bogendoerfer" <tsbogend@alpha.franken.de>,
"Huacai Chen" <chenhc@lemote.com>,
"Peter Zijlstra" <peterz@infradead.org>,
"Ingo Molnar" <mingo@redhat.com>,
"Arnaldo Carvalho de Melo" <acme@kernel.org>,
"Mark Rutland" <mark.rutland@arm.com>,
"Alexander Shishkin" <alexander.shishkin@linux.intel.com>,
"Jiri Olsa" <jolsa@redhat.com>,
"Namhyung Kim" <namhyung@kernel.org>,
"Florian Fainelli" <f.fainelli@gmail.com>,
"Robert Richter" <rric@kernel.org>,
"Sudeep Holla" <sudeep.holla@arm.com>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
"Daniel Lezcano" <daniel.lezcano@linaro.org>,
"Thomas Gleixner" <tglx@linutronix.de>,
"Jason Cooper" <jason@lakedaemon.net>,
"Marc Zyngier" <maz@kernel.org>,
"Paul Burton" <paulburton@kernel.org>,
"Allison Randal" <allison@lohutok.net>,
"Enrico Weigelt" <info@metux.net>,
"Kate Stewart" <kstewart@linuxfoundation.org>,
"Vladimir Kondratiev" <vladimir.kondratiev@intel.com>,
"Paul Cercueil" <paul@crapouillou.net>,
"Zhou Yanjie" <zhouyanjie@zoho.com>,
"周琰杰 (Zhou Yanjie)" <zhouyanjie@wanyeetech.com>,
"YunQiang Su" <syq@debian.org>, "Arnd Bergmann" <arnd@arndb.de>,
"Serge Semin" <fancer.lancer@gmail.com>,
"Matt Redfearn" <matt.redfearn@mips.com>,
"Steve Winslow" <swinslow@gmail.com>,
"Alexios Zavras" <alexios.zavras@intel.com>,
"Richard Fontana" <rfontana@redhat.com>,
"Peter Xu" <peterx@redhat.com>,
"afzal mohammed" <afzal.mohd.ma@gmail.com>,
"Kamal Dasu" <kdasu.kdev@gmail.com>,
"Oleksij Rempel" <linux@rempel-privat.de>,
linux-kernel@vger.kernel.org,
bcm-kernel-feedback-list@broadcom.com,
oprofile-list@lists.sf.net, linux-pm@vger.kernel.org
Subject: Re: [PATCH v2 05/11] MIPS: Switch to arch_topology
Date: Sun, 12 Apr 2020 13:24:19 +0800 [thread overview]
Message-ID: <202004121355.oP26ZAtx%lkp@intel.com> (raw)
In-Reply-To: <20200412032123.3896114-6-jiaxun.yang@flygoat.com>
[-- Attachment #1: Type: text/plain, Size: 17040 bytes --]
Hi Jiaxun,
I love your patch! Yet something to improve:
[auto build test ERROR on driver-core/driver-core-testing]
[also build test ERROR on pm/linux-next linus/master next-20200411]
[cannot apply to tip/perf/core tip/irq/core v5.6]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
url: https://github.com/0day-ci/linux/commits/Jiaxun-Yang/MIPS-Topology-DeviceTree-CPU-rework-v2/20200412-113308
base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core.git a10c9c710f9ecea87b9f4bbb837467893b4bef01
config: mips-fuloong2e_defconfig (attached as .config)
compiler: mips64el-linux-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=9.3.0 make.cross ARCH=mips
If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp@intel.com>
Note: the linux-review/Jiaxun-Yang/MIPS-Topology-DeviceTree-CPU-rework-v2/20200412-113308 HEAD 8e8e9d4f7aa74359f2199773786ffe2fbb7877d0 builds fine.
It only hurts bisectibility.
All errors (new ones prefixed by >>):
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
arch/mips/include/asm/mips-cm.h: In function 'mips_cm_vp_id':
>> arch/mips/include/asm/mips-cm.h:398:31: error: passing argument 1 of 'cpu_core' makes integer from pointer without a cast [-Werror=int-conversion]
398 | unsigned int core = cpu_core(&cpu_data[cpu]);
| ^~~~~~~~~~~~~~
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:68:41: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
68 | static inline unsigned int cpu_core(int cpu)
| ~~~~^~~
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
>> arch/mips/include/asm/mips-cm.h:399:31: error: passing argument 1 of 'cpu_vpe_id' makes integer from pointer without a cast [-Werror=int-conversion]
399 | unsigned int vp = cpu_vpe_id(&cpu_data[cpu]);
| ^~~~~~~~~~~~~~
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:73:43: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
73 | static inline unsigned int cpu_vpe_id(int cpu)
| ~~~~^~~
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
arch/mips/include/asm/mips-cm.h: In function 'mips_cm_lock_other_cpu':
>> arch/mips/include/asm/mips-cm.h:456:33: error: passing argument 1 of 'cpu_cluster' makes integer from pointer without a cast [-Werror=int-conversion]
456 | mips_cm_lock_other(cpu_cluster(d), cpu_core(d), cpu_vpe_id(d), block);
| ^
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:63:44: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
63 | static inline unsigned int cpu_cluster(int cpu)
| ~~~~^~~
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
arch/mips/include/asm/mips-cm.h:456:46: error: passing argument 1 of 'cpu_core' makes integer from pointer without a cast [-Werror=int-conversion]
456 | mips_cm_lock_other(cpu_cluster(d), cpu_core(d), cpu_vpe_id(d), block);
| ^
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:68:41: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
68 | static inline unsigned int cpu_core(int cpu)
| ~~~~^~~
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
arch/mips/include/asm/mips-cm.h:456:61: error: passing argument 1 of 'cpu_vpe_id' makes integer from pointer without a cast [-Werror=int-conversion]
456 | mips_cm_lock_other(cpu_cluster(d), cpu_core(d), cpu_vpe_id(d), block);
| ^
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:73:43: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
73 | static inline unsigned int cpu_vpe_id(int cpu)
| ~~~~^~~
cc1: all warnings being treated as errors
--
arch/mips/kernel/cacheinfo.c: In function 'fill_cpumask_siblings':
arch/mips/kernel/cacheinfo.c:58:7: error: implicit declaration of function 'cpus_are_siblings' [-Werror=implicit-function-declaration]
58 | if (cpus_are_siblings(cpu, cpu1))
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/cacheinfo.c: In function 'fill_cpumask_cluster':
>> arch/mips/kernel/cacheinfo.c:65:16: error: implicit declaration of function 'cpu_cluster' [-Werror=implicit-function-declaration]
65 | int cluster = cpu_cluster(&cpu_data[cpu]);
| ^~~~~~~~~~~
cc1: all warnings being treated as errors
--
arch/mips/kernel/proc.c: In function 'show_cpuinfo':
>> arch/mips/kernel/proc.c:141:50: error: 'struct cpuinfo_mips' has no member named 'package'
141 | seq_printf(m, "package\t\t\t: %d\n", cpu_data[n].package);
| ^
>> arch/mips/kernel/proc.c:142:45: error: passing argument 1 of 'cpu_core' makes integer from pointer without a cast [-Werror=int-conversion]
142 | seq_printf(m, "core\t\t\t: %d\n", cpu_core(&cpu_data[n]));
| ^~~~~~~~~~~~
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/fs.h:15,
from include/linux/seq_file.h:11,
from arch/mips/kernel/proc.c:10:
arch/mips/include/asm/topology.h:68:41: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
68 | static inline unsigned int cpu_core(int cpu)
| ~~~~^~~
cc1: all warnings being treated as errors
vim +/cpu_core +398 arch/mips/include/asm/mips-cm.h
7573b94e08aeb5 Paul Burton 2015-09-22 385
7573b94e08aeb5 Paul Burton 2015-09-22 386 /**
7573b94e08aeb5 Paul Burton 2015-09-22 387 * mips_cm_vp_id() - calculate the hardware VP ID for a CPU
7573b94e08aeb5 Paul Burton 2015-09-22 388 * @cpu: the CPU whose VP ID to calculate
7573b94e08aeb5 Paul Burton 2015-09-22 389 *
7573b94e08aeb5 Paul Burton 2015-09-22 390 * Hardware such as the GIC uses identifiers for VPs which may not match the
7573b94e08aeb5 Paul Burton 2015-09-22 391 * CPU numbers used by Linux. This function calculates the hardware VP
7573b94e08aeb5 Paul Burton 2015-09-22 392 * identifier corresponding to a given CPU.
7573b94e08aeb5 Paul Burton 2015-09-22 393 *
7573b94e08aeb5 Paul Burton 2015-09-22 394 * Return: the VP ID for the CPU.
7573b94e08aeb5 Paul Burton 2015-09-22 395 */
7573b94e08aeb5 Paul Burton 2015-09-22 396 static inline unsigned int mips_cm_vp_id(unsigned int cpu)
7573b94e08aeb5 Paul Burton 2015-09-22 397 {
f875a832d20285 Paul Burton 2017-08-12 @398 unsigned int core = cpu_core(&cpu_data[cpu]);
7573b94e08aeb5 Paul Burton 2015-09-22 @399 unsigned int vp = cpu_vpe_id(&cpu_data[cpu]);
7573b94e08aeb5 Paul Burton 2015-09-22 400
7573b94e08aeb5 Paul Burton 2015-09-22 401 return (core * mips_cm_max_vp_width()) + vp;
7573b94e08aeb5 Paul Burton 2015-09-22 402 }
7573b94e08aeb5 Paul Burton 2015-09-22 403
23d5de8efb9aed Paul Burton 2015-09-22 404 #ifdef CONFIG_MIPS_CM
23d5de8efb9aed Paul Burton 2015-09-22 405
23d5de8efb9aed Paul Burton 2015-09-22 406 /**
68923cdc2eb341 Paul Burton 2017-08-12 407 * mips_cm_lock_other - lock access to redirect/other region
68923cdc2eb341 Paul Burton 2017-08-12 408 * @cluster: the other cluster to be accessed
23d5de8efb9aed Paul Burton 2015-09-22 409 * @core: the other core to be accessed
23d5de8efb9aed Paul Burton 2015-09-22 410 * @vp: the VP within the other core to be accessed
68923cdc2eb341 Paul Burton 2017-08-12 411 * @block: the register block to be accessed
23d5de8efb9aed Paul Burton 2015-09-22 412 *
68923cdc2eb341 Paul Burton 2017-08-12 413 * Configure the redirect/other region for the local core/VP (depending upon
68923cdc2eb341 Paul Burton 2017-08-12 414 * the CM revision) to target the specified @cluster, @core, @vp & register
68923cdc2eb341 Paul Burton 2017-08-12 415 * @block. Must be called before using the redirect/other region, and followed
68923cdc2eb341 Paul Burton 2017-08-12 416 * by a call to mips_cm_unlock_other() when access to the redirect/other region
68923cdc2eb341 Paul Burton 2017-08-12 417 * is complete.
68923cdc2eb341 Paul Burton 2017-08-12 418 *
68923cdc2eb341 Paul Burton 2017-08-12 419 * This function acquires a spinlock such that code between it &
68923cdc2eb341 Paul Burton 2017-08-12 420 * mips_cm_unlock_other() calls cannot be pre-empted by anything which may
68923cdc2eb341 Paul Burton 2017-08-12 421 * reconfigure the redirect/other region, and cannot be interfered with by
68923cdc2eb341 Paul Burton 2017-08-12 422 * another VP in the core. As such calls to this function should not be nested.
23d5de8efb9aed Paul Burton 2015-09-22 423 */
68923cdc2eb341 Paul Burton 2017-08-12 424 extern void mips_cm_lock_other(unsigned int cluster, unsigned int core,
68923cdc2eb341 Paul Burton 2017-08-12 425 unsigned int vp, unsigned int block);
23d5de8efb9aed Paul Burton 2015-09-22 426
23d5de8efb9aed Paul Burton 2015-09-22 427 /**
68923cdc2eb341 Paul Burton 2017-08-12 428 * mips_cm_unlock_other - unlock access to redirect/other region
23d5de8efb9aed Paul Burton 2015-09-22 429 *
68923cdc2eb341 Paul Burton 2017-08-12 430 * Must be called after mips_cm_lock_other() once all required access to the
68923cdc2eb341 Paul Burton 2017-08-12 431 * redirect/other region has been completed.
23d5de8efb9aed Paul Burton 2015-09-22 432 */
23d5de8efb9aed Paul Burton 2015-09-22 433 extern void mips_cm_unlock_other(void);
23d5de8efb9aed Paul Burton 2015-09-22 434
23d5de8efb9aed Paul Burton 2015-09-22 435 #else /* !CONFIG_MIPS_CM */
23d5de8efb9aed Paul Burton 2015-09-22 436
68923cdc2eb341 Paul Burton 2017-08-12 437 static inline void mips_cm_lock_other(unsigned int cluster, unsigned int core,
68923cdc2eb341 Paul Burton 2017-08-12 438 unsigned int vp, unsigned int block) { }
23d5de8efb9aed Paul Burton 2015-09-22 439 static inline void mips_cm_unlock_other(void) { }
23d5de8efb9aed Paul Burton 2015-09-22 440
23d5de8efb9aed Paul Burton 2015-09-22 441 #endif /* !CONFIG_MIPS_CM */
23d5de8efb9aed Paul Burton 2015-09-22 442
68923cdc2eb341 Paul Burton 2017-08-12 443 /**
68923cdc2eb341 Paul Burton 2017-08-12 444 * mips_cm_lock_other_cpu - lock access to redirect/other region
68923cdc2eb341 Paul Burton 2017-08-12 445 * @cpu: the other CPU whose register we want to access
68923cdc2eb341 Paul Burton 2017-08-12 446 *
68923cdc2eb341 Paul Burton 2017-08-12 447 * Configure the redirect/other region for the local core/VP (depending upon
68923cdc2eb341 Paul Burton 2017-08-12 448 * the CM revision) to target the specified @cpu & register @block. This is
68923cdc2eb341 Paul Burton 2017-08-12 449 * equivalent to calling mips_cm_lock_other() but accepts a Linux CPU number
68923cdc2eb341 Paul Burton 2017-08-12 450 * for convenience.
68923cdc2eb341 Paul Burton 2017-08-12 451 */
68923cdc2eb341 Paul Burton 2017-08-12 452 static inline void mips_cm_lock_other_cpu(unsigned int cpu, unsigned int block)
68923cdc2eb341 Paul Burton 2017-08-12 453 {
68923cdc2eb341 Paul Burton 2017-08-12 454 struct cpuinfo_mips *d = &cpu_data[cpu];
68923cdc2eb341 Paul Burton 2017-08-12 455
68923cdc2eb341 Paul Burton 2017-08-12 @456 mips_cm_lock_other(cpu_cluster(d), cpu_core(d), cpu_vpe_id(d), block);
68923cdc2eb341 Paul Burton 2017-08-12 457 }
68923cdc2eb341 Paul Burton 2017-08-12 458
:::::: The code at line 398 was first introduced by commit
:::::: f875a832d2028523f9b53c261b67e05a359bab8b MIPS: Abstract CPU core & VP(E) ID access through accessor functions
:::::: TO: Paul Burton <paul.burton@imgtec.com>
:::::: CC: Ralf Baechle <ralf@linux-mips.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 19312 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: kbuild test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [PATCH v2 05/11] MIPS: Switch to arch_topology
Date: Sun, 12 Apr 2020 13:24:19 +0800 [thread overview]
Message-ID: <202004121355.oP26ZAtx%lkp@intel.com> (raw)
In-Reply-To: <20200412032123.3896114-6-jiaxun.yang@flygoat.com>
[-- Attachment #1: Type: text/plain, Size: 17307 bytes --]
Hi Jiaxun,
I love your patch! Yet something to improve:
[auto build test ERROR on driver-core/driver-core-testing]
[also build test ERROR on pm/linux-next linus/master next-20200411]
[cannot apply to tip/perf/core tip/irq/core v5.6]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
url: https://github.com/0day-ci/linux/commits/Jiaxun-Yang/MIPS-Topology-DeviceTree-CPU-rework-v2/20200412-113308
base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core.git a10c9c710f9ecea87b9f4bbb837467893b4bef01
config: mips-fuloong2e_defconfig (attached as .config)
compiler: mips64el-linux-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=9.3.0 make.cross ARCH=mips
If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp@intel.com>
Note: the linux-review/Jiaxun-Yang/MIPS-Topology-DeviceTree-CPU-rework-v2/20200412-113308 HEAD 8e8e9d4f7aa74359f2199773786ffe2fbb7877d0 builds fine.
It only hurts bisectibility.
All errors (new ones prefixed by >>):
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
arch/mips/include/asm/mips-cm.h: In function 'mips_cm_vp_id':
>> arch/mips/include/asm/mips-cm.h:398:31: error: passing argument 1 of 'cpu_core' makes integer from pointer without a cast [-Werror=int-conversion]
398 | unsigned int core = cpu_core(&cpu_data[cpu]);
| ^~~~~~~~~~~~~~
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:68:41: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
68 | static inline unsigned int cpu_core(int cpu)
| ~~~~^~~
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
>> arch/mips/include/asm/mips-cm.h:399:31: error: passing argument 1 of 'cpu_vpe_id' makes integer from pointer without a cast [-Werror=int-conversion]
399 | unsigned int vp = cpu_vpe_id(&cpu_data[cpu]);
| ^~~~~~~~~~~~~~
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:73:43: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
73 | static inline unsigned int cpu_vpe_id(int cpu)
| ~~~~^~~
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
arch/mips/include/asm/mips-cm.h: In function 'mips_cm_lock_other_cpu':
>> arch/mips/include/asm/mips-cm.h:456:33: error: passing argument 1 of 'cpu_cluster' makes integer from pointer without a cast [-Werror=int-conversion]
456 | mips_cm_lock_other(cpu_cluster(d), cpu_core(d), cpu_vpe_id(d), block);
| ^
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:63:44: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
63 | static inline unsigned int cpu_cluster(int cpu)
| ~~~~^~~
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
arch/mips/include/asm/mips-cm.h:456:46: error: passing argument 1 of 'cpu_core' makes integer from pointer without a cast [-Werror=int-conversion]
456 | mips_cm_lock_other(cpu_cluster(d), cpu_core(d), cpu_vpe_id(d), block);
| ^
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:68:41: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
68 | static inline unsigned int cpu_core(int cpu)
| ~~~~^~~
In file included from arch/mips/include/asm/mips-cps.h:104,
from arch/mips/kernel/process.c:43:
arch/mips/include/asm/mips-cm.h:456:61: error: passing argument 1 of 'cpu_vpe_id' makes integer from pointer without a cast [-Werror=int-conversion]
456 | mips_cm_lock_other(cpu_cluster(d), cpu_core(d), cpu_vpe_id(d), block);
| ^
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from include/linux/clocksource.h:19,
from include/linux/clockchips.h:14,
from include/linux/tick.h:8,
from arch/mips/kernel/process.c:17:
arch/mips/include/asm/topology.h:73:43: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
73 | static inline unsigned int cpu_vpe_id(int cpu)
| ~~~~^~~
cc1: all warnings being treated as errors
--
arch/mips/kernel/cacheinfo.c: In function 'fill_cpumask_siblings':
arch/mips/kernel/cacheinfo.c:58:7: error: implicit declaration of function 'cpus_are_siblings' [-Werror=implicit-function-declaration]
58 | if (cpus_are_siblings(cpu, cpu1))
| ^~~~~~~~~~~~~~~~~
arch/mips/kernel/cacheinfo.c: In function 'fill_cpumask_cluster':
>> arch/mips/kernel/cacheinfo.c:65:16: error: implicit declaration of function 'cpu_cluster' [-Werror=implicit-function-declaration]
65 | int cluster = cpu_cluster(&cpu_data[cpu]);
| ^~~~~~~~~~~
cc1: all warnings being treated as errors
--
arch/mips/kernel/proc.c: In function 'show_cpuinfo':
>> arch/mips/kernel/proc.c:141:50: error: 'struct cpuinfo_mips' has no member named 'package'
141 | seq_printf(m, "package\t\t\t: %d\n", cpu_data[n].package);
| ^
>> arch/mips/kernel/proc.c:142:45: error: passing argument 1 of 'cpu_core' makes integer from pointer without a cast [-Werror=int-conversion]
142 | seq_printf(m, "core\t\t\t: %d\n", cpu_core(&cpu_data[n]));
| ^~~~~~~~~~~~
| |
| struct cpuinfo_mips *
In file included from include/linux/topology.h:36,
from include/linux/gfp.h:9,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/fs.h:15,
from include/linux/seq_file.h:11,
from arch/mips/kernel/proc.c:10:
arch/mips/include/asm/topology.h:68:41: note: expected 'int' but argument is of type 'struct cpuinfo_mips *'
68 | static inline unsigned int cpu_core(int cpu)
| ~~~~^~~
cc1: all warnings being treated as errors
vim +/cpu_core +398 arch/mips/include/asm/mips-cm.h
7573b94e08aeb5 Paul Burton 2015-09-22 385
7573b94e08aeb5 Paul Burton 2015-09-22 386 /**
7573b94e08aeb5 Paul Burton 2015-09-22 387 * mips_cm_vp_id() - calculate the hardware VP ID for a CPU
7573b94e08aeb5 Paul Burton 2015-09-22 388 * @cpu: the CPU whose VP ID to calculate
7573b94e08aeb5 Paul Burton 2015-09-22 389 *
7573b94e08aeb5 Paul Burton 2015-09-22 390 * Hardware such as the GIC uses identifiers for VPs which may not match the
7573b94e08aeb5 Paul Burton 2015-09-22 391 * CPU numbers used by Linux. This function calculates the hardware VP
7573b94e08aeb5 Paul Burton 2015-09-22 392 * identifier corresponding to a given CPU.
7573b94e08aeb5 Paul Burton 2015-09-22 393 *
7573b94e08aeb5 Paul Burton 2015-09-22 394 * Return: the VP ID for the CPU.
7573b94e08aeb5 Paul Burton 2015-09-22 395 */
7573b94e08aeb5 Paul Burton 2015-09-22 396 static inline unsigned int mips_cm_vp_id(unsigned int cpu)
7573b94e08aeb5 Paul Burton 2015-09-22 397 {
f875a832d20285 Paul Burton 2017-08-12 @398 unsigned int core = cpu_core(&cpu_data[cpu]);
7573b94e08aeb5 Paul Burton 2015-09-22 @399 unsigned int vp = cpu_vpe_id(&cpu_data[cpu]);
7573b94e08aeb5 Paul Burton 2015-09-22 400
7573b94e08aeb5 Paul Burton 2015-09-22 401 return (core * mips_cm_max_vp_width()) + vp;
7573b94e08aeb5 Paul Burton 2015-09-22 402 }
7573b94e08aeb5 Paul Burton 2015-09-22 403
23d5de8efb9aed Paul Burton 2015-09-22 404 #ifdef CONFIG_MIPS_CM
23d5de8efb9aed Paul Burton 2015-09-22 405
23d5de8efb9aed Paul Burton 2015-09-22 406 /**
68923cdc2eb341 Paul Burton 2017-08-12 407 * mips_cm_lock_other - lock access to redirect/other region
68923cdc2eb341 Paul Burton 2017-08-12 408 * @cluster: the other cluster to be accessed
23d5de8efb9aed Paul Burton 2015-09-22 409 * @core: the other core to be accessed
23d5de8efb9aed Paul Burton 2015-09-22 410 * @vp: the VP within the other core to be accessed
68923cdc2eb341 Paul Burton 2017-08-12 411 * @block: the register block to be accessed
23d5de8efb9aed Paul Burton 2015-09-22 412 *
68923cdc2eb341 Paul Burton 2017-08-12 413 * Configure the redirect/other region for the local core/VP (depending upon
68923cdc2eb341 Paul Burton 2017-08-12 414 * the CM revision) to target the specified @cluster, @core, @vp & register
68923cdc2eb341 Paul Burton 2017-08-12 415 * @block. Must be called before using the redirect/other region, and followed
68923cdc2eb341 Paul Burton 2017-08-12 416 * by a call to mips_cm_unlock_other() when access to the redirect/other region
68923cdc2eb341 Paul Burton 2017-08-12 417 * is complete.
68923cdc2eb341 Paul Burton 2017-08-12 418 *
68923cdc2eb341 Paul Burton 2017-08-12 419 * This function acquires a spinlock such that code between it &
68923cdc2eb341 Paul Burton 2017-08-12 420 * mips_cm_unlock_other() calls cannot be pre-empted by anything which may
68923cdc2eb341 Paul Burton 2017-08-12 421 * reconfigure the redirect/other region, and cannot be interfered with by
68923cdc2eb341 Paul Burton 2017-08-12 422 * another VP in the core. As such calls to this function should not be nested.
23d5de8efb9aed Paul Burton 2015-09-22 423 */
68923cdc2eb341 Paul Burton 2017-08-12 424 extern void mips_cm_lock_other(unsigned int cluster, unsigned int core,
68923cdc2eb341 Paul Burton 2017-08-12 425 unsigned int vp, unsigned int block);
23d5de8efb9aed Paul Burton 2015-09-22 426
23d5de8efb9aed Paul Burton 2015-09-22 427 /**
68923cdc2eb341 Paul Burton 2017-08-12 428 * mips_cm_unlock_other - unlock access to redirect/other region
23d5de8efb9aed Paul Burton 2015-09-22 429 *
68923cdc2eb341 Paul Burton 2017-08-12 430 * Must be called after mips_cm_lock_other() once all required access to the
68923cdc2eb341 Paul Burton 2017-08-12 431 * redirect/other region has been completed.
23d5de8efb9aed Paul Burton 2015-09-22 432 */
23d5de8efb9aed Paul Burton 2015-09-22 433 extern void mips_cm_unlock_other(void);
23d5de8efb9aed Paul Burton 2015-09-22 434
23d5de8efb9aed Paul Burton 2015-09-22 435 #else /* !CONFIG_MIPS_CM */
23d5de8efb9aed Paul Burton 2015-09-22 436
68923cdc2eb341 Paul Burton 2017-08-12 437 static inline void mips_cm_lock_other(unsigned int cluster, unsigned int core,
68923cdc2eb341 Paul Burton 2017-08-12 438 unsigned int vp, unsigned int block) { }
23d5de8efb9aed Paul Burton 2015-09-22 439 static inline void mips_cm_unlock_other(void) { }
23d5de8efb9aed Paul Burton 2015-09-22 440
23d5de8efb9aed Paul Burton 2015-09-22 441 #endif /* !CONFIG_MIPS_CM */
23d5de8efb9aed Paul Burton 2015-09-22 442
68923cdc2eb341 Paul Burton 2017-08-12 443 /**
68923cdc2eb341 Paul Burton 2017-08-12 444 * mips_cm_lock_other_cpu - lock access to redirect/other region
68923cdc2eb341 Paul Burton 2017-08-12 445 * @cpu: the other CPU whose register we want to access
68923cdc2eb341 Paul Burton 2017-08-12 446 *
68923cdc2eb341 Paul Burton 2017-08-12 447 * Configure the redirect/other region for the local core/VP (depending upon
68923cdc2eb341 Paul Burton 2017-08-12 448 * the CM revision) to target the specified @cpu & register @block. This is
68923cdc2eb341 Paul Burton 2017-08-12 449 * equivalent to calling mips_cm_lock_other() but accepts a Linux CPU number
68923cdc2eb341 Paul Burton 2017-08-12 450 * for convenience.
68923cdc2eb341 Paul Burton 2017-08-12 451 */
68923cdc2eb341 Paul Burton 2017-08-12 452 static inline void mips_cm_lock_other_cpu(unsigned int cpu, unsigned int block)
68923cdc2eb341 Paul Burton 2017-08-12 453 {
68923cdc2eb341 Paul Burton 2017-08-12 454 struct cpuinfo_mips *d = &cpu_data[cpu];
68923cdc2eb341 Paul Burton 2017-08-12 455
68923cdc2eb341 Paul Burton 2017-08-12 @456 mips_cm_lock_other(cpu_cluster(d), cpu_core(d), cpu_vpe_id(d), block);
68923cdc2eb341 Paul Burton 2017-08-12 457 }
68923cdc2eb341 Paul Burton 2017-08-12 458
:::::: The code at line 398 was first introduced by commit
:::::: f875a832d2028523f9b53c261b67e05a359bab8b MIPS: Abstract CPU core & VP(E) ID access through accessor functions
:::::: TO: Paul Burton <paul.burton@imgtec.com>
:::::: CC: Ralf Baechle <ralf@linux-mips.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 19312 bytes --]
next prev parent reply other threads:[~2020-04-12 5:25 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-12 3:20 [PATCH v2 00/11] MIPS: Topology & DeviceTree CPU rework v2 Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 01/11] MIPS: setup: Drop prefill_possible_map Jiaxun Yang
2020-04-14 8:21 ` Sudeep Holla
2020-04-14 8:39 ` Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 02/11] MIPS: prom: Add helper to parse CPU node in dt Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 03/11] arch_topology: Make it avilable for MIPS Jiaxun Yang
2020-04-14 8:25 ` Sudeep Holla
2020-04-12 3:20 ` [PATCH v2 04/11] arch_topology: Reset all cpus in reset_cpu_topology Jiaxun Yang
2020-04-14 8:27 ` Sudeep Holla
2020-04-14 8:35 ` Jiaxun Yang
2020-04-14 10:03 ` Sudeep Holla
2020-04-12 3:20 ` [PATCH v2 05/11] MIPS: Switch to arch_topology Jiaxun Yang
2020-04-12 5:24 ` kbuild test robot [this message]
2020-04-12 5:24 ` kbuild test robot
2020-04-12 5:24 ` kbuild test robot
2020-04-12 5:24 ` kbuild test robot
2020-04-12 7:49 ` Jiaxun Yang
2020-04-12 9:39 ` Marc Zyngier
2020-04-12 9:39 ` Marc Zyngier
2020-04-12 11:32 ` Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 06/11] MIPS: Kernel: Switch to new topology interface Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 07/11] MIPS: CPS & MT: " Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 08/11] irqchip: mips-cpu: " Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 09/11] MIPS: bmips: " Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 10/11] MIPS: nlm: " Jiaxun Yang
2020-04-12 3:20 ` [PATCH v2 11/11] MIPS: Loongson64: " Jiaxun Yang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202004121355.oP26ZAtx%lkp@intel.com \
--to=lkp@intel.com \
--cc=acme@kernel.org \
--cc=afzal.mohd.ma@gmail.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=alexios.zavras@intel.com \
--cc=allison@lohutok.net \
--cc=arnd@arndb.de \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=chenhc@lemote.com \
--cc=daniel.lezcano@linaro.org \
--cc=f.fainelli@gmail.com \
--cc=fancer.lancer@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=info@metux.net \
--cc=jason@lakedaemon.net \
--cc=jiaxun.yang@flygoat.com \
--cc=jolsa@redhat.com \
--cc=kbuild-all@lists.01.org \
--cc=kdasu.kdev@gmail.com \
--cc=kstewart@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux@rempel-privat.de \
--cc=mark.rutland@arm.com \
--cc=matt.redfearn@mips.com \
--cc=maz@kernel.org \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=oprofile-list@lists.sf.net \
--cc=paul@crapouillou.net \
--cc=paulburton@kernel.org \
--cc=peterx@redhat.com \
--cc=peterz@infradead.org \
--cc=rafael@kernel.org \
--cc=rfontana@redhat.com \
--cc=rric@kernel.org \
--cc=sudeep.holla@arm.com \
--cc=swinslow@gmail.com \
--cc=syq@debian.org \
--cc=tglx@linutronix.de \
--cc=tsbogend@alpha.franken.de \
--cc=vladimir.kondratiev@intel.com \
--cc=zhouyanjie@wanyeetech.com \
--cc=zhouyanjie@zoho.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.