From patchwork Fri Apr 20 09:14:25 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 901812 X-Patchwork-Delegate: yamada.m@jp.panasonic.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=socionext.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=nifty.com header.i=@nifty.com header.b="Tz9WpOF4"; dkim-atps=neutral Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 40S9Fx2ygSz9s7P for ; Fri, 20 Apr 2018 19:16:21 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id EB356C2203A; Fri, 20 Apr 2018 09:15:25 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id F0AE7C22016; Fri, 20 Apr 2018 09:15:03 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 886D5C21E79; Fri, 20 Apr 2018 09:15:01 +0000 (UTC) Received: from conuserg-09.nifty.com (conuserg-09.nifty.com [210.131.2.76]) by lists.denx.de (Postfix) with ESMTPS id 47459C21E79 for ; Fri, 20 Apr 2018 09:15:00 +0000 (UTC) Received: from pug.e01.socionext.com (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-09.nifty.com with ESMTP id w3K9ESOq030098; Fri, 20 Apr 2018 18:14:30 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-09.nifty.com w3K9ESOq030098 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1524215670; bh=bM/Mp0r662/WmYxwddO6CTY1d17NtTBe87AKQS6b2VQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Tz9WpOF4fu8gJriUvB9HzHl6nIpg1fW4vwybHAEC8YCRbFeL6BWIAs130U3G++HZ5 Z9SxskBtqSx1e7vR3A6nsathoH48tLXuaYIfpR1iehDjRs06eb3365Uh6E4u7l3Tl4 eRtIgsUbz232WIMBaPacivMdlEiE0IcclqnmiFpy4ARt8dGFliUt8+GraXbwWYSSh+ 9PR4XeTCdH6iQp49Q/KTZQQqDNzqk3/A7NudbKN+Jf23KAJuqugGTtn5vPph7GeNnH h5+b3XojJ50fBK9e82Si/jgcjPH0sg1FXFv8lNWcok+kHnmoEU2bsrWUi6c2bb5bZY Gs6eUH6TO8rBQ== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: u-boot@lists.denx.de Date: Fri, 20 Apr 2018 18:14:25 +0900 Message-Id: <1524215667-32112-3-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1524215667-32112-1-git-send-email-yamada.masahiro@socionext.com> References: <1524215667-32112-1-git-send-email-yamada.masahiro@socionext.com> Subject: [U-Boot] [PATCH 2/4] mmc: uniphier-sd: skip clock set-up for SPL X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" The size of SPL is hitting the limit (64KB) for uniphier_v7_defconfig. When booting from SD/eMMC, obviously its clock has been properly set up by the boot ROM. Acutually, no need to re-initialize the clock in SPL. Using a clock driver would generalize the SoC specific code, but solving the memory footprint problem would win. Signed-off-by: Masahiro Yamada --- drivers/mmc/uniphier-sd.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/mmc/uniphier-sd.c b/drivers/mmc/uniphier-sd.c index bc6e41d..61f8da4 100644 --- a/drivers/mmc/uniphier-sd.c +++ b/drivers/mmc/uniphier-sd.c @@ -33,6 +33,7 @@ static const struct udevice_id uniphier_sd_match[] = { static int uniphier_sd_probe(struct udevice *dev) { struct tmio_sd_priv *priv = dev_get_priv(dev); +#ifndef CONFIG_SPL_BUILD struct clk clk; int ret; @@ -56,6 +57,9 @@ static int uniphier_sd_probe(struct udevice *dev) dev_err(dev, "failed to enable host clock\n"); return ret; } +#else + priv->mclk = 100000000; +#endif return tmio_sd_probe(dev, 0); }