From patchwork Wed Oct 15 15:53:14 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Guillaume GARDET X-Patchwork-Id: 400020 X-Patchwork-Delegate: trini@ti.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 09198140081 for ; Thu, 16 Oct 2014 02:55:37 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 76D8CA7874; Wed, 15 Oct 2014 17:55:16 +0200 (CEST) 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 qv5ePaU86G4o; Wed, 15 Oct 2014 17:55:16 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 9381AAB59B; Wed, 15 Oct 2014 17:55:10 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E350FA7448 for ; Wed, 15 Oct 2014 17:54:55 +0200 (CEST) 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 u3XSO3C3pSXs for ; Wed, 15 Oct 2014 17:54:55 +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 smtp6-g21.free.fr (smtp6-g21.free.fr [212.27.42.6]) by theia.denx.de (Postfix) with ESMTPS id B860DA746A for ; Wed, 15 Oct 2014 17:54:53 +0200 (CEST) Received: from OLI01.site (unknown [82.244.147.214]) by smtp6-g21.free.fr (Postfix) with ESMTP id DBC9382323; Wed, 15 Oct 2014 17:53:49 +0200 (CEST) From: Guillaume GARDET To: u-boot@lists.denx.de Date: Wed, 15 Oct 2014 17:53:14 +0200 Message-Id: <1413388395-11425-5-git-send-email-guillaume.gardet@free.fr> X-Mailer: git-send-email 1.8.4.5 In-Reply-To: <1413388395-11425-1-git-send-email-guillaume.gardet@free.fr> References: <20140930133307.GX25506@bill-the-cat> <1413388395-11425-1-git-send-email-guillaume.gardet@free.fr> Cc: Tom Rini Subject: [U-Boot] [PATCH V2 4/5] spl: do not hang in spl_register_fat_device but return error value. It allows to use both CONFIG_SPL_FAT_SUPPORT and CONFIG_SPL_EXT_SUPPORT. X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.13 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Do not hang in spl_register_fat_device but return an error value. It allows to use both CONFIG_SPL_FAT_SUPPORT and CONFIG_SPL_EXT_SUPPORT. If FAT load fails, then EXT load is tried. Signed-off-by: Guillaume GARDET Cc: Tom Rini --- common/spl/spl_fat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/spl/spl_fat.c b/common/spl/spl_fat.c index 91481fc..350f7d9 100644 --- a/common/spl/spl_fat.c +++ b/common/spl/spl_fat.c @@ -30,7 +30,7 @@ static int spl_register_fat_device(block_dev_desc_t *block_dev, int partition) #ifdef CONFIG_SPL_LIBCOMMON_SUPPORT printf("%s: fat register err - %d\n", __func__, err); #endif - hang(); + return err; } fat_registered = 1;