From patchwork Tue Jun 24 13:49:06 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ivan Khoronzhuk X-Patchwork-Id: 363465 X-Patchwork-Delegate: scottwood@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 599911400BE for ; Tue, 24 Jun 2014 23:50:39 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 964D6A75E8; Tue, 24 Jun 2014 15:49:52 +0200 (CEST) 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 1FCE31I6ilPH; Tue, 24 Jun 2014 15:49:52 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 067D4A75B8; Tue, 24 Jun 2014 15:49:35 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 31396A75A9 for ; Tue, 24 Jun 2014 15:49:29 +0200 (CEST) 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 QQ95ubRaoXaw for ; Tue, 24 Jun 2014 15:49:25 +0200 (CEST) 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 devils.ext.ti.com (devils.ext.ti.com [198.47.26.153]) by theia.denx.de (Postfix) with ESMTPS id 2DE04A75A0 for ; Tue, 24 Jun 2014 15:49:25 +0200 (CEST) Received: from dflxv15.itg.ti.com ([128.247.5.124]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id s5ODnJiK028845; Tue, 24 Jun 2014 08:49:19 -0500 Received: from DFLE73.ent.ti.com (dfle73.ent.ti.com [128.247.5.110]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id s5ODnJQT027062; Tue, 24 Jun 2014 08:49:19 -0500 Received: from dflp32.itg.ti.com (10.64.6.15) by DFLE73.ent.ti.com (128.247.5.110) with Microsoft SMTP Server id 14.3.174.1; Tue, 24 Jun 2014 08:49:19 -0500 Received: from khorivan.synapse.com (incasgf5a_e1_2.itg.ti.com [10.167.216.36]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id s5ODn8Tn014695; Tue, 24 Jun 2014 08:49:17 -0500 From: Ivan Khoronzhuk To: , , , Date: Tue, 24 Jun 2014 16:49:06 +0300 Message-ID: <1403617746-25024-4-git-send-email-ivan.khoronzhuk@ti.com> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1403617746-25024-1-git-send-email-ivan.khoronzhuk@ti.com> References: <1403617746-25024-1-git-send-email-ivan.khoronzhuk@ti.com> MIME-Version: 1.0 Cc: w-kwok2@ti.com, hzhang@ti.com Subject: [U-Boot] [U-boot] [Patch v3 3/3] k2hk: change default nand ecc layout 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 For keystyone k2hk board the default nand layout is different from davinci. So swich ecc layout at init in board file. Signed-off-by: Ivan Khoronzhuk --- board/ti/k2hk_evm/board.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/board/ti/k2hk_evm/board.c b/board/ti/k2hk_evm/board.c index ef90f9d..baa6ab7 100644 --- a/board/ti/k2hk_evm/board.c +++ b/board/ti/k2hk_evm/board.c @@ -11,6 +11,7 @@ #include #include #include +#include #include #include @@ -19,6 +20,7 @@ #include #include #include +#include DECLARE_GLOBAL_DATA_PTR; @@ -147,6 +149,15 @@ int cpu_to_bus(u32 *ptr, u32 length) return 0; } +int board_nand_init(struct nand_chip *chip) +{ + davinci_nand_init(chip); + chip->ecc.layout = + board_nand_get_ecclayout(NAND_KEYSTONE_RBL_4BIT_LAYOUT); + + return 0; +} + #if defined(CONFIG_BOARD_EARLY_INIT_F) int board_early_init_f(void) {