linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Alistair Popple <alistair@popple.id.au>
To: Michael Ellerman <mpe@ellerman.id.au>
Cc: Jordan Niethe <jniethe5@gmail.com>,
	linuxppc-dev@lists.ozlabs.org, Joel Stanley <joel@jms.id.au>
Subject: Re: [PATCH v2] PPC: Set reserved PCR bits
Date: Tue, 17 Sep 2019 10:48:14 +1000	[thread overview]
Message-ID: <2120353.GbO1pRtziF@townsend> (raw)
In-Reply-To: <877e68tvtl.fsf@mpe.ellerman.id.au>

Those definitions were introduced in a previous commit so I've posted a new 
series to fix the definitions first. Thanks.

- Alistair

On Monday, 16 September 2019 7:49:26 PM AEST Michael Ellerman wrote:
> Alistair Popple <alistair@popple.id.au> writes:
> > Currently the reserved bits of the Processor Compatibility Register
> > (PCR) are cleared as per the Programming Note in Section 1.3.3 of
> > version 3.0B of the Power ISA. This causes all new architecture
> > features to be made available when running on newer processors with
> > new architecture features added to the PCR as bits must be set to
> > disable a given feature.
> >
> > For example to disable new features added as part of Version 2.07 of
> > the ISA the corresponding bit in the PCR needs to be set.
> >
> > As new processor features generally require explicit kernel support
> > they should be disabled until such support is implemented. Therefore
> > kernels should set all unknown/reserved bits in the PCR such that any
> > new architecture features which the kernel does not currently know
> > about get disabled.
> >
> > An update is planned to the ISA to clarify that the PCR is an
> > exception to the Programming Note on reserved bits in Section 1.3.3.
> >
> > Signed-off-by: Alistair Popple <alistair@popple.id.au>
> > Signed-off-by: Jordan Niethe <jniethe5@gmail.com>
> > Tested-by: Joel Stanley <joel@jms.id.au>
> > ---
> > v2: Added some clarifications to the commit message
> > ---
> >  arch/powerpc/include/asm/reg.h          |  3 +++
> >  arch/powerpc/kernel/cpu_setup_power.S   |  6 ++++++
> >  arch/powerpc/kernel/dt_cpu_ftrs.c       |  3 ++-
> >  arch/powerpc/kvm/book3s_hv.c            | 11 +++++++----
> >  arch/powerpc/kvm/book3s_hv_nested.c     |  6 +++---
> >  arch/powerpc/kvm/book3s_hv_rmhandlers.S | 10 ++++++----
> >  6 files changed, 27 insertions(+), 12 deletions(-)
> >
> > diff --git a/arch/powerpc/include/asm/reg.h b/arch/powerpc/include/asm/
reg.h
> > index 10caa145f98b..258435c75c43 100644
> > --- a/arch/powerpc/include/asm/reg.h
> > +++ b/arch/powerpc/include/asm/reg.h
> > @@ -475,6 +475,7 @@
> >  #define   PCR_VEC_DIS	(1ul << (63-0))	/* Vec. disable (bit NA since 
POWER8) */
> >  #define   PCR_VSX_DIS	(1ul << (63-1))	/* VSX disable (bit NA since 
POWER8) */
> >  #define   PCR_TM_DIS	(1ul << (63-2))	/* Trans. memory disable (POWER8) 
*/
> > +#define   PCR_HIGH_BITS	(PCR_VEC_DIS | PCR_VSX_DIS | PCR_TM_DIS)
> 
> This doesn't build with old binutils that don't support 'ul', eg:
> 
>   arch/powerpc/kvm/book3s_hv_rmhandlers.S:647: Error: junk at end of line, 
first unrecognized character is `u'
>   arch/powerpc/kvm/book3s_hv_rmhandlers.S:647: Error: missing ')'
>   arch/powerpc/kvm/book3s_hv_rmhandlers.S:647: Error: junk at end of line: 
`ul<<(63-0))|(1ul<<(63-1))|(1ul<<(63-2)))|(0x8|0x4|0x2)))>>32)@h'
>   arch/powerpc/kernel/cpu_setup_power.S:131: Error: syntax error; found `u', 
expected `,'
>   arch/powerpc/kernel/cpu_setup_power.S:131: Error: junk at end of line: 
`ul<<(63-0))|(1ul<<(63-1))|(1ul<<(63-2)))|(0x8|0x4|0x2)))@l'
> 
> etc. http://kisskb.ellerman.id.au/kisskb/buildresult/13957233/ 
> 
> There's a gcc-4.6 with an old binutils on the ka's.
> 
> cheers
> 





      reply	other threads:[~2019-09-17  0:52 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-10  6:01 [PATCH v2] PPC: Set reserved PCR bits Alistair Popple
2019-09-16  9:49 ` Michael Ellerman
2019-09-17  0:48   ` Alistair Popple [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=2120353.GbO1pRtziF@townsend \
    --to=alistair@popple.id.au \
    --cc=jniethe5@gmail.com \
    --cc=joel@jms.id.au \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    /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;
as well as URLs for NNTP newsgroup(s).