From patchwork Mon Jul 13 20:06:34 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 11660979 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9290013B4 for ; Mon, 13 Jul 2020 20:07:28 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 6A61720674 for ; Mon, 13 Jul 2020 20:07:28 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="MrmykLBG"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=amarulasolutions.com header.i=@amarulasolutions.com header.b="Lxs+H3O6" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6A61720674 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=amarulasolutions.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=dHunVjggxSQO8257tpNWmY8jrywXxkMAA9+WJFcqLRs=; b=MrmykLBGLH/+JaO7HlT+2XKzy ImOXr5T+X2xX7nQ7WOimZBHkxsarh4Ff6tSYStAKbc84T2ZjWA7bzzYjWTqehatm4mGue22grQFpV Tu7UvnX1PiFyXMjoPHgKJ4DZx6x3VtuIh5ub7jU7m3Vcx8/GlV+X/aFGLTxDGeG80eaNDXN012DlF NpdE43VVKy0Rs54Vo3agZ9H8hLtrJd8YRz7Pw4qSOvPn8f9NaGG6i0D9F/A/MNjFCFPTHKp+nwCMz /P7n4P/PJBUejW6mg5wAD2jgW+v2/oZHoc4zVpL7QEu0Nj+plM0d6bBIYlFuWj06xWS4Pxj43KR1N Gv7XLFSlQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jv4jW-0000nC-N1; Mon, 13 Jul 2020 20:07:26 +0000 Received: from mail-pl1-x641.google.com ([2607:f8b0:4864:20::641]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jv4jU-0000jD-Km for linux-rockchip@lists.infradead.org; Mon, 13 Jul 2020 20:07:25 +0000 Received: by mail-pl1-x641.google.com with SMTP id p1so5991557pls.4 for ; Mon, 13 Jul 2020 13:07:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=kmupqMbziJlPy1JRSkwR5KOsOApCHx7mcVYbKMourXI=; b=Lxs+H3O6c9nN7WEK6upbGJ6oLQhSlU9DZvrTY8Dr62Zi8bguz63hGCPBR2tgKqsai/ e4DpiwvoYk7hNamBSh7r7xAhf46eveJcrja0DRq8OPsesQynxTYmAHMhtQdAZ1vKehbS gd/7p75Ku4V2E7NuT1Y78TYH61Xb9tmXUERok= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=kmupqMbziJlPy1JRSkwR5KOsOApCHx7mcVYbKMourXI=; b=Y5Nanmhse/+o3+p0XCkts46hkp1bWEZgCVhSn7CsqS+OpQWP2qVSoXNU0iDnj8nqgA S/gYSVD3hCvWNbH8e3CAjtj1fNibSC0MSzIA7fQa3CoiwbkycAyVD0kRVy6huFv+6IA8 E+ZklnnMiEu5lOhwOmm1PTkmypUnzNjvtkNonJm9RbsLE8pCiK+D3ECJVB20dQ/8oBDs HcxX3J8k6zWs8HcDR66WKTm10MZbW62uhkVHhPqUAhiTr8KQiOq5JaoafFfyzY6w/LRK uougsukdVXYWbADUJ3ikWtxdCn/t+R+KUD7gq8qm5umrLkv03uVBooVFLGru7PAUOjQL TLVQ== X-Gm-Message-State: AOAM533WmJ6rRsw7ZK/PdZ9Jc8rO1CleGwYDT/mkwbphzrk/LcyDUfiv Ix0Ve0DdluaikdA44kiVg06A2A== X-Google-Smtp-Source: ABdhPJxVLg1/Yoic2XARFbz/lOyiwfbcDqVTmT5hSVN0H3iLBVt9lVZc8Br2+DUs74swyiaX70Qiig== X-Received: by 2002:a17:90a:9606:: with SMTP id v6mr1058930pjo.110.1594670842609; Mon, 13 Jul 2020 13:07:22 -0700 (PDT) Received: from localhost.localdomain ([2405:201:c809:c7d5:1c27:6fcc:7acc:eebb]) by smtp.gmail.com with ESMTPSA id e10sm400126pjw.22.2020.07.13.13.07.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 13 Jul 2020 13:07:21 -0700 (PDT) From: Jagan Teki To: Kever Yang , Philipp Tomsich , Simon Glass Subject: [PATCH 2/3] ram: rk3399: Mark existing prints via RAM_ROCKCHIP_DEBUG Date: Tue, 14 Jul 2020 01:36:34 +0530 Message-Id: <20200713200635.651032-2-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200713200635.651032-1-jagan@amarulasolutions.com> References: <20200713200635.651032-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200713_160724_714572_6EFD602D X-CRM114-Status: UNSURE ( 8.95 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.2 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (-0.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2607:f8b0:4864:20:0:0:0:641 listed in] [list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: U-Boot-Denx , linux-rockchip@lists.infradead.org, linux-amarula , Jagan Teki , Suniel Mahesh Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org Right now all these debug statements are printing on the console to make sure proper dram initialization happens.   Mark them into RAM_ROCKCHIP_DEBUG would be more meaningful and work like before since the RAM_ROCKCHIP_DEBUG is by default yet. No functionality changes. Signed-off-by: Jagan Teki Reviewed-by: Kever Yang --- drivers/ram/rockchip/sdram_rk3399.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/drivers/ram/rockchip/sdram_rk3399.c b/drivers/ram/rockchip/sdram_rk3399.c index d2f3fde236..670925420d 100644 --- a/drivers/ram/rockchip/sdram_rk3399.c +++ b/drivers/ram/rockchip/sdram_rk3399.c @@ -2551,8 +2551,10 @@ static int lpddr4_set_rate(struct dram_info *dram, lpddr4_set_ctl(dram, params, ctl_fn, dfs_cfgs_lpddr4[ctl_fn].base.ddr_freq); - printf("%s: change freq to %d mhz %d, %d\n", __func__, - dfs_cfgs_lpddr4[ctl_fn].base.ddr_freq, ctl_fn, phy_fn); + if (IS_ENABLED(CONFIG_RAM_ROCKCHIP_DEBUG)) + printf("%s: change freq to %d mhz %d, %d\n", __func__, + dfs_cfgs_lpddr4[ctl_fn].base.ddr_freq, + ctl_fn, phy_fn); } return 0; @@ -2966,8 +2968,10 @@ static int sdram_init(struct dram_info *dram, params->base.num_channels++; } - printf("Channel "); - printf(channel ? "1: " : "0: "); + if (IS_ENABLED(CONFIG_RAM_ROCKCHIP_DEBUG)) { + printf("Channel "); + printf(channel ? "1: " : "0: "); + } if (channel == 0) set_ddr_stride(dram->pmusgrf, 0x17);