From patchwork Thu Jun 22 07:50:01 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 106180 Delivered-To: patch@linaro.org Received: by 10.140.91.2 with SMTP id y2csp2329931qgd; Thu, 22 Jun 2017 00:50:35 -0700 (PDT) X-Received: by 10.80.149.132 with SMTP id w4mr1592726eda.82.1498117835148; Thu, 22 Jun 2017 00:50:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1498117835; cv=none; d=google.com; s=arc-20160816; b=wBtlUiY0fHt3ZGJiCqSZ2CQ2qvKm7+KjM4tlOhSo0qSm3RVJk4riOWqFsvDIUJYDUy QaXE+v0LtBoxpucEjvDfY+Ma7jiwLPHvOqMziz5mK2Y8WhsVo0OzSYYn559ykWf7Xwy2 bU6D486hXOiwz5XNAB8zk39TKASpSSpqQrbkXxY/Ve8rq4gjSRKkCGwOfuMGnLPs6IdG q/0LxGyxws9nIGJs+ED6a6Rk4ebdl25OK3k/8yNTQQodRiuN0D9kaZrUNbgf2ZZS0vFd zFQhP1VdsUSxuYw6bgL2xQCxn0YzTMvpkvVr0yrFbxaAkxZ92jfdyibW/Y5KlgpnY3Ek +n6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:message-id:date:to:from:dkim-signature :dkim-filter:arc-authentication-results; bh=z2XdyLJfOlUndFvgJA9IvZ4MW3S9DDMbX1hbUcqTz0c=; b=jXtL0qRF9r+gubpUEi6+1ZSwBBubFhCcUNIGs+eo5hs4FoNXOvVldQIuS06oHAR/Qo Y9y+hRNH6karWUyAIqy8TFlubHi5O4gIDTZB9XR08y3an4lw7rOjea6woU2wbx+OolNi COR7dK/mdxqvTUfNkN2qJIWSeN7Sp17R5/qX0u1ou7/7LHtJt8nlBEPUZ6+c1iy5CPVO z5rwlC1XLuDRDw8DWKWyU2NF3HFj31NfYxTbjVFvPU3fTdzCgTNDp/cLBQZxLPvEEWoo LCOfbPQf7FxxzvEwaG5GErJ1dyNhyhra6471XyEk5s96GFydAm7cXT2tKPh0CM5qu/6u Xp8g== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@nifty.com header.b=YQ836yIu; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Return-Path: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id a33si1075283edf.241.2017.06.22.00.50.34; Thu, 22 Jun 2017 00:50:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) client-ip=81.169.180.215; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@nifty.com header.b=YQ836yIu; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by lists.denx.de (Postfix, from userid 105) id 95E06C21C7E; Thu, 22 Jun 2017 07:50:33 +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 CDB2FC21C55; Thu, 22 Jun 2017 07:50:31 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id AC747C21C55; Thu, 22 Jun 2017 07:50:30 +0000 (UTC) Received: from conuserg-11.nifty.com (conuserg-11.nifty.com [210.131.2.78]) by lists.denx.de (Postfix) with ESMTPS id E01EFC21C3E for ; Thu, 22 Jun 2017 07:50:29 +0000 (UTC) Received: from pug.e01.socionext.com (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-11.nifty.com with ESMTP id v5M7o2uO023286; Thu, 22 Jun 2017 16:50:03 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-11.nifty.com v5M7o2uO023286 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1498117803; bh=PGVBYj2SSZLnfhgQgThwepm0iZX9YmTXrPN1/073Sow=; h=From:To:Cc:Subject:Date:From; b=YQ836yIu6TXsqWI7UWksPykn7oS7RT5pLWkumUHXJjqk9klID0jcWAJBM/X/cHAQ6 pQKxNdbGjK0wNhoMiMoQr3Ovn6v7Ie3+xpuEvE+xOpUJemzHHUfmyMqOVSYdNQOfB9 39mogdu9yWBz9qOYUuZgw9cmOhPG1HPv3MHYgyC8Mi0tgHykXZeU00Mfct6ivJDkJF jHynBz/iRTyoErNGnSY1kjqjiKFyWJt2bhHd33xzgGWOzpwGHBmVG7x2Vn3cPgkzaR GgnLtwPUBngtk7pyIKwcGMjDI+yz1xFIVkbuxGsZ7nPRIteZV7XGBHCH01LZG6g0fk bHJ/I5MUHExSw== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: u-boot@lists.denx.de Date: Thu, 22 Jun 2017 16:50:01 +0900 Message-Id: <1498117801-19220-1-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.7.4 Subject: [U-Boot] [PATCH] dm: include from drivers/core/util.c 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" Fix sparse warnings "... was not declared. Should it be static?" Also, fix redefinition of dm_warn/dm_dbg. Signed-off-by: Masahiro Yamada Reviewed-by: Bin Meng --- drivers/core/util.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/core/util.c b/drivers/core/util.c index 5ceac8bbb15b..2e232d57a14f 100644 --- a/drivers/core/util.c +++ b/drivers/core/util.c @@ -5,9 +5,11 @@ */ #include +#include #include #include +#ifdef CONFIG_DM_WARN void dm_warn(const char *fmt, ...) { va_list args; @@ -16,7 +18,9 @@ void dm_warn(const char *fmt, ...) vprintf(fmt, args); va_end(args); } +#endif +#ifdef DEBUG void dm_dbg(const char *fmt, ...) { va_list args; @@ -25,6 +29,7 @@ void dm_dbg(const char *fmt, ...) vprintf(fmt, args); va_end(args); } +#endif int list_count_items(struct list_head *head) {