From patchwork Fri Aug 8 07:03:43 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Leroy X-Patchwork-Id: 378093 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [103.22.144.68]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 647D1140116 for ; Fri, 8 Aug 2014 17:14:01 +1000 (EST) Received: from ozlabs.org (ozlabs.org [103.22.144.67]) by lists.ozlabs.org (Postfix) with ESMTP id 40C2D1A0DD8 for ; Fri, 8 Aug 2014 17:14:01 +1000 (EST) X-Original-To: linuxppc-dev@lists.ozlabs.org Delivered-To: linuxppc-dev@lists.ozlabs.org Received: from mailhub1.si.c-s.fr (pegase1.c-s.fr [93.17.236.30]) by lists.ozlabs.org (Postfix) with ESMTP id C081C1A0A74 for ; Fri, 8 Aug 2014 17:04:31 +1000 (EST) Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 05EFC1C847C; Fri, 8 Aug 2014 09:04:30 +0200 (CEST) X-Virus-Scanned: amavisd-new at c-s.fr Received: from mailhub1.si.c-s.fr ([192.168.12.234]) by localhost (mailhub1.c-s.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LzHjUXUmh55V; Fri, 8 Aug 2014 09:04:29 +0200 (CEST) Received: from messagerie.si.c-s.fr (messagerie [192.168.25.192]) by pegase1.c-s.fr (Postfix) with ESMTP id D3DEF1C8497; Fri, 8 Aug 2014 09:04:29 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 60769C73C5; Fri, 8 Aug 2014 09:04:29 +0200 (CEST) X-Virus-Scanned: amavisd-new at c-s.fr Received: from messagerie.si.c-s.fr ([127.0.0.1]) by localhost (messagerie.si.c-s.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id skIH-vMxRXqk; Fri, 8 Aug 2014 09:04:29 +0200 (CEST) Received: from PO10863.localdomain (unknown [192.168.4.167]) by messagerie.si.c-s.fr (Postfix) with ESMTP id F166BC73CC; Fri, 8 Aug 2014 09:04:28 +0200 (CEST) Received: by localhost.localdomain (Postfix, from userid 0) id 2D84C1ABD47; Fri, 8 Aug 2014 09:03:43 +0200 (CEST) From: Christophe Leroy To: Benjamin Herrenschmidt , Paul Mackerras Subject: [PATCH 11/20] powerpc/8xx: Align swapper_pg_dir on 16 bits boundary Message-Id: <20140808070343.2D84C1ABD47@localhost.localdomain> Date: Fri, 8 Aug 2014 09:03:43 +0200 (CEST) Cc: scottwood@freescale.com, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" Lets save one cycle by aligning swapper_pg_dir on 16 bits boundary. Signed-off-by: Christophe Leroy --- arch/powerpc/kernel/head_8xx.S | 13 +++++-------- 1 files changed, 5 insertions(+), 8 deletions(-) diff --git a/arch/powerpc/kernel/head_8xx.S b/arch/powerpc/kernel/head_8xx.S index 4a49ff3..6c2aa33 100644 --- a/arch/powerpc/kernel/head_8xx.S +++ b/arch/powerpc/kernel/head_8xx.S @@ -310,7 +310,6 @@ InstructionTLBMiss: andi. r11, r10, 0x0800 /* Address >= 0x80000000 */ beq 3f lis r11, swapper_pg_dir@h - ori r11, r11, swapper_pg_dir@l rlwimi r10, r11, 0, 2, 19 3: #endif @@ -383,7 +382,6 @@ DataStoreTLBMiss: andi. r11, r10, 0x0800 beq 3f lis r11, swapper_pg_dir@h - ori r11, r11, swapper_pg_dir@l rlwimi r10, r11, 0, 2, 19 3: lwz r11, 0(r10) /* Get the level 1 entry */ @@ -526,7 +524,6 @@ FixupDAR:/* Entry point for dcbx workaround. */ mfspr r11, SPRN_M_TWB /* Get level 1 table entry address */ beq- 3f /* Branch if user space */ lis r11, (swapper_pg_dir-PAGE_OFFSET)@h - ori r11, r11, (swapper_pg_dir-PAGE_OFFSET)@l rlwimi r11, r10, 32-20, 0xffc /* r11 = r11&~0xffc|(r10>>20)&0xffc */ 3: lwz r11, 0(r11) /* Get the level 1 entry */ DO_8xx_CPU6(0x3b80, r3) @@ -687,7 +684,6 @@ start_here: * easier......until someone changes init's static structures. */ lis r6, swapper_pg_dir@h - ori r6, r6, swapper_pg_dir@l tophys(r6,r6) #ifdef CONFIG_8xx_CPU6 lis r4, cpu6_errata_word@h @@ -912,14 +908,15 @@ set_dec_cpu6: .data .globl sdata sdata: - .globl empty_zero_page -empty_zero_page: - .space 4096 - .globl swapper_pg_dir + .align 16 swapper_pg_dir: .space 4096 + .globl empty_zero_page +empty_zero_page: + .space 4096 + /* Room for two PTE table poiners, usually the kernel and current user * pointer to their respective root page table (pgdir). */