All of lore.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Alexander Graf <agraf@suse.de>
Cc: "linuxppc-dev@ozlabs.org" <linuxppc-dev@ozlabs.org>,
	Paul Mackerras <paulus@samba.org>,
	"kvm@vger.kernel.org" <kvm@vger.kernel.org>
Subject: Re: [PATCH 03/13] kvm/powerpc: Fix the build for 32-bit Book 3S (classic) processors
Date: Thu, 12 May 2011 21:16:19 +1000	[thread overview]
Message-ID: <1305198979.29820.102.camel@pasglop> (raw)
In-Reply-To: <C5B8A119-56B6-467C-B3BD-01D5D7FA0773@suse.de>

On Thu, 2011-05-12 at 11:33 +0200, Alexander Graf wrote:
> Am 11.05.2011 um 12:39 schrieb Paul Mackerras <paulus@samba.org>:
> 
> > Commits a5d4f3ad3a ("powerpc: Base support for exceptions using
> > HSRR0/1") and 673b189a2e ("powerpc: Always use SPRN_SPRG_HSCRATCH0
> > when running in HV mode") cause compile and link errors for 32-bit
> > classic Book 3S processors when KVM is enabled.  This fixes these
> > errors.
> > 
> > Signed-off-by: Paul Mackerras <paulus@samba.org>
> > ---
> > arch/powerpc/include/asm/reg.h       |    5 +++++
> > arch/powerpc/kvm/book3s_rmhandlers.S |    2 ++
> > 2 files changed, 7 insertions(+), 0 deletions(-)
> > 
> > diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/reg.h
> > index 47e3416..05658b7 100644
> > --- a/arch/powerpc/include/asm/reg.h
> > +++ b/arch/powerpc/include/asm/reg.h
> > @@ -823,6 +823,11 @@
> >    FTR_SECTION_ELSE_NESTED(66);            \
> >    mtspr    SPRN_SPRG_HSCRATCH0,rX;            \
> >    ALT_FTR_SECTION_END_NESTED_IFCLR(CPU_FTR_HVMODE_206, 66)
> > +
> > +#else /* CONFIG_PPC_BOOK3S_64 */
> > +#define GET_SCRATCH0(rX)    mfspr    rX,SPRN_SPRG_SCRATCH0
> > +#define SET_SCRATCH0(rX)    mtspr    SPRN_SPRG_SCRATCH0,rX
> > +
> > #endif
> > 
> > #ifdef CONFIG_PPC_BOOK3E_64
> > diff --git a/arch/powerpc/kvm/book3s_rmhandlers.S b/arch/powerpc/kvm/book3s_rmhandlers.S
> > index ae99af6..1a1b344 100644
> > --- a/arch/powerpc/kvm/book3s_rmhandlers.S
> > +++ b/arch/powerpc/kvm/book3s_rmhandlers.S
> > @@ -112,7 +112,9 @@ INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_MACHINE_CHECK
> > INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_DATA_STORAGE
> > INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_INST_STORAGE
> > INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_EXTERNAL
> > +#ifdef CONFIG_PPC_BOOK3S_64
> > INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_EXTERNAL_HV
> 
> Hrm - I don't remember putting this one here. When did it get into the tree and why wasn't I CC'ed?

Because I did and I forgot :-)

The patch in question only marginally touched kvm, it's one in a series
that rework of the ppc64 exception vectors to better operate on modern
CPUs running in HV mode (deal with HSRR's vs SRR's etc...) and it needed
a small fixup to the KVM code due to 0x500 becoming "H" interrupts
(using HSRR's) on these.

Unfortunately, it looks like I didn't have KVM enabled in any of my
32-bit test configs and missed that little breakage.

I should have CCed you I suppose, I simply forgot as it wasn't primarily
a KVM related patch.

Cheers,
Ben.

WARNING: multiple messages have this Message-ID (diff)
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Alexander Graf <agraf@suse.de>
Cc: Paul Mackerras <paulus@samba.org>,
	"linuxppc-dev@ozlabs.org" <linuxppc-dev@ozlabs.org>,
	"kvm@vger.kernel.org" <kvm@vger.kernel.org>
Subject: Re: [PATCH 03/13] kvm/powerpc: Fix the build for 32-bit Book 3S (classic) processors
Date: Thu, 12 May 2011 21:16:19 +1000	[thread overview]
Message-ID: <1305198979.29820.102.camel@pasglop> (raw)
In-Reply-To: <C5B8A119-56B6-467C-B3BD-01D5D7FA0773@suse.de>

On Thu, 2011-05-12 at 11:33 +0200, Alexander Graf wrote:
> Am 11.05.2011 um 12:39 schrieb Paul Mackerras <paulus@samba.org>:
> 
> > Commits a5d4f3ad3a ("powerpc: Base support for exceptions using
> > HSRR0/1") and 673b189a2e ("powerpc: Always use SPRN_SPRG_HSCRATCH0
> > when running in HV mode") cause compile and link errors for 32-bit
> > classic Book 3S processors when KVM is enabled.  This fixes these
> > errors.
> > 
> > Signed-off-by: Paul Mackerras <paulus@samba.org>
> > ---
> > arch/powerpc/include/asm/reg.h       |    5 +++++
> > arch/powerpc/kvm/book3s_rmhandlers.S |    2 ++
> > 2 files changed, 7 insertions(+), 0 deletions(-)
> > 
> > diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/reg.h
> > index 47e3416..05658b7 100644
> > --- a/arch/powerpc/include/asm/reg.h
> > +++ b/arch/powerpc/include/asm/reg.h
> > @@ -823,6 +823,11 @@
> >    FTR_SECTION_ELSE_NESTED(66);            \
> >    mtspr    SPRN_SPRG_HSCRATCH0,rX;            \
> >    ALT_FTR_SECTION_END_NESTED_IFCLR(CPU_FTR_HVMODE_206, 66)
> > +
> > +#else /* CONFIG_PPC_BOOK3S_64 */
> > +#define GET_SCRATCH0(rX)    mfspr    rX,SPRN_SPRG_SCRATCH0
> > +#define SET_SCRATCH0(rX)    mtspr    SPRN_SPRG_SCRATCH0,rX
> > +
> > #endif
> > 
> > #ifdef CONFIG_PPC_BOOK3E_64
> > diff --git a/arch/powerpc/kvm/book3s_rmhandlers.S b/arch/powerpc/kvm/book3s_rmhandlers.S
> > index ae99af6..1a1b344 100644
> > --- a/arch/powerpc/kvm/book3s_rmhandlers.S
> > +++ b/arch/powerpc/kvm/book3s_rmhandlers.S
> > @@ -112,7 +112,9 @@ INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_MACHINE_CHECK
> > INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_DATA_STORAGE
> > INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_INST_STORAGE
> > INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_EXTERNAL
> > +#ifdef CONFIG_PPC_BOOK3S_64
> > INTERRUPT_TRAMPOLINE    BOOK3S_INTERRUPT_EXTERNAL_HV
> 
> Hrm - I don't remember putting this one here. When did it get into the tree and why wasn't I CC'ed?

Because I did and I forgot :-)

The patch in question only marginally touched kvm, it's one in a series
that rework of the ppc64 exception vectors to better operate on modern
CPUs running in HV mode (deal with HSRR's vs SRR's etc...) and it needed
a small fixup to the KVM code due to 0x500 becoming "H" interrupts
(using HSRR's) on these.

Unfortunately, it looks like I didn't have KVM enabled in any of my
32-bit test configs and missed that little breakage.

I should have CCed you I suppose, I simply forgot as it wasn't primarily
a KVM related patch.

Cheers,
Ben.


  parent reply	other threads:[~2011-05-12 11:16 UTC|newest]

Thread overview: 103+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-11 10:34 [PATCH 0/13] Hypervisor-mode KVM on POWER7 Paul Mackerras
2011-05-11 10:36 ` [PATCH 01/13] kvm/powerpc: Move fields between struct kvm_vcpu_arch and kvmppc_vcpu_book3s Paul Mackerras
2011-05-11 10:38 ` [PATCH 02/13] kvm/powerpc: Fix kvmppc_core_pending_dec Paul Mackerras
2011-05-11 10:39 ` [PATCH 03/13] kvm/powerpc: Fix the build for 32-bit Book 3S (classic) processors Paul Mackerras
2011-05-12  9:33   ` Alexander Graf
2011-05-12  9:33     ` Alexander Graf
2011-05-12 11:15     ` Paul Mackerras
2011-05-12 11:15       ` Paul Mackerras
2011-05-12 11:16     ` Benjamin Herrenschmidt [this message]
2011-05-12 11:16       ` Benjamin Herrenschmidt
2011-05-12 11:57       ` Alexander Graf
2011-05-12 11:57         ` Alexander Graf
2011-05-11 10:40 ` [PATCH 04/13] kvm/powerpc: Split out code from book3s.c into book3s_pr.c Paul Mackerras
2011-05-11 10:41 ` [PATCH 05/13] powerpc, kvm: Rework KVM checks in first-level interrupt handlers Paul Mackerras
2011-05-11 10:42 ` [PATCH 06/13] kvm/powerpc: Deliver program interrupts right away instead of queueing them Paul Mackerras
2011-05-11 10:42 ` [PATCH 07/13] kvm/powerpc: Pass init/destroy vm and prepare/commit memory region ops down Paul Mackerras
2011-05-11 10:43 ` [PATCH 08/13] kvm/powerpc: Move guest enter/exit down into subarch-specific code Paul Mackerras
2011-05-17 18:05   ` Marcelo Tosatti
2011-05-17 18:05     ` Marcelo Tosatti
2011-05-17 18:10     ` Marcelo Tosatti
2011-05-17 18:10       ` Marcelo Tosatti
2011-05-11 10:44 ` [PATCH 09/13] powerpc: Set up LPCR for running guest partitions Paul Mackerras
2011-05-11 10:44 ` [PATCH 10/13] kvm/powerpc: Add support for Book3S processors in hypervisor mode Paul Mackerras
2011-05-12  9:07   ` Avi Kivity
2011-05-12  9:07     ` Avi Kivity
2011-05-16  1:07     ` Paul Mackerras
2011-05-16  1:07       ` Paul Mackerras
2011-05-15 21:58   ` Alexander Graf
2011-05-15 21:58     ` Alexander Graf
2011-05-15 21:58     ` Alexander Graf
2011-05-16  5:58     ` [PATCH 10/13] kvm/powerpc: Add support for Book3S processors in Paul Mackerras
2011-05-16  5:58       ` [PATCH 10/13] kvm/powerpc: Add support for Book3S processors in hypervisor mode Paul Mackerras
2011-05-16  5:58       ` Paul Mackerras
2011-05-17 10:17       ` Alexander Graf
2011-05-17 10:17         ` Alexander Graf
2011-05-17 10:17         ` Alexander Graf
2011-05-27 10:33         ` [PATCH 10/13] kvm/powerpc: Add support for Book3S processors in Paul Mackerras
2011-05-27 10:33           ` [PATCH 10/13] kvm/powerpc: Add support for Book3S processors in hypervisor mode Paul Mackerras
2011-05-27 10:33           ` Paul Mackerras
2011-05-27 10:43           ` Alexander Graf
2011-05-27 10:43             ` Alexander Graf
2011-05-27 10:43             ` Alexander Graf
2011-05-27 20:59           ` Segher Boessenkool
2011-05-27 20:59             ` Segher Boessenkool
2011-05-27 20:59             ` Segher Boessenkool
2011-05-27 23:19             ` Alexander Graf
2011-05-27 23:19               ` Alexander Graf
2011-05-27 23:19               ` Alexander Graf
2011-05-28  1:07               ` Segher Boessenkool
2011-05-28  1:07                 ` Segher Boessenkool
2011-05-28  1:07                 ` Segher Boessenkool
2011-05-31 20:26                 ` Jimi Xenidis
2011-05-31 20:26                   ` Jimi Xenidis
2011-05-31 20:26                   ` Jimi Xenidis
2011-05-31 22:34                   ` Segher Boessenkool
2011-05-31 22:34                     ` Segher Boessenkool
2011-05-31 22:34                     ` Segher Boessenkool
2011-06-01  5:11                     ` [PATCH 10/13] kvm/powerpc: Add support for Book3S processors in Paul Mackerras
2011-06-01  5:11                       ` [PATCH 10/13] kvm/powerpc: Add support for Book3S processors in hypervisor mode Paul Mackerras
2011-06-01  5:11                       ` Paul Mackerras
2011-05-11 10:45 ` [PATCH 11/13] kvm/powerpc: Handle some PAPR hcalls in the kernel Paul Mackerras
2011-05-17  7:54   ` Alexander Graf
2011-05-17  7:54     ` Alexander Graf
2011-05-17 10:28     ` Paul Mackerras
2011-05-11 10:46 ` [PATCH 12/13] kvm/powerpc: Accelerate H_PUT_TCE by implementing it in real mode Paul Mackerras
2011-05-17  8:01   ` Alexander Graf
2011-05-17  8:01     ` Alexander Graf
2011-05-17  9:11     ` Benjamin Herrenschmidt
2011-05-17  9:11       ` Benjamin Herrenschmidt
2011-05-17  9:31       ` Alexander Graf
2011-05-17  9:31         ` Alexander Graf
2011-05-17  9:35         ` Benjamin Herrenschmidt
2011-05-17  9:35           ` Benjamin Herrenschmidt
2011-05-17  9:39           ` Alexander Graf
2011-05-17  9:39             ` Alexander Graf
2011-05-11 10:46 ` [PATCH 13/13] kvm/powerpc: Allow book3s_hv guests to use SMT processor modes Paul Mackerras
2011-05-11 13:44   ` Christoph Hellwig
2011-05-11 21:17     ` Paul Mackerras
2011-05-11 21:17       ` Paul Mackerras
2011-05-17  8:21   ` Alexander Graf
2011-05-17  8:21     ` Alexander Graf
2011-05-17 10:44     ` Paul Mackerras
2011-05-17 11:36       ` Alexander Graf
2011-05-17 11:36         ` Alexander Graf
2011-05-19  6:06         ` Paul Mackerras
2011-05-17  9:46 ` [PATCH 0/13] Hypervisor-mode KVM on POWER7 Alexander Graf
2011-05-17  9:46   ` Alexander Graf
2011-05-17 11:15   ` Paul Mackerras
2011-05-17 11:38     ` Alexander Graf
2011-05-17 11:38       ` Alexander Graf
2011-05-17 11:42       ` Avi Kivity
2011-05-17 11:42         ` Avi Kivity
2011-05-19  5:22         ` Paul Mackerras
2011-05-19  5:22           ` Paul Mackerras
2011-05-19  6:01           ` Alexander Graf
2011-05-19  6:01             ` Alexander Graf
2011-05-19  6:01             ` Alexander Graf
2011-05-21 16:41           ` Alexander Graf
2011-05-21 16:41             ` Alexander Graf
2011-05-21 17:00             ` Alexander Graf
2011-05-21 17:00               ` Alexander Graf
2011-05-21 18:15               ` Alexander Graf
2011-05-21 18:15                 ` Alexander Graf

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=1305198979.29820.102.camel@pasglop \
    --to=benh@kernel.crashing.org \
    --cc=agraf@suse.de \
    --cc=kvm@vger.kernel.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=paulus@samba.org \
    /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.