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 DE601C04A68 for ; Wed, 27 Jul 2022 18:25:29 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 3368C841BC; Wed, 27 Jul 2022 20:23:57 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=edgeble.ai 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=edgeble-ai.20210112.gappssmtp.com header.i=@edgeble-ai.20210112.gappssmtp.com header.b="X/tx7r0D"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id EE9BF83445; Wed, 27 Jul 2022 19:41:24 +0200 (CEST) Received: from mail-pj1-x1032.google.com (mail-pj1-x1032.google.com [IPv6:2607:f8b0:4864:20::1032]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 794888341C for ; Wed, 27 Jul 2022 19:41:22 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=edgeble.ai Authentication-Results: phobos.denx.de; spf=none smtp.mailfrom=jagan@edgeble.ai Received: by mail-pj1-x1032.google.com with SMTP id t2-20020a17090a4e4200b001f21572f3a4so2872402pjl.0 for ; Wed, 27 Jul 2022 10:41:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=edgeble-ai.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=hieTm6AnXL1p8EUYdB660G/L7GfRKhSnOfrWts52xEw=; b=X/tx7r0DbLbdsu7kLOO7eY37Dr/7w6REuDzOHQOCICBteKI1I4rU1NnUTKyBtvnUqU 71I7FbZ4qMzvPAhufmarm5Ywl62Wt1aKJaHRbaJtQggsdyU2CpmW8upsFuUj08HarRtA ThySKoeSfZ9JeGs6/ec5cKVobhCyhtlV4bgiJ5+jN69/M5cpatLW9YT9ebe3DmXDgM57 e5uyA6hEyEQFDT/fsEXeJcWY8SW/y0lUAwovmRIzlijle4KLqvNPV0aUNL21R3/77J8w 6B8MmxIJ/zZKaV+YR5h9EMNDDKA6Ti2ZacfyrsAYn/+aQzDxqITmG2QEGqRTwfzaBQZH az4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=hieTm6AnXL1p8EUYdB660G/L7GfRKhSnOfrWts52xEw=; b=WLz/ysavyk3/6oYVLpSYl6idjg0i90cK0SvZJ7gDhONXdpp0SjMSkeggh2vrVSOsZW 4zu9+oDPYN5Vho5InalxSbyK0+jS36K7H/y494lktR8GClN2MEb25PsF3ld+iDA5oqqQ PEYMmGsxzIPyeOXLBKbwj/FG0xmR4nf29DvCI32IypD9NrV4Vc6RQUs86XmzJUt2Bsud W6YDYZEQt8ptbB+AuvoAyh3gNgr6dHh1ub7GAoaVY1o/CRg5SqO78pyZ87eAPN4lIzv1 ek3vqlr6H/vx2g+46akGJXpvOp9EVjLyO19JEEbn1jv9TB5rX8R1ZhEqaDi2bMkUF9Xh j2zg== X-Gm-Message-State: AJIora/jPJVgGbH2zl8Ak81W3nMNtjn/UCf4P2hOQLuk9XgLhnG3WowW aTo9GwBM5nPjm0gLzMMbuEmuHg== X-Google-Smtp-Source: AGRyM1sGypx5IcWC4FxpTO1ANXHTeAQjEJuNa0oWtterifRTmm53IXVsxoYAwtX3WuKiVYnsMhKO+g== X-Received: by 2002:a17:902:f30c:b0:16d:a79c:4aed with SMTP id c12-20020a170902f30c00b0016da79c4aedmr6813625ple.23.1658943681956; Wed, 27 Jul 2022 10:41:21 -0700 (PDT) Received: from localhost.localdomain ([2405:201:c00a:a073:7b77:efa3:a08f:c6d8]) by smtp.gmail.com with ESMTPSA id d4-20020a621d04000000b00528c8ed356dsm14492958pfd.96.2022.07.27.10.41.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Jul 2022 10:41:21 -0700 (PDT) From: Jagan Teki To: Kever Yang , Philipp Tomsich , Simon Glass Cc: u-boot@lists.denx.de, Jagan Teki Subject: [PATCH 10/28] ram: rockchip: rv1126: Control ddr init prints via DEBUG Date: Wed, 27 Jul 2022 23:10:32 +0530 Message-Id: <20220727174050.2214617-11-jagan@edgeble.ai> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220727174050.2214617-1-jagan@edgeble.ai> References: <20220727174050.2214617-1-jagan@edgeble.ai> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Mailman-Approved-At: Wed, 27 Jul 2022 20:23:40 +0200 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 Control the ddr init print messages via RAM_ROCKCHIP_DEBUG instead of printing by default. This gives an option to configs to enable these prints or not. Signed-off-by: Jagan Teki --- drivers/ram/rockchip/sdram_rv1126.c | 38 +++++++++++++++++++---------- 1 file changed, 25 insertions(+), 13 deletions(-) diff --git a/drivers/ram/rockchip/sdram_rv1126.c b/drivers/ram/rockchip/sdram_rv1126.c index 9b1c34391e..6fe5b0305e 100644 --- a/drivers/ram/rockchip/sdram_rv1126.c +++ b/drivers/ram/rockchip/sdram_rv1126.c @@ -3358,22 +3358,33 @@ static void ddr_set_rate_for_fsp(struct dram_info *dram, if (get_wrlvl_val(dram, sdram_params)) printascii("get wrlvl value fail\n"); - printascii("change to: "); - printdec(f1); - printascii("MHz\n"); + if (IS_ENABLED(CONFIG_RAM_ROCKCHIP_DEBUG)) { + printascii("change to: "); + printdec(f1); + printascii("MHz\n"); + } ddr_set_rate(&dram_info, sdram_params, f1, sdram_params->base.ddr_freq, 1, 1, 1); - printascii("change to: "); - printdec(f2); - printascii("MHz\n"); + + if (IS_ENABLED(CONFIG_RAM_ROCKCHIP_DEBUG)) { + printascii("change to: "); + printdec(f2); + printascii("MHz\n"); + } ddr_set_rate(&dram_info, sdram_params, f2, f1, 2, 0, 1); - printascii("change to: "); - printdec(f3); - printascii("MHz\n"); + + if (IS_ENABLED(CONFIG_RAM_ROCKCHIP_DEBUG)) { + printascii("change to: "); + printdec(f3); + printascii("MHz\n"); + } ddr_set_rate(&dram_info, sdram_params, f3, f2, 3, 1, 1); - printascii("change to: "); - printdec(f0); - printascii("MHz(final freq)\n"); + + if (IS_ENABLED(CONFIG_RAM_ROCKCHIP_DEBUG)) { + printascii("change to: "); + printdec(f0); + printascii("MHz(final freq)\n"); + } ddr_set_rate(&dram_info, sdram_params, f0, f3, 0, 0, 1); } @@ -3465,7 +3476,8 @@ static int rv1126_dmc_init(struct udevice *dev) save_rw_trn_result_to_ddr(&rw_trn_result); #endif - printascii("out\n"); + if (IS_ENABLED(CONFIG_RAM_ROCKCHIP_DEBUG)) + printascii("out\n"); return ret; error: -- 2.25.1