Message ID | 1473200999-123004-2-git-send-email-pbonzini@redhat.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Hi Paolo,
[auto build test ERROR on tip/x86/core]
[also build test ERROR on v4.8-rc5 next-20160906]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
[Suggest to use git(>=2.9.0) format-patch --base=<commit> (or --base=auto for convenience) to record what (public, well-known) commit your patch series was built on]
[Check https://git-scm.com/docs/git-format-patch for more information]
url: https://github.com/0day-ci/linux/commits/Paolo-Bonzini/if-running-under-KVM-use-kvmclock-to-compute-TSC-deadline-value/20160907-131553
config: i386-defconfig (attached as .config)
compiler: gcc-6 (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
# save the attached .config to linux build tree
make ARCH=i386
All errors (new ones prefixed by >>):
arch/x86/kernel/apic/apic.c: In function 'smp_apic_timer_interrupt':
>> arch/x86/kernel/apic/apic.c:931:2: error: implicit declaration of function 'local_apic_timer_interrupt' [-Werror=implicit-function-declaration]
local_apic_timer_interrupt();
^~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +/local_apic_timer_interrupt +931 arch/x86/kernel/apic/apic.c
eddc0e92 arch/x86/kernel/apic/apic.c Seiji Aguchi 2013-06-20 925 *
0e078e2f arch/x86/kernel/apic_64.c Thomas Gleixner 2008-01-30 926 * update_process_times() expects us to have done irq_enter().
0e078e2f arch/x86/kernel/apic_64.c Thomas Gleixner 2008-01-30 927 * Besides, if we don't timer interrupts ignore the global
0e078e2f arch/x86/kernel/apic_64.c Thomas Gleixner 2008-01-30 928 * interrupt lock, which is the WrongThing (tm) to do.
0e078e2f arch/x86/kernel/apic_64.c Thomas Gleixner 2008-01-30 929 */
eddc0e92 arch/x86/kernel/apic/apic.c Seiji Aguchi 2013-06-20 930 entering_ack_irq();
0e078e2f arch/x86/kernel/apic_64.c Thomas Gleixner 2008-01-30 @931 local_apic_timer_interrupt();
eddc0e92 arch/x86/kernel/apic/apic.c Seiji Aguchi 2013-06-20 932 exiting_irq();
274cfe59 arch/x86/kernel/apic_64.c Cyrill Gorcunov 2008-08-16 933
0e078e2f arch/x86/kernel/apic_64.c Thomas Gleixner 2008-01-30 934 set_irq_regs(old_regs);
:::::: The code at line 931 was first introduced by commit
:::::: 0e078e2f5060e06f9b3f32e55665ea835343440e x86: prepare merging arch/x86/kernel/apic_32/64.c
:::::: TO: Thomas Gleixner <tglx@linutronix.de>
:::::: CC: Ingo Molnar <mingo@elte.hu>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Hi Paolo, [auto build test ERROR on tip/x86/core] [also build test ERROR on v4.8-rc5 next-20160906] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] [Suggest to use git(>=2.9.0) format-patch --base=<commit> (or --base=auto for convenience) to record what (public, well-known) commit your patch series was built on] [Check https://git-scm.com/docs/git-format-patch for more information] url: https://github.com/0day-ci/linux/commits/Paolo-Bonzini/if-running-under-KVM-use-kvmclock-to-compute-TSC-deadline-value/20160907-131553 config: i386-randconfig-s1-201636 (attached as .config) compiler: gcc-6 (Debian 6.1.1-9) 6.1.1 20160705 reproduce: # save the attached .config to linux build tree make ARCH=i386 All errors (new ones prefixed by >>): >> arch/x86/kernel/paravirt.c:313:32: error: 'native_local_apic_timer_interrupt' undeclared here (not in a function) .local_apic_timer_interrupt = native_local_apic_timer_interrupt, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ vim +/native_local_apic_timer_interrupt +313 arch/x86/kernel/paravirt.c 307 .patch = native_patch, 308 }; 309 310 struct pv_time_ops pv_time_ops = { 311 .sched_clock = native_sched_clock, 312 .steal_clock = native_steal_clock, > 313 .local_apic_timer_interrupt = native_local_apic_timer_interrupt, 314 }; 315 316 __visible struct pv_irq_ops pv_irq_ops = { --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation
diff --git a/arch/x86/include/asm/apic.h b/arch/x86/include/asm/apic.h index 124357773ffa..f6e0bad1cde2 100644 --- a/arch/x86/include/asm/apic.h +++ b/arch/x86/include/asm/apic.h @@ -109,6 +109,7 @@ extern void native_apic_wait_icr_idle(void); extern u32 native_safe_apic_wait_icr_idle(void); extern void native_apic_icr_write(u32 low, u32 id); extern u64 native_apic_icr_read(void); +extern void native_local_apic_timer_interrupt(void); static inline bool apic_is_x2apic_enabled(void) { diff --git a/arch/x86/include/asm/paravirt.h b/arch/x86/include/asm/paravirt.h index 2970d22d7766..71ec3a73745f 100644 --- a/arch/x86/include/asm/paravirt.h +++ b/arch/x86/include/asm/paravirt.h @@ -197,6 +197,11 @@ static inline u64 paravirt_steal_clock(int cpu) return PVOP_CALL1(u64, pv_time_ops.steal_clock, cpu); } +static inline void local_apic_timer_interrupt(void) +{ + PVOP_VCALL0(pv_time_ops.local_apic_timer_interrupt); +} + static inline unsigned long long paravirt_read_pmc(int counter) { return PVOP_CALL1(u64, pv_cpu_ops.read_pmc, counter); diff --git a/arch/x86/include/asm/paravirt_types.h b/arch/x86/include/asm/paravirt_types.h index 7fa9e7740ba3..ea1f27400098 100644 --- a/arch/x86/include/asm/paravirt_types.h +++ b/arch/x86/include/asm/paravirt_types.h @@ -96,6 +96,7 @@ struct pv_lazy_ops { struct pv_time_ops { unsigned long long (*sched_clock)(void); unsigned long long (*steal_clock)(int cpu); + void (*local_apic_timer_interrupt)(void); }; struct pv_cpu_ops { diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c index cea4fc19e844..5b63bec7d0af 100644 --- a/arch/x86/kernel/apic/apic.c +++ b/arch/x86/kernel/apic/apic.c @@ -902,7 +902,7 @@ void setup_secondary_APIC_clock(void) /* * The guts of the apic timer interrupt */ -static void local_apic_timer_interrupt(void) +void native_local_apic_timer_interrupt(void) { int cpu = smp_processor_id(); struct clock_event_device *evt = &per_cpu(lapic_events, cpu); diff --git a/arch/x86/kernel/paravirt.c b/arch/x86/kernel/paravirt.c index ad5bc9578a73..0e056271d714 100644 --- a/arch/x86/kernel/paravirt.c +++ b/arch/x86/kernel/paravirt.c @@ -310,6 +310,7 @@ struct pv_init_ops pv_init_ops = { struct pv_time_ops pv_time_ops = { .sched_clock = native_sched_clock, .steal_clock = native_steal_clock, + .local_apic_timer_interrupt = native_local_apic_timer_interrupt, }; __visible struct pv_irq_ops pv_irq_ops = {
local_apic_timer_interrupt refers to a static clockevent in apic.c. Paravirtualized implementations need to check a different clockevent, so allow customizing the guts of the APIC timer interrupt. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> --- arch/x86/include/asm/apic.h | 1 + arch/x86/include/asm/paravirt.h | 5 +++++ arch/x86/include/asm/paravirt_types.h | 1 + arch/x86/kernel/apic/apic.c | 2 +- arch/x86/kernel/paravirt.c | 1 + 5 files changed, 9 insertions(+), 1 deletion(-)