From mboxrd@z Thu Jan 1 00:00:00 1970 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 1675BC433FE for ; Fri, 7 Oct 2022 12:21:00 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 49C3F84E9B; Fri, 7 Oct 2022 14:20:28 +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="eN5KPDTN"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id CCD5284E8E; Fri, 7 Oct 2022 14:20:11 +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 87B9B84E82 for ; Fri, 7 Oct 2022 14:20:04 +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 1ogmKh-0002x0-5S; Fri, 07 Oct 2022 14:20:03 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=thorsis.com; s=default; t=1665145203; 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=eN5KPDTNwpZLqCCZSTWvJ5JRprDUAzHoC02xGnb8yjBWtGbRJgnvf5lumlojwkAeb2GGnN bIG8hPSG9pI61FdkrogkEB6ML8LcCGuItu80BsiXks9OzHcCJNUKdlfrSkt5+eQPLBfVZY R3zhTz78KRASYLZdIbE5aO9VDOPXw/Du9yxhIjOPawA9WTx4+LF85vg960Haz+A6p3f0ES p5twF17dDtnlDCR6Gnv/8p253NritUL1kotAflUCfh/spiidOoZmizbCSVmqkTYInXsqF3 i0o/IFEhYfS45GrVS+8rLnNXCpcjIHMf+SA8G72FCbI9Fn1F7wOl3m0hI4OEPg== From: Alexander Dahl To: u-boot@lists.denx.de Cc: Michal Simek Subject: [PATCH v4 05/10] fpga: altera: Use logging feature instead of FPGA_DEBUG Date: Fri, 7 Oct 2022 14:19:58 +0200 Message-Id: <20221007122003.11239-6-ada@thorsis.com> In-Reply-To: <20221007122003.11239-1-ada@thorsis.com> References: <20221007122003.11239-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