mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Paolo Bonzini <pbonzini@redhat.com>,
	linux-kernel@vger.kernel.org, kvm@vger.kernel.org
Subject: Re: [PATCH] kvm: do not handle APIC access page if in-kernel irqchip is not in use
Date: Thu, 02 Oct 2014 18:50:17 +0200	[thread overview]
Message-ID: <542D8249.5040009@siemens.com> (raw)
In-Reply-To: <1412251225-1686-1-git-send-email-pbonzini@redhat.com>

On 2014-10-02 14:00, Paolo Bonzini wrote:
> This fixes the following OOPS:
> 
>    loaded kvm module (v3.17-rc1-168-gcec26bc)
>    BUG: unable to handle kernel paging request at fffffffffffffffe
>    IP: [<ffffffff81168449>] put_page+0x9/0x30
>    PGD 1e15067 PUD 1e17067 PMD 0
>    Oops: 0000 [#1] PREEMPT SMP
>     [<ffffffffa063271d>] ? kvm_vcpu_reload_apic_access_page+0x5d/0x70 [kvm]
>     [<ffffffffa013b6db>] vmx_vcpu_reset+0x21b/0x470 [kvm_intel]
>     [<ffffffffa0658816>] ? kvm_pmu_reset+0x76/0xb0 [kvm]
>     [<ffffffffa064032a>] kvm_vcpu_reset+0x15a/0x1b0 [kvm]
>     [<ffffffffa06403ac>] kvm_arch_vcpu_setup+0x2c/0x50 [kvm]
>     [<ffffffffa062e540>] kvm_vm_ioctl+0x200/0x780 [kvm]
>     [<ffffffff81212170>] do_vfs_ioctl+0x2d0/0x4b0
>     [<ffffffff8108bd99>] ? __mmdrop+0x69/0xb0
>     [<ffffffff812123d1>] SyS_ioctl+0x81/0xa0
>     [<ffffffff8112a6f6>] ? __audit_syscall_exit+0x1f6/0x2a0
>     [<ffffffff817229e9>] system_call_fastpath+0x16/0x1b
>    Code: c6 78 ce a3 81 4c 89 e7 e8 d9 80 ff ff 0f 0b 4c 89 e7 e8 8f f6 ff ff e9 fa fe ff ff 66 2e 0f 1f 84 00 00 00 00 00 66 66 66 66 90 <48> f7 07 00 c0 00 00 55 48 89 e5 75 1e 8b 47 1c 85 c0 74 27 f0
>    RIP  [<ffffffff81193045>] put_page+0x5/0x50
> 
> when not using the in-kernel irqchip ("-machine kernel_irqchip=off"
> with QEMU).
> 
> Reported-by: Jan Kiszka <jan.kiszka@siemens.com>
> Fixes: 4256f43f9fab91e1c17b5846a240cf4b66a768a8
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  arch/x86/kvm/x86.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
> index 6857257f3810..5430e4b0af29 100644
> --- a/arch/x86/kvm/x86.c
> +++ b/arch/x86/kvm/x86.c
> @@ -6030,6 +6030,9 @@ void kvm_vcpu_reload_apic_access_page(struct kvm_vcpu *vcpu)
>  {
>  	struct page *page = NULL;
>  
> +	if (!irqchip_in_kernel(vcpu->kvm))
> +		return;
> +
>  	if (!kvm_x86_ops->set_apic_access_page_addr)
>  		return;
>  
> 

Works fine here.

Jan

-- 
Siemens AG, Corporate Technology, CT RTC ITP SES-DE
Corporate Competence Center Embedded Linux

      reply	other threads:[~2014-10-02 16:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-02 12:00 Paolo Bonzini
2014-10-02 16:50 ` Jan Kiszka [this message]

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=542D8249.5040009@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pbonzini@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome