[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <063D6719AE5E284EB5DD2968C1650D6D1CAC1765@AcuExch.aculab.com>
Date: Tue, 6 Jan 2015 12:08:09 +0000
From: David Laight <David.Laight@...LAB.COM>
To: 'Joakim Tjernlund' <Joakim.Tjernlund@...nsmode.se>,
"christophe.leroy@....fr" <christophe.leroy@....fr>
CC: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"paulus@...ba.org" <paulus@...ba.org>,
"scottwood@...escale.com" <scottwood@...escale.com>,
"linuxppc-dev@...ts.ozlabs.org" <linuxppc-dev@...ts.ozlabs.org>
Subject: RE: [PATCH 05/11] powerpc/8xx: Optimise access to swapper_pg_dir
> On Tue, 2014-12-16 at 16:03 +0100, Christophe Leroy wrote:
> > All accessed to PGD entries are done via 0(r11).
> > By using lower part of swapper_pg_dir as load index to r11, we can remove the
> > ori instruction.
> >
> > Signed-off-by: Christophe Leroy <christophe.leroy@....fr>
>
> Nice :)
> Acked-by: Joakim Tjernlund <joakim.tjernlund@...nsmode.se>
>
> >
> > ---
> > arch/powerpc/kernel/head_8xx.S | 22 ++++++++++------------
> > 1 file changed, 10 insertions(+), 12 deletions(-)
> >
> > diff --git a/arch/powerpc/kernel/head_8xx.S b/arch/powerpc/kernel/head_8xx.S
> > index ae05f28..aa45225 100644
> > --- a/arch/powerpc/kernel/head_8xx.S
> > +++ b/arch/powerpc/kernel/head_8xx.S
> > @@ -322,13 +322,12 @@ InstructionTLBMiss:
> > mfspr r11, SPRN_M_TW/* Get level 1 table base address */
> > #ifdef CONFIG_MODULES
> > beq 3f
> > - lis r11, (swapper_pg_dir-PAGE_OFFSET)@h
> > - ori r11, r11, (swapper_pg_dir-PAGE_OFFSET)@l
> > + lis r11, (swapper_pg_dir-PAGE_OFFSET)@ha
> > 3:
> > #endif
> > /* Insert level 1 index */
> > rlwimi r11, r10, 32 - ((PAGE_SHIFT - 2) << 1), (PAGE_SHIFT - 2) << 1, 29
> > - lwz r11, 0(r11)/* Get the level 1 entry */
> > + lwz r11, (swapper_pg_dir-PAGE_OFFSET)@l(r11)/* Get the level 1 entry */
> >
On the face of it that fragment doesn't look right when CONFIG_MODULES is undefined.
David
Powered by blists - more mailing lists