Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 06BC7C433FE for ; Wed, 5 Oct 2022 11:44:51 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 61F0484D69; Wed, 5 Oct 2022 13:44:35 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=thorsis.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=thorsis.com header.i=@thorsis.com header.b="P8F5dy4K"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 598C684D72; Wed, 5 Oct 2022 13:44:30 +0200 (CEST) Received: from mail.thorsis.com (mail.thorsis.com [92.198.35.195]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id EF0DB8419C for ; Wed, 5 Oct 2022 13:44:23 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=thorsis.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=ada@thorsis.com Received: from adahl by ada.ifak-system.com with local (Exim 4.92) (envelope-from ) id 1og2p3-0006Lp-Or; Wed, 05 Oct 2022 13:44:21 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=thorsis.com; s=default; t=1664970262; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=flObOUMnY1Ki2adJztcXdjjKhB3ng0EnQJRZ/OIlkVc=; b=P8F5dy4KGBxseLIy2MFJLfvIX5jPTYA8ep0kegkNkN4ji+3yKkK/mMu4v0gxezzp9OtPYF KPFnrhykbRhb9mToPg+4+oGBjePyNXzz5pkmuamM2rdnMTtcYzzwOHvblsDEO7fUxONwYx 6BJnSVIIZlJeHLKnazXvGotyRCHjifHtZct3UJSi2SceZDP5t4vvaQPkskMsuHaGSXXxKR M7+S6nxSBjy0yu0KeZobERU1XW0V68oz7/Ko7O8wBs0rZJyMcNqvDSLcH1ULcaVCntN+au 2jyusOYpyoQ8G4pcrplR/bAhWCfF87HcoN+5fQoQNwMo1HHxtwCG7y5WDyAkAQ== From: Alexander Dahl To: u-boot@lists.denx.de Cc: Michal Simek Subject: [PATCH v3 1/7] fpga: altera: Use logging feature instead of FPGA_DEBUG Date: Wed, 5 Oct 2022 13:44:15 +0200 Message-Id: <20221005114421.24340-2-ada@thorsis.com> In-Reply-To: <20221005114421.24340-1-ada@thorsis.com> References: <20221005114421.24340-1-ada@thorsis.com> Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Instead of using DEBUG or LOG_DEBUG the driver still had its own definition for debug output. Signed-off-by: Alexander Dahl --- drivers/fpga/altera.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/drivers/fpga/altera.c b/drivers/fpga/altera.c index 10c0475d25..6a4f0cb9bc 100644 --- a/drivers/fpga/altera.c +++ b/drivers/fpga/altera.c @@ -7,6 +7,8 @@ * Rich Ireland, Enterasys Networks, rireland@enterasys.com. */ +#define LOG_CATEGORY UCLASS_FPGA + /* * Altera FPGA support */ @@ -16,9 +18,6 @@ #include #include -/* Define FPGA_DEBUG to 1 to get debug printf's */ -#define FPGA_DEBUG 0 - static const struct altera_fpga { enum altera_family family; const char *name; @@ -106,8 +105,7 @@ int altera_load(Altera_desc *desc, const void *buf, size_t bsize) if (!fpga) return FPGA_FAIL; - debug_cond(FPGA_DEBUG, "%s: Launching the %s Loader...\n", - __func__, fpga->name); + log_debug("Launching the %s Loader...\n", fpga->name); if (fpga->load) return fpga->load(desc, buf, bsize); return 0; @@ -120,8 +118,7 @@ int altera_dump(Altera_desc *desc, const void *buf, size_t bsize) if (!fpga) return FPGA_FAIL; - debug_cond(FPGA_DEBUG, "%s: Launching the %s Reader...\n", - __func__, fpga->name); + log_debug("Launching the %s Reader...\n", fpga->name); if (fpga->dump) return fpga->dump(desc, buf, bsize); return 0; -- 2.30.2