From patchwork Mon Jul 7 10:37:24 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: maxin.john@enea.com X-Patchwork-Id: 367498 X-Patchwork-Delegate: hs@denx.de 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 993AE1400BE for ; Mon, 7 Jul 2014 21:14:19 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id DFFAD4B372; Mon, 7 Jul 2014 13:14:17 +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 C8Hp4eh0ZEE4; Mon, 7 Jul 2014 13:14:17 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 3DCBA4A053; Mon, 7 Jul 2014 13:14:15 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 8322C4A047 for ; Mon, 7 Jul 2014 12:37:37 +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 dAIqeLZL4ych for ; Mon, 7 Jul 2014 12:37:34 +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 mx-3.enea.com (sestofw01.enea.se [192.36.1.252]) by theia.denx.de (Postfix) with SMTP id 111B04A041 for ; Mon, 7 Jul 2014 12:37:29 +0200 (CEST) Received: from sestofb10.enea.se (172.21.3.145) by smtp.enea.com (172.21.1.209) with Microsoft SMTP Server id 14.3.158.1; Mon, 7 Jul 2014 12:37:28 +0200 Received: by sestofb10.enea.se (Postfix, from userid 4454) id E1F1D288F30; Mon, 7 Jul 2014 12:37:28 +0200 (CEST) From: "Maxin B. John" To: Date: Mon, 7 Jul 2014 12:37:24 +0200 Message-ID: <1404729444-10957-1-git-send-email-maxin.john@enea.com> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 Received-SPF: None (SESTOEX03.enea.se: maxin.john@enea.com does not designate permitted sender hosts) X-Mailman-Approved-At: Mon, 07 Jul 2014 13:14:13 +0200 Subject: [U-Boot] [PATCH] mtdcore: Fix a build error with CONFIG_CMD_MTDPARTS_SPREAD 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 This patch fixes the build error for CONFIG_CMD_MTDPARTS_SPREAD introduced by the commit: commit dfe64e2c89731a3f9950d7acd8681b68df2bae03 Author: Sergey Lapin Date: Mon Jan 14 03:46:50 2013 +0000 mtd: resync with Linux-3.7.1 Signed-off-by: Maxin B. John --- drivers/mtd/mtdcore.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c index 0a38fbe..328a2b9 100644 --- a/drivers/mtd/mtdcore.c +++ b/drivers/mtd/mtdcore.c @@ -167,7 +167,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t offset, *truncated = 0; *len_incl_bad = 0; - if (!mtd->block_isbad) { + if (!mtd->_block_isbad) { *len_incl_bad = length; return; } @@ -183,7 +183,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t offset, block_len = mtd->erasesize - (offset & (mtd->erasesize - 1)); - if (!mtd->block_isbad(mtd, offset & ~(mtd->erasesize - 1))) + if (!mtd->_block_isbad(mtd, offset & ~(mtd->erasesize - 1))) len_excl_bad += block_len; *len_incl_bad += block_len;