From patchwork Tue Jul 16 11:57:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 775 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-pg1-f197.google.com (mail-pg1-f197.google.com [209.85.215.197]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 844A03F08F for ; Tue, 16 Jul 2019 13:59:30 +0200 (CEST) Received: by mail-pg1-f197.google.com with SMTP id w5sf12495022pgs.5 for ; Tue, 16 Jul 2019 04:59:30 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1563278369; cv=pass; d=google.com; s=arc-20160816; b=CKnLhRSz4SbsovhoN67qVtt1LBebpN5M+mktHSWPsyRVEUU6EgfROaa96+ekgHcGkc IVsjqEWEnVDNVR1gTVzBFyh2dtpCoCmoBqizczPLdSE3+5xPhhFabigvt2Cp3DOLReLd fjgZTxDVcE8FPYKIA3MsSX/qglrjXeC//Md5cgDiLsM9cNnbhCILF3XSklbS/mBmPUT1 M/wfgTplHPThT9xxxC1ghS6e1CblEaoeiu7A1Fm77lMlFSI81Olvpoti/NfWp+eaDwFY t7cGjIaV+eB0hErIGPBOYgbXrYd7aLhsNoNb0EKRsULZGgDbp5yYGo5W2/AGGg87RBCT 1QwQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=R4GRoo3Upq+rvmJl3xxpBjTkZJqPIqPiQtazy/mxx5c=; b=ys15UQyLZUuASvSsP7J0BNWfdgF6WvyrkeTJvqiGYRMrUEyrFZvfyFfFzdTEULLnpF q6BNtb3POpykaH5PW6mzHSJ7KabRQITnk5A7QB0K2iIwn+fHQ0h242Z3XH7Fq3ZWR0pU +WvooQF78mnQ0uGokqaCeHb49aproxO78pX688hUlYXdlHWrsn4Q4nWNjBcRQYM29eSf NNlwZK9oC7jjMrW/zQ8aPT9g6xiRj6BffwjbiaNXD4/r1Byk5lGABHI98FkKlZ5hqPX1 EUUZDJxH3VtnkYr2WoTcVXKXDUe4AWPSZIA0PxV7U2NGrwD6ZS8JcGMgqDsLWArNpgS9 7k1g== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=OMtEuoLB; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com 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:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=R4GRoo3Upq+rvmJl3xxpBjTkZJqPIqPiQtazy/mxx5c=; b=jlxbmF0aqf8FtyQI7mTmhH+0ZeOzZZMR81O6XThn+yMFQMxheQfnUvCu/25s92Mtgn p4UUqCyOozPI+ufwCq1yzdh44NtvG3DrGfPTl6aMmHPs0OC/7gdhd7cw8mvg9LWNhLs3 6eLLfHDEuaoxqLWnrnoJ6OIAWQTIbQDhfwi9E= 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:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-spam-checked-in-group:list-post:list-help:list-archive :list-unsubscribe; bh=R4GRoo3Upq+rvmJl3xxpBjTkZJqPIqPiQtazy/mxx5c=; b=USjmq+MNrwWT9JwmomeJus2DpINM8k1JdtuwAQWv9D2NkZBExZY0ZUndJ88Z50koam CC9XYd5Ps87+qBMg7uiKk24Q/DWAHsr05pm43Jb5QaiiA36JkAzwlWBodCf7DLyeOkSh +9V83BcI54gCmiFauiDw5CIrgfjl5LEbaUdLdb9n7iM2VdoYQuushfmSCauYVpoNHQab xIYbyFXZ58JWpablDZKiJ+sv+8ZoGFRvrPXV6VJ+gLfHcB2ZEsyCsG3YFtapMu+GsJr2 AUkF6lmthGT+00AHL/bSJbAu+dO9bXjRbssSpWdsRpQRWjYQesVyg4SsXNUliLJi5ACa PxRg== X-Gm-Message-State: APjAAAUiaL79HCKtjsiW1fJpPeMg2d+Pg+9gPuwYLExB7oqNIv+QR5C9 kpU7bmaYhE/sTIlznJ+4Rayq/nkO X-Google-Smtp-Source: APXvYqwbpAxE6h/+PcM04KT7+R/MkcIIMJkOiM+m35QKtBc90kRBrgq3Ynl701qg0qbcuKfTStLQfA== X-Received: by 2002:a17:902:8509:: with SMTP id bj9mr35071638plb.79.1563278369384; Tue, 16 Jul 2019 04:59:29 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a17:902:680d:: with SMTP id h13ls3344311plk.13.gmail; Tue, 16 Jul 2019 04:59:29 -0700 (PDT) X-Received: by 2002:a17:90a:5288:: with SMTP id w8mr35894107pjh.61.1563278369057; Tue, 16 Jul 2019 04:59:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563278369; cv=none; d=google.com; s=arc-20160816; b=enR8PgG6YF3+hEfZPMgTIukkNRkhrw1cGBluKM0f0cyZWn2sfltf0nWnDWrHtGYC1Q 1kMQ+Ulfp0lU+RICLUSZqiaY4NLBb2pgTZ1wSY/uxG8+xqu+RhTV5J9AIw7NWnJ4GAMM BCuHbeIfJCWD+ilVkwp6EImyGHZ2qNvF19YW42segtwZuaPOmwFYs2kJSAyiHuaqTAac T4710njF/7mOZoQqi1eQ3FypdqiF5ooFlaT4Nqh2HpTRUE0hAdBuF5K3pyOmPR0xJ+Z6 Qc6xFmIOkl5OdHecU7pIByaevqmdB6pQGZ8Kw4jpnvFcMOJyOeqXCfCx4u0AR59qQUFt GMpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=uqu7PB29bSdtqH47pAusxbjypIHUbAZ//ch+/8e+yqE=; b=QqQ5fFm9rFQA4sf+Qn9fK3S9N3X6WVhie11GgKPpcPZk8HUfbUrag/Emo1Xo62a8av 5CgLZnV6vi2m0+8bVpQ4QCjTzBqa6CLio2hOi/whMLQH98gUVjoiW/qrLWZIPq2Cjdjf gSwZxDJN7kB4PlMiHCZ4mbaV1+9duOHnijO3yEUgrwkFBltzXTUNHyaDEShg4qIi9Gg8 kpFOZTzXHU2uwP+OXQ8McJBTH5gV8d2x25hVhIudbnpggUpMdLvi64vc3jm6dJgor5dA 8hbJaaLqWQMFyiWN0i68NJV5lMe47f0ntj2ec2m5A00+aRNgbeWk3ORhWAkeUhPb0tBR qpDA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=OMtEuoLB; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id r39sor24694373pld.65.2019.07.16.04.59.29 for (Google Transport Security); Tue, 16 Jul 2019 04:59:29 -0700 (PDT) Received-SPF: pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; X-Received: by 2002:a17:90a:2506:: with SMTP id j6mr36804665pje.129.1563278368728; Tue, 16 Jul 2019 04:59:28 -0700 (PDT) Received: from localhost.localdomain ([49.206.201.107]) by smtp.gmail.com with ESMTPSA id z24sm36269566pfr.51.2019.07.16.04.59.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 16 Jul 2019 04:59:28 -0700 (PDT) From: Jagan Teki To: Simon Glass , Philipp Tomsich , Kever Yang , YouMin Chen , u-boot@lists.denx.de Cc: Manivannan Sadhasivam , gajjar04akash@gmail.com, linux-rockchip@lists.infradead.org, linux-amarula@amarulasolutions.com, Jagan Teki Subject: [PATCH v3 26/57] ram: rk3399: Configure PHY_898, PHY_919 for lpddr4 Date: Tue, 16 Jul 2019 17:27:14 +0530 Message-Id: <20190716115745.12585-27-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20190716115745.12585-1-jagan@amarulasolutions.com> References: <20190716115745.12585-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-Original-Sender: jagan@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=OMtEuoLB; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , PHY_898, PHY_919 would require to configure PHY LP4 boot pll control and ca for lpddr4. So, configure the same in pctl_cfg for LPDDR4. Signed-off-by: Jagan Teki Signed-off-by: YouMin Chen Reviewed-by: Kever Yang --- drivers/ram/rockchip/sdram_rk3399.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/ram/rockchip/sdram_rk3399.c b/drivers/ram/rockchip/sdram_rk3399.c index beb4f6de54..7625506458 100644 --- a/drivers/ram/rockchip/sdram_rk3399.c +++ b/drivers/ram/rockchip/sdram_rk3399.c @@ -574,6 +574,11 @@ static int pctl_cfg(struct dram_info *dram, const struct chan_info *chan, writel(params->phy_regs.denali_phy[911], &denali_phy[911]); writel(params->phy_regs.denali_phy[912], &denali_phy[912]); + if (IS_ENABLED(CONFIG_RAM_RK3399_LPDDR4)) { + writel(params->phy_regs.denali_phy[898], &denali_phy[898]); + writel(params->phy_regs.denali_phy[919], &denali_phy[919]); + } + dram->pwrup_srefresh_exit[channel] = readl(&denali_ctl[68]) & PWRUP_SREFRESH_EXIT; clrbits_le32(&denali_ctl[68], PWRUP_SREFRESH_EXIT);