powerpc32: provide VIRT_CPU_ACCOUNTING
PATCH v7 1/1 powerpc32: provide VIRT_CPU_ACCOUNTING
This patch provides VIRT_CPU_ACCOUTING to PPC32 architecture. PPC32 doesn't have the PACA structure, so we use the task_info structure to store the accounting data.
In order to reuse on PPC32 the PPC64 functions, all u64 data has been replaced by 'unsigned long' so that it is u32 on PPC32 and u64 on PPC64
---
Changes in v3: unlike previous version of the patch that was inspired from IA64 architecture, this new version tries to reuse as much as possible the PPC64 implementation.
PPC32 doesn't have PACA and past discusion on v2 version has shown that it is not worth implementing a PACA in PPC32 architecture (see below benh opinion)
benh: PACA is actually a data structure and you really really don't want it on ppc32 :-) Having a register point to current works, having a register point to per-cpu data instead works too (ie, change what we do today), but don't introduce a PACA *please* :-)
Changes in v4: ACCOUNT_CPU_USER_ENTRY/EXIT() needed updates in other places than entry_32.S and entry_64.S (reported by kbuild-robot) Related defines in asm-offset.c need to be conditional to CONFIG_VIRT_CPU_ACCOUNTING_NATIVE (reported by kbuild-robot)
Changes in v5: Using PPC_LL et PPC_STL instead of defining new macros AC_LD and AC_STD
Changes in v6: jiffies64_to_cputime64() modified to avoid 64 bits div and mod on PPC32
Changes in v7: created a struct cpu_accounting_data which is common to PPC32 and PPC64
taken into account Scott's comments
arch/powerpc/Kconfig | 1 + arch/powerpc/include/asm/accounting.h | 24 +++++++++ arch/powerpc/include/asm/cputime.h | 14 +++-- arch/powerpc/include/asm/exception-64s.h | 2 +- arch/powerpc/include/asm/paca.h | 9 +--- arch/powerpc/include/asm/ppc_asm.h | 24 ++++----- arch/powerpc/include/asm/reg.h | 1 + arch/powerpc/include/asm/thread_info.h | 5 ++ arch/powerpc/kernel/asm-offsets.c | 23 +++++++-- arch/powerpc/kernel/entry_32.S | 17 ++++++ arch/powerpc/kernel/entry_64.S | 6 +-- arch/powerpc/kernel/exceptions-64e.S | 4 +- arch/powerpc/kernel/time.c | 89 +++++++++++++++++++++----------- arch/powerpc/platforms/Kconfig.cputype | 1 - 14 files changed, 157 insertions(+), 63 deletions(-) create mode 100644 arch/powerpc/include/asm/accounting.h
arch/powerpc/Kconfig +1 -0
@@ -159,6 +159,7 @@ config PPC select ARCH_HAS_DEVMEM_IS_ALLOWED select HAVE_ARCH_SECCOMP_FILTER select ARCH_HAS_UBSAN_SANITIZE_ALL + select HAVE_VIRT_CPU_ACCOUNTING config GENERIC_CSUM def_bool CPU_LITTLE_ENDIAN
arch/powerpc/include/asm/accounting.h new file +24 -0
@@ -0,0 +1,24 @@ +/* +* Common time accounting prototypes and such for all ppc machines. +* +* This program is free software; you can redistribute it and/or +* modify it under the terms of the GNU General Public License +* as published by the Free Software Foundation; either version +* 2 of the License, or (at your option) any later version. +*/ + +#ifndef __POWERPC_ACCOUNTING_H +#define __POWERPC_ACCOUNTING_H + +/* Stuff for accurate time accounting */ +struct cpu_accounting_data { +unsigned long user_time;/* accumulated usermode TB ticks */ +unsigned long system_time;/* accumulated system TB ticks */ +unsigned long user_time_scaled;/* accumulated usermode SPURR ticks */ +unsigned long starttime;/* TB value snapshot */ +unsigned long starttime_user;/* TB value on exit to usermode */ +unsigned long startspurr;/* SPURR value snapshot */ +unsigned long utime_sspurr;/* ->user_time when ->startspurr set */ +}; + +#endif
arch/powerpc/include/asm/cputime.h +11 -3
@@ -90,11 +90,10 @@ static inline void setup_cputime_one_jiffy(void)static inline cputime64_t jiffies64_to_cputime64 (const u64 jif) {u64 ct; -u64 sec; +u64 sec = jif;/* have to be a little careful about overflow */ - ct = jif %HZ ; - sec = jif /HZ ; + ct =do_div (sec,HZ );if (ct) { ct *= tb_ticks_per_sec;do_div (ct,HZ );
@@ -230,7 +229,16 @@ static inline cputime_t clock_t_to_cputime(const unsigned long clk)#define cputime64_to_clock_t (ct) cputime_to_clock_t((cputime_t)(ct)) +/* +* PPC64 uses PACA which is task independent for storing accounting data while +* PPC32 uses struct thread_info, therefore at task switch the accounting data +* has to be populated in the new task +*/ +#ifdef CONFIG_PPC64 static inline void arch_vtime_task_switch (struct task_struct *tsk) { } +#else +void arch_vtime_task_switch (struct task_struct *tsk); +#endif #endif /* __KERNEL__ */ #endif /* CONFIG_VIRT_CPU_ACCOUNTING_NATIVE */
arch/powerpc/include/asm/exception-64s.h +1 -1
@@ -287,7 +287,7 @@ do_kvm_##n: \std r0,GPR0 (r1 );/* save r0 in stackframe */ \std r10,GPR1 (r1 );/* save r1 in stackframe */ \ beq 4f; /* if from kernel mode */ \ -ACCOUNT_CPU_USER_ENTRY (r9, r10); \ +ACCOUNT_CPU_USER_ENTRY (r13, r9, r10); \SAVE_PPR (area, r9, r10); \ 4: EXCEPTION_PROLOG_COMMON_2(area) \EXCEPTION_PROLOG_COMMON_3 (n) \
arch/powerpc/include/asm/paca.h +2 -7
@@ -25,6 +25,7 @@#ifdef CONFIG_KVM_BOOK3S_64_HANDLER #include <asm/kvm_book3s_asm.h> #endif +#include <asm/accounting.h> registerstruct paca_struct *local_paca asm("r13" );
@@ -184,13 +185,7 @@ struct paca_struct {#endif /* Stuff for accurate time accounting */ -u64 user_time;/* accumulated usermode TB ticks */ -u64 system_time;/* accumulated system TB ticks */ -u64 user_time_scaled;/* accumulated usermode SPURR ticks */ -u64 starttime;/* TB value snapshot */ -u64 starttime_user;/* TB value on exit to usermode */ -u64 startspurr;/* SPURR value snapshot */ -u64 utime_sspurr;/* ->user_time when ->startspurr set */ +struct cpu_accounting_data accounting;u64 stolen_time;/* TB ticks taken by hypervisor */ u64 dtl_ridx;/* read index in dispatch log */ struct dtl_entry *dtl_curr;/* pointer corresponding to dtl_ridx */
arch/powerpc/include/asm/ppc_asm.h +12 -12
@@ -24,27 +24,27 @@*/ #ifndef CONFIG_VIRT_CPU_ACCOUNTING_NATIVE -#define ACCOUNT_CPU_USER_ENTRY (ra, rb) -#define ACCOUNT_CPU_USER_EXIT (ra, rb) +#define ACCOUNT_CPU_USER_ENTRY (ptr, ra, rb) +#define ACCOUNT_CPU_USER_EXIT (ptr, ra, rb)#define ACCOUNT_STOLEN_TIME #else -#define ACCOUNT_CPU_USER_ENTRY (ra, rb) \ +#define ACCOUNT_CPU_USER_ENTRY (ptr, ra, rb) \ MFTB(ra);/* get timebase */ \ -ld rb,PACA_STARTTIME_USER (r13 ); \ -std ra,PACA_STARTTIME (r13 ); \ +PPC_LL rb,ACCOUNT_STARTTIME_USER (ptr ); \ +PPC_STL ra,ACCOUNT_STARTTIME (ptr ); \subf rb,rb,ra;/* subtract start value */ \ -ld ra,PACA_USER_TIME (r13 ); \ +PPC_LL ra,ACCOUNT_USER_TIME (ptr ); \add ra,ra,rb;/* add on to user time */ \ -std ra,PACA_USER_TIME (r13 ); \ +PPC_STL ra,ACCOUNT_USER_TIME (ptr ); \ -#define ACCOUNT_CPU_USER_EXIT (ra, rb) \ +#define ACCOUNT_CPU_USER_EXIT (ptr, ra, rb) \ MFTB(ra);/* get timebase */ \ -ld rb,PACA_STARTTIME (r13 ); \ -std ra,PACA_STARTTIME_USER (r13 ); \ +PPC_LL rb,ACCOUNT_STARTTIME (ptr ); \ +PPC_STL ra,ACCOUNT_STARTTIME_USER (ptr ); \subf rb,rb,ra;/* subtract start value */ \ -ld ra,PACA_SYSTEM_TIME (r13 ); \ +PPC_LL ra,ACCOUNT_SYSTEM_TIME (ptr ); \add ra,ra,rb;/* add on to system time */ \ - std ra,PACA_SYSTEM_TIME(r13) + PPC_STL ra, ACCOUNT_SYSTEM_TIME(ptr)#ifdef CONFIG_PPC_SPLPAR #define ACCOUNT_STOLEN_TIME \
arch/powerpc/include/asm/reg.h +1 -0
@@ -1275,6 +1275,7 @@ static inline unsigned long mfvtb (void) asmvolatile ("mfspr %0, %1" :"=r" (rval) : \ "i" (SPRN_TBRU)); rval;})#endif +#define mftb () mftbl()#endif /* !__powerpc64__ */ #define mttbl (v) asm volatile("mttbl %0":: "r"(v))
arch/powerpc/include/asm/thread_info.h +5 -0
@@ -33,6 +33,7 @@#include <asm/processor.h> #include <asm/page.h> #include <linux/stringify.h> +#include <asm/accounting.h> /* * low level task data.
@@ -44,6 +45,10 @@ struct thread_info {<0 => BUG */ unsigned long local_flags;/* private flags for thread */ +#if defined(CONFIG_VIRT_CPU_ACCOUNTING_NATIVE ) && defined(CONFIG_PPC32 ) +struct cpu_accounting_data accounting; +#endif +/* low level flags - has atomic operations done on it */ unsigned long flags____cacheline_aligned_in_smp ; };
arch/powerpc/kernel/asm-offsets.c +19 -4
@@ -249,13 +249,28 @@ int main(void)DEFINE (PACAHWCPUID , offsetof(struct paca_struct , hw_cpu_id));DEFINE (PACAKEXECSTATE , offsetof(struct paca_struct , kexec_state));DEFINE (PACA_DSCR_DEFAULT , offsetof(struct paca_struct , dscr_default)); -DEFINE (PACA_STARTTIME , offsetof(struct paca_struct , starttime)); -DEFINE (PACA_STARTTIME_USER , offsetof(struct paca_struct , starttime_user)); -DEFINE (PACA_USER_TIME , offsetof(struct paca_struct , user_time)); -DEFINE (PACA_SYSTEM_TIME , offsetof(struct paca_struct , system_time)); +DEFINE (ACCOUNT_STARTTIME , + offsetof(struct paca_struct, accounting.starttime)); +DEFINE (ACCOUNT_STARTTIME_USER , + offsetof(struct paca_struct, accounting.starttime_user)); +DEFINE (ACCOUNT_USER_TIME , + offsetof(struct paca_struct, accounting.user_time)); +DEFINE (ACCOUNT_SYSTEM_TIME , + offsetof(struct paca_struct, accounting.system_time));DEFINE (PACA_TRAP_SAVE , offsetof(struct paca_struct , trap_save));DEFINE (PACA_NAPSTATELOST , offsetof(struct paca_struct , nap_state_lost));DEFINE (PACA_SPRG_VDSO , offsetof(struct paca_struct , sprg_vdso)); +#else /* CONFIG_PPC64 */ +#ifdef CONFIG_VIRT_CPU_ACCOUNTING_NATIVE +DEFINE (ACCOUNT_STARTTIME , + offsetof(struct thread_info, accounting.starttime)); +DEFINE (ACCOUNT_STARTTIME_USER , + offsetof(struct thread_info, accounting.starttime_user)); +DEFINE (ACCOUNT_USER_TIME , + offsetof(struct thread_info, accounting.user_time)); +DEFINE (ACCOUNT_SYSTEM_TIME , + offsetof(struct thread_info, accounting.system_time)); +#endif #endif /* CONFIG_PPC64 */ /* RTAS */
arch/powerpc/kernel/entry_32.S +17 -0
@@ -175,6 +175,12 @@ transfer_to_handler: addi r12,r12,-1 stw r12,4(r11) #endif +#ifdef CONFIG_VIRT_CPU_ACCOUNTING_NATIVE + CURRENT_THREAD_INFO(r9, r1) + tophys(r9, r9) + ACCOUNT_CPU_USER_ENTRY(r9, r11, r12) +#endif + b 3f 2: /* if from kernel, check interrupted DOZE/NAP mode and
@@ -398,6 +404,13 @@ BEGIN_FTR_SECTION lwarx r7,0,r1 END_FTR_SECTION_IFSET(CPU_FTR_NEED_PAIRED_STWCX) stwcx. r0,0,r1 /* to clear the reservation */ +#ifdef CONFIG_VIRT_CPU_ACCOUNTING_NATIVE + andi. r4,r8,MSR_PR + beq 3f + CURRENT_THREAD_INFO(r4, r1) + ACCOUNT_CPU_USER_EXIT(r4, r5, r7) +3: +#endif lwz r4,_LINK(r1) lwz r5,_CCR(r1) mtlr r4
@@ -769,6 +782,10 @@ restore_user: andis. r10,r0,DBCR0_IDM@h bnel- load_dbcr0 #endif +#ifdef CONFIG_VIRT_CPU_ACCOUNTING_NATIVE + CURRENT_THREAD_INFO(r9, r1) + ACCOUNT_CPU_USER_EXIT(r9, r10, r11) +#endif b restore
arch/powerpc/kernel/entry_64.S +3 -3
@@ -70,7 +70,7 @@ END_FTR_SECTION_IFSET(CPU_FTR_TM) std r0,GPR0(r1) std r10,GPR1(r1) beq 2f /* if from kernel mode */ - ACCOUNT_CPU_USER_ENTRY(r10, r11) + ACCOUNT_CPU_USER_ENTRY(r13, r10, r11) 2: std r2,GPR2(r1) std r3,GPR3(r1) mfcr r2
@@ -222,7 +222,7 @@ END_FTR_SECTION_IFCLR(CPU_FTR_STCX_CHECKS_ADDRESS) ld r4,_LINK(r1) beq- 1f - ACCOUNT_CPU_USER_EXIT(r11, r12) + ACCOUNT_CPU_USER_EXIT(r13, r11, r12) BEGIN_FTR_SECTION HMT_MEDIUM_LOW
@@ -822,7 +822,7 @@ END_FTR_SECTION_IFSET(CPU_FTR_HAS_PPR) BEGIN_FTR_SECTION mtspr SPRN_PPR,r2 /* Restore PPR */ END_FTR_SECTION_IFSET(CPU_FTR_HAS_PPR) - ACCOUNT_CPU_USER_EXIT(r2, r4) + ACCOUNT_CPU_USER_EXIT(r13, r2, r4) REST_GPR(13, r1) 1: mtspr SPRN_SRR1,r3
arch/powerpc/kernel/exceptions-64e.S +2 -2
@@ -386,7 +386,7 @@ exc_##n##_common: \ std r10,_NIP(r1); /* save SRR0 to stackframe */ \ std r11,_MSR(r1); /* save SRR1 to stackframe */ \ beq 2f; /* if from kernel mode */ \ - ACCOUNT_CPU_USER_ENTRY(r10,r11);/* accounting (uses cr0+eq) */ \ + ACCOUNT_CPU_USER_ENTRY(r13,r10,r11);/* accounting (uses cr0+eq) */ \ 2: ld r3,excf+EX_R10(r13); /* get back r10 */ \ ld r4,excf+EX_R11(r13); /* get back r11 */ \ mfspr r5,scratch; /* get back r13 */ \
@@ -1059,7 +1059,7 @@ fast_exception_return: andi. r6,r10,MSR_PR REST_2GPRS(6, r1) beq 1f - ACCOUNT_CPU_USER_EXIT(r10, r11) + ACCOUNT_CPU_USER_EXIT(r13, r10, r11) ld r0,GPR13(r1) 1: stdcx. r0,0,r1 /* to clear the reservation */
arch/powerpc/kernel/time.c +59 -30
169 lines not on this page · raw message
arch/powerpc/platforms/Kconfig.cputype +0 -1
@@ -1,7 +1,6 @@ config PPC64 bool "64-bit kernel" default n - select HAVE_VIRT_CPU_ACCOUNTING select ZLIB_DEFLATE help This option selects whether a 32-bit or a 64-bit kernel
Signature · 1 line
2.1.0
kbuild test robot
build botreproduce: wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree…
Hi Christophe,
[auto build test ERROR on powerpc/next]
[also build test ERROR on v4.5-rc5 next-20160223]
[if your patch is applied to the wrong git tree, please drop us a note to help improving the system]
url: https://github.com/0day-ci/linux/commits/Christophe-Leroy/powerpc32-provide-VIRT_CPU_ACCOUNTING/20160224-010322 base: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next config: powerpc-defconfig (attached as .config)
reproduce:
wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=powerpc
All errors (new ones prefixed by >>):
arch/powerpc/kernel/time.c: In function 'accumulate_stolen_time':
>> arch/powerpc/kernel/time.c:274:6: error: 'struct cpu_accounting_data' has no member named 'stolen_time'
acct->stolen_time += ust + sst;
^
arch/powerpc/kernel/time.c: In function 'calculate_stolen_time':
arch/powerpc/kernel/time.c:289:16: error: 'struct cpu_accounting_data' has no member named 'stolen_time'
stolen += acct->stolen_time;
^
arch/powerpc/kernel/time.c:290:6: error: 'struct cpu_accounting_data' has no member named 'stolen_time'
acct->stolen_time = 0;
^
--
arch/powerpc/xmon/xmon.c: In function 'dump_one_paca':
>> arch/powerpc/xmon/xmon.c:2130:63: error: 'struct paca_struct' has no member named 'user_time'
printf(" %-*s = %#-*"format"\t(0x%lx)\n", 20, #name, 18, paca->name, \
^
arch/powerpc/xmon/xmon.c:2200:2: note: in expansion of macro 'DUMP'
DUMP(p, user_time, "llx");
^
In file included from include/linux/compiler.h:56:0,
from include/uapi/linux/stddef.h:1,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/uapi/linux/capability.h:16,
from include/linux/capability.h:15,
from include/linux/sched.h:15,
from arch/powerpc/xmon/xmon.c:14:
include/linux/compiler-gcc.h:158:2: error: 'struct paca_struct' has no member named 'user_time'
__builtin_offsetof(a, b)
^
include/linux/stddef.h:16:32: note: in expansion of macro '__compiler_offsetof'
#define offsetof(TYPE, MEMBER) __compiler_offsetof(TYPE, MEMBER)
^
arch/powerpc/xmon/xmon.c:2131:3: note: in expansion of macro 'offsetof'
offsetof(struct paca_struct, name));
^
arch/powerpc/xmon/xmon.c:2200:2: note: in expansion of macro 'DUMP'
DUMP(p, user_time, "llx");
^
>> arch/powerpc/xmon/xmon.c:2130:63: error: 'struct paca_struct' has no member named 'system_time'
printf(" %-*s = %#-*"format"\t(0x%lx)\n", 20, #name, 18, paca->name, \
^
arch/powerpc/xmon/xmon.c:2201:2: note: in expansion of macro 'DUMP'
DUMP(p, system_time, "llx");
^
In file included from include/linux/compiler.h:56:0,
from include/uapi/linux/stddef.h:1,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/uapi/linux/capability.h:16,
from include/linux/capability.h:15,
from include/linux/sched.h:15,
from arch/powerpc/xmon/xmon.c:14:
include/linux/compiler-gcc.h:158:2: error: 'struct paca_struct' has no member named 'system_time'
__builtin_offsetof(a, b)
^
include/linux/stddef.h:16:32: note: in expansion of macro '__compiler_offsetof'
#define offsetof(TYPE, MEMBER) __compiler_offsetof(TYPE, MEMBER)
^
arch/powerpc/xmon/xmon.c:2131:3: note: in expansion of macro 'offsetof'
offsetof(struct paca_struct, name));
^
arch/powerpc/xmon/xmon.c:2201:2: note: in expansion of macro 'DUMP'
DUMP(p, system_time, "llx");
^
>> arch/powerpc/xmon/xmon.c:2130:63: error: 'struct paca_struct' has no member named 'user_time_scaled'
printf(" %-*s = %#-*"format"\t(0x%lx)\n", 20, #name, 18, paca->name, \
^
arch/powerpc/xmon/xmon.c:2202:2: note: in expansion of macro 'DUMP'
DUMP(p, user_time_scaled, "llx");
^
In file included from include/linux/compiler.h:56:0,
from include/uapi/linux/stddef.h:1,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/uapi/linux/capability.h:16,
from include/linux/capability.h:15,
from include/linux/sched.h:15,
from arch/powerpc/xmon/xmon.c:14:
include/linux/compiler-gcc.h:158:2: error: 'struct paca_struct' has no member named 'user_time_scaled'
__builtin_offsetof(a, b)
^
include/linux/stddef.h:16:32: note: in expansion of macro '__compiler_offsetof'
#define offsetof(TYPE, MEMBER) __compiler_offsetof(TYPE, MEMBER)
^
arch/powerpc/xmon/xmon.c:2131:3: note: in expansion of macro 'offsetof'
offsetof(struct paca_struct, name));
^
arch/powerpc/xmon/xmon.c:2202:2: note: in expansion of macro 'DUMP'
DUMP(p, user_time_scaled, "llx");
^
>> arch/powerpc/xmon/xmon.c:2130:63: error: 'struct paca_struct' has no member named 'starttime'
printf(" %-*s = %#-*"format"\t(0x%lx)\n", 20, #name, 18, paca->name, \
^
arch/powerpc/xmon/xmon.c:2203:2: note: in expansion of macro 'DUMP'
DUMP(p, starttime, "llx");
^
In file included from include/linux/compiler.h:56:0,
from include/uapi/linux/stddef.h:1,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/uapi/linux/capability.h:16,
from include/linux/capability.h:15,
from include/linux/sched.h:15,
from arch/powerpc/xmon/xmon.c:14:
include/linux/compiler-gcc.h:158:2: error: 'struct paca_struct' has no member named 'starttime'
__builtin_offsetof(a, b)
^
include/linux/stddef.h:16:32: note: in expansion of macro '__compiler_offsetof'
#define offsetof(TYPE, MEMBER) __compiler_offsetof(TYPE, MEMBER)
^
arch/powerpc/xmon/xmon.c:2131:3: note: in expansion of macro 'offsetof'
offsetof(struct paca_struct, name));
^
arch/powerpc/xmon/xmon.c:2203:2: note: in expansion of macro 'DUMP'
DUMP(p, starttime, "llx");
^
>> arch/powerpc/xmon/xmon.c:2130:63: error: 'struct paca_struct' has no member named 'starttime_user'
printf(" %-*s = %#-*"format"\t(0x%lx)\n", 20, #name, 18, paca->name, \
^
arch/powerpc/xmon/xmon.c:2204:2: note: in expansion of macro 'DUMP'
DUMP(p, starttime_user, "llx");
^
In file included from include/linux/compiler.h:56:0,
from include/uapi/linux/stddef.h:1,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/uapi/linux/capability.h:16,
from include/linux/capability.h:15,
from include/linux/sched.h:15,
from arch/powerpc/xmon/xmon.c:14:
include/linux/compiler-gcc.h:158:2: error: 'struct paca_struct' has no member named 'starttime_user'
__builtin_offsetof(a, b)
^
include/linux/stddef.h:16:32: note: in expansion of macro '__compiler_offsetof'
#define offsetof(TYPE, MEMBER) __compiler_offsetof(TYPE, MEMBER)
^
arch/powerpc/xmon/xmon.c:2131:3: note: in expansion of macro 'offsetof'
offsetof(struct paca_struct, name));
^
arch/powerpc/xmon/xmon.c:2204:2: note: in expansion of macro 'DUMP'
DUMP(p, starttime_user, "llx");
^
>> arch/powerpc/xmon/xmon.c:2130:63: error: 'struct paca_struct' has no member named 'startspurr'
printf(" %-*s = %#-*"format"\t(0x%lx)\n", 20, #name, 18, paca->name, \
^
arch/powerpc/xmon/xmon.c:2205:2: note: in expansion of macro 'DUMP'
DUMP(p, startspurr, "llx");
^
In file included from include/linux/compiler.h:56:0,
from include/uapi/linux/stddef.h:1,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/uapi/linux/capability.h:16,
from include/linux/capability.h:15,
from include/linux/sched.h:15,
from arch/powerpc/xmon/xmon.c:14:
include/linux/compiler-gcc.h:158:2: error: 'struct paca_struct' has no member named 'startspurr'
__builtin_offsetof(a, b)
^
include/linux/stddef.h:16:32: note: in expansion of macro '__compiler_offsetof'
#define offsetof(TYPE, MEMBER) __compiler_offsetof(TYPE, MEMBER)
^
arch/powerpc/xmon/xmon.c:2131:3: note: in expansion of macro 'offsetof'
offsetof(struct paca_struct, name));
^
arch/powerpc/xmon/xmon.c:2205:2: note: in expansion of macro 'DUMP'
DUMP(p, startspurr, "llx");
^
>> arch/powerpc/xmon/xmon.c:2130:63: error: 'struct paca_struct' has no member named 'utime_sspurr'
printf(" %-*s = %#-*"format"\t(0x%lx)\n", 20, #name, 18, paca->name, \
^
arch/powerpc/xmon/xmon.c:2206:2: note: in expansion of macro 'DUMP'
DUMP(p, utime_sspurr, "llx");
^
In file included from include/linux/compiler.h:56:0,
from include/uapi/linux/stddef.h:1,
from include/linux/stddef.h:4,
from include/uapi/linux/posix_types.h:4,
from include/uapi/linux/types.h:13,
from include/linux/types.h:5,
from include/uapi/linux/capability.h:16,
from include/linux/capability.h:15,
from include/linux/sched.h:15,
from arch/powerpc/xmon/xmon.c:14:
include/linux/compiler-gcc.h:158:2: error: 'struct paca_struct' has no member named 'utime_sspurr'
__builtin_offsetof(a, b)
^
include/linux/stddef.h:16:32: note: in expansion of macro '__compiler_offsetof'
#define offsetof(TYPE, MEMBER) __compiler_offsetof(TYPE, MEMBER)
^
arch/powerpc/xmon/xmon.c:2131:3: note: in expansion of macro 'offsetof'
offsetof(struct paca_struct, name));
^
arch/powerpc/xmon/xmon.c:2206:2: note: in expansion of macro 'DUMP'
DUMP(p, utime_sspurr, "llx");
^vim +274 arch/powerpc/kernel/time.c
268 local_paca->soft_enabled = 0;
269
270 sst = scan_dispatch_log(acct->starttime_user);
271 ust = scan_dispatch_log(acct->starttime);
272 acct->system_time -= sst;
273 acct->user_time -= ust;
> 274 acct->stolen_time += ust + sst;
275
276 local_paca->soft_enabled = save_soft_enabled;
277 }
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Quoted 7 lines · kbuild test robot
Hi Christophe,
[auto build test ERROR on powerpc/next]
[also build test ERROR on v4.5-rc5 next-20160223]
[if your patch is applied to the wrong git tree, please drop us a note to help improving the system]
Quoted 11 lines
url: https://github.com/0day-ci/linux/commits/Christophe-Leroy/powerpc32-
provide-VIRT_CPU_ACCOUNTING/20160224-010322
base: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git ne
xt
config: powerpc-defconfig (attached as .config)
reproduce:
wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/
plain/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree make.cross ARCH=powerpc
I've been seeing a lot of these build failure reports from your patches -- can you please test build on an appropriate variety of configs before submitting?
-Scott
Quoted 19 lines · Scott Wood
Quoted 7 lines · kbuild test robot
Hi Christophe,
[auto build test ERROR on powerpc/next]
[also build test ERROR on v4.5-rc5 next-20160223]
[if your patch is applied to the wrong git tree, please drop us a note to help improving the system]Quoted 11 lines
url: https://github.com/0day-ci/linux/commits/Christophe-Leroy/powerpc32-
provide-VIRT_CPU_ACCOUNTING/20160224-010322
base: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git ne
xt
config: powerpc-defconfig (attached as .config)
reproduce:
wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/
plain/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree make.cross ARCH=powerpc
Quoted 4 lines
I've been seeing a lot of these build failure reports from your patches -- can you please test build on an appropriate variety of configs before submitting?
I usually test several PPC32 configs, but I only have a PPC32 compiler, therefore I'm not able to test PPC64 configs. I'll see what I can do.
Christophe
---
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast.
https://www.avast.com/antivirus
Quoted 31 lines · christophe leroy
Quoted 23 lines · Scott Wood
Quoted 8 lines · kbuild test robot
Hi Christophe,
[auto build test ERROR on powerpc/next]
[also build test ERROR on v4.5-rc5 next-20160223]
[if your patch is applied to the wrong git tree, please drop us a note to
help improving the system]Quoted 14 lines
url:
https://github.com/0day-ci/linux/commits/Christophe-Leroy/powerpc32-
provide-VIRT_CPU_ACCOUNTING/20160224-010322
base:
https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git ne xt
config: powerpc-defconfig (attached as .config) reproduce:
wget
https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/
plain/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree make.cross ARCH=powerpcQuoted 6 lines
I've been seeing a lot of these build failure reports from your patches -- can
you please test build on an appropriate variety of configs before submitting?
Quoted 3 lines
I usually test several PPC32 configs, but I only have a PPC32 compiler, therefore I'm not able to test PPC64 configs.
I'll see what I can do.
Get a ppc64 compiler.
https://www.kernel.org/pub/tools/crosstool/
-Scott