From patchwork Wed Feb 15 08:54:33 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Prabhakar Kushwaha X-Patchwork-Id: 141276 X-Patchwork-Delegate: afleming@freescale.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 74E701007D4 for ; Wed, 15 Feb 2012 19:54:53 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 34C35280D1; Wed, 15 Feb 2012 09:54:52 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id nriwTsxyahrz; Wed, 15 Feb 2012 09:54:52 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id ABDE5280AB; Wed, 15 Feb 2012 09:54:49 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 832B4280A5 for ; Wed, 15 Feb 2012 09:54:48 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id VXLVA-RQCZ2v for ; Wed, 15 Feb 2012 09:54:48 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from TX2EHSOBE002.bigfish.com (tx2ehsobe002.messaging.microsoft.com [65.55.88.12]) by theia.denx.de (Postfix) with ESMTPS id DAB87280CE for ; Wed, 15 Feb 2012 09:54:45 +0100 (CET) Received: from mail88-tx2-R.bigfish.com (10.9.14.235) by TX2EHSOBE002.bigfish.com (10.9.40.22) with Microsoft SMTP Server id 14.1.225.23; Wed, 15 Feb 2012 08:54:44 +0000 Received: from mail88-tx2 (localhost [127.0.0.1]) by mail88-tx2-R.bigfish.com (Postfix) with ESMTP id 0BF3760398 for ; Wed, 15 Feb 2012 08:54:44 +0000 (UTC) X-SpamScore: 0 X-BigFish: VS0(zzzz1202hzz8275bhz2dh2a8h668h839h) X-Forefront-Antispam-Report: CIP:70.37.183.190; KIP:(null); UIP:(null); IPV:NLI; H:mail.freescale.net; RD:none; EFVD:NLI Received: from mail88-tx2 (localhost.localdomain [127.0.0.1]) by mail88-tx2 (MessageSwitch) id 1329296079723016_21240; Wed, 15 Feb 2012 08:54:39 +0000 (UTC) Received: from TX2EHSMHS043.bigfish.com (unknown [10.9.14.247]) by mail88-tx2.bigfish.com (Postfix) with ESMTP id 7F801800D8 for ; Wed, 15 Feb 2012 08:54:39 +0000 (UTC) Received: from mail.freescale.net (70.37.183.190) by TX2EHSMHS043.bigfish.com (10.9.99.143) with Microsoft SMTP Server (TLS) id 14.1.225.23; Wed, 15 Feb 2012 08:54:38 +0000 Received: from az84smr01.freescale.net (10.64.34.197) by 039-SN1MMR1-003.039d.mgd.msft.net (10.84.1.16) with Microsoft SMTP Server (TLS) id 14.1.355.3; Wed, 15 Feb 2012 02:54:37 -0600 Received: from b32579-VirtualBox.ap.freescale.net (b32579-VirtualBox.ap.freescale.net [10.232.132.74]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id q1F8sYfs016610; Wed, 15 Feb 2012 01:54:35 -0700 From: Prabhakar Kushwaha To: Date: Wed, 15 Feb 2012 14:24:33 +0530 Message-ID: <1329296073-28576-1-git-send-email-prabhakar@freescale.com> X-Mailer: git-send-email 1.7.5.4 MIME-Version: 1.0 X-OriginatorOrg: freescale.com Cc: afleming@freescale.com, Radu Lazarescu Subject: [U-Boot] [PATCH 4/4] powerpc/85xx:Update NAND code base to support debugger X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Update NAND code base to ovecome e500 and e500v2's second limitation i.e. IVPR + IVOR15 should be valid fetchable OP code address. As NAND SPL does not compile vector table so making sure IVOR + IVOR15 points to any fetchable valid data Signed-off-by: Radu Lazarescu Signed-off-by: Prabhakar Kushwaha --- Applies on http://git.denx.de/u-boot.git branch master arch/powerpc/cpu/mpc85xx/start.S | 18 +++++++++++++----- 1 files changed, 13 insertions(+), 5 deletions(-) diff --git a/arch/powerpc/cpu/mpc85xx/start.S b/arch/powerpc/cpu/mpc85xx/start.S index 26c32df..2d7b000 100644 --- a/arch/powerpc/cpu/mpc85xx/start.S +++ b/arch/powerpc/cpu/mpc85xx/start.S @@ -1415,17 +1415,25 @@ relocate_code: 7: sync /* Wait for all icbi to complete on bus */ isync - /* - * Re-point the IVPR at RAM - */ - mtspr IVPR,r10 - /* * We are done. Do not return, instead branch to second part of board * initialization, now running from RAM. */ addi r0,r10,in_ram - _start + _START_OFFSET + +#if defined(CONFIG_E500_V1_V2) && defined(CONFIG_NAND_SPL) +/* + * As IVPR is going to point RAM address, + * Make sure IVOR15 has valid opcode to support debugger + */ + mtspr IVOR15,r0 +#endif + /* + * Re-point the IVPR at RAM + */ + mtspr IVPR,r10 + mtlr r0 blr /* NEVER RETURNS! */ .globl in_ram