From patchwork Thu Mar 11 19:12:10 2021
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Pratyush Yadav
X-Patchwork-Id: 1451475
Return-Path:
X-Original-To: incoming@patchwork.ozlabs.org
Delivered-To: patchwork-incoming@bilbo.ozlabs.org
Authentication-Results: ozlabs.org;
spf=none (no SPF record) smtp.mailfrom=lists.infradead.org
(client-ip=2001:8b0:10b:1:d65d:64ff:fe57:4e05; helo=desiato.infradead.org;
envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org;
receiver=)
Authentication-Results: ozlabs.org;
dkim=pass (2048-bit key;
secure) header.d=lists.infradead.org header.i=@lists.infradead.org
header.a=rsa-sha256 header.s=desiato.20200630 header.b=OasS7K+R;
dkim=fail reason="signature verification failed" (1024-bit key;
unprotected) header.d=ti.com header.i=@ti.com header.a=rsa-sha256
header.s=ti-com-17Q1 header.b=U0Gg9VpI;
dkim-atps=neutral
Received: from desiato.infradead.org (desiato.infradead.org
[IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest
SHA256)
(No client certificate requested)
by ozlabs.org (Postfix) with ESMTPS id 4DxJWn3XPLz9sCD
for ; Fri, 12 Mar 2021 06:13:41 +1100 (AEDT)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding
:Content-Type:List-Subscribe:List-Help:List-Post:List-Archive:
List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:CC:To:From:
Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender
:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner;
bh=XlGbStN8062sdu3J1Kkk54U5N+ivFdsh3JXZv+KsEKI=; b=OasS7K+RlRgLX+qXD3qJxiQVZT
rz5b4Y8jMT1d0r+/G5K740m4ZYbONWyZFZlCKsgOik6NdJ3RMSBPyjuEb0rmXyOwJQrYYFrP5lZ17
3CeOhdng15gWCsXw1JUH8OPiF3UyMu2eTZbzqE/dsb2mMLYgcRnOouKU8TJzXMK8m+OSAIAA0M/6E
+RTRmaTRj3OgHb3PaHap84a1zjYCBfx7gwiAiO4ycdOKq/1AaiC7+lpCi0MMocakc2Feg1b5TEyPK
BW5DyDAdE8pow56mLGo5s5QsQVYRCIbfSpB8Kn/QcQ7fRPsHRZjR7PbSJ7y/a61DxG0kll+1nTjUp
tJWFm6vw==;
Received: from localhost ([::1] helo=desiato.infradead.org)
by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux))
id 1lKQja-009wi4-CY; Thu, 11 Mar 2021 19:12:34 +0000
Received: from fllv0015.ext.ti.com ([198.47.19.141])
by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux))
id 1lKQjT-009wgu-SU; Thu, 11 Mar 2021 19:12:30 +0000
Received: from fllv0034.itg.ti.com ([10.64.40.246])
by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 12BJCMBG123822;
Thu, 11 Mar 2021 13:12:22 -0600
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com;
s=ti-com-17Q1; t=1615489942;
bh=K10iL76Rgk2W/O4gIBcHwJ90W5MxbdgPMg2+TPXlU58=;
h=From:To:CC:Subject:Date;
b=U0Gg9VpIDlC5XhTwNU5ZcXVGc0e4yE6p72o3dGXDfKhIEpPaOrzft/ZrAYp0Ce7tF
WYtqiP0mHXUJa3hg1kZWSHKB8ctox+3fwEkjSXaEEVg+RIUWEOxyv8uAkcOZiFkhl7
8ajsTiqpSAgfgrWluhKM5zMPqFDWxjDWFuDab7Dg=
Received: from DFLE102.ent.ti.com (dfle102.ent.ti.com [10.64.6.23])
by fllv0034.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 12BJCM8t112956
(version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL);
Thu, 11 Mar 2021 13:12:22 -0600
Received: from DFLE113.ent.ti.com (10.64.6.34) by DFLE102.ent.ti.com
(10.64.6.23) with Microsoft SMTP Server (version=TLS1_2,
cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2176.2; Thu, 11
Mar 2021 13:12:22 -0600
Received: from fllv0039.itg.ti.com (10.64.41.19) by DFLE113.ent.ti.com
(10.64.6.34) with Microsoft SMTP Server (version=TLS1_2,
cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2176.2 via
Frontend Transport; Thu, 11 Mar 2021 13:12:22 -0600
Received: from pratyush-OptiPlex-790.dhcp.ti.com (ileax41-snat.itg.ti.com
[10.172.224.153])
by fllv0039.itg.ti.com (8.15.2/8.15.2) with ESMTP id 12BJCHvR080816;
Thu, 11 Mar 2021 13:12:17 -0600
From: Pratyush Yadav
To: Nishanth Menon , Tero Kristo , Rob Herring
, Tudor Ambarus , Michael
Walle , Miquel Raynal ,
Richard Weinberger , Vignesh Raghavendra ,
Mark Brown ,
, ,
, ,
CC: Pratyush Yadav , Lokesh Vutla
Subject: [RFC PATCH 0/6] spi: Add OSPI PHY calibration support for
spi-cadence-quadspi
Date: Fri, 12 Mar 2021 00:42:10 +0530
Message-ID: <20210311191216.7363-1-p.yadav@ti.com>
X-Mailer: git-send-email 2.30.0
MIME-Version: 1.0
X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180
X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3
X-CRM114-CacheID: sfid-20210311_191228_427682_5B9F1848
X-CRM114-Status: GOOD ( 13.47 )
X-Spam-Score: -2.8 (--)
X-Spam-Report: Spam detection software,
running on the system "desiato.infradead.org",
has NOT identified this incoming email as spam. The original
message has been attached to this so you can view it or label
similar future email. If you have any questions, see
the administrator of that system for details.
Content preview: Hi,
This series adds support for OSPI PHY calibration on the
Cadence OSPI controller. This calibration procedure is needed to allow high
clock speeds in 8D-8D-8D mode. The procedure reads some pre-determi [...]
Content analysis details: (-2.8 points, 5.0 required)
pts rule name description
---- ----------------------
--------------------------------------------------
-0.0 RCVD_IN_MSPIKE_H4 RBL: Very Good reputation (+4)
[198.47.19.141 listed in wl.mailspike.net]
-2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/,
medium trust [198.47.19.141 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 Message has at least one valid DKIM or DK signature
-0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from
envelope-from domain
0.1 DKIM_SIGNED Message has a DKIM or DK signature,
not necessarily
valid
-0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from
author's domain
-0.0 RCVD_IN_MSPIKE_WL Mailspike good senders
-0.3 DKIMWL_WL_HIGH DKIMwl.org - High trust sender
X-BeenThere: linux-mtd@lists.infradead.org
X-Mailman-Version: 2.1.34
Precedence: list
List-Id: Linux MTD discussion mailing list
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Sender: "linux-mtd"
Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org
Hi,
This series adds support for OSPI PHY calibration on the Cadence OSPI
controller. This calibration procedure is needed to allow high clock
speeds in 8D-8D-8D mode. The procedure reads some pre-determined pattern
data from the flash and runs a sequence of test reads to find out the
optimal delays for high speed transfer. More details on the calibration
procedure in patch 5/6.
The main problem here is telling the controller where to find the
pattern and how to read it. This RFC uses nvmem cells which point to a
fixed partition containing the data to do the reads. It depends on [0]
and [1].
The obvious problem with this is it won't work when the partitions are
defined via command line. I don't see any good way to add nvmem cells to
command line partitions. I would like some help or ideas here. We don't
necessarily have to use nvmem either. Any way that can cleanly and
consistently let the controller find out where the pattern is stored is
good.
The dts patch depends on [2].
Tested on TI's J721E EVM.
[0] https://patchwork.ozlabs.org/project/linux-mtd/patch/20210302190012.1255-1-zajec5@gmail.com/
[1] https://patchwork.ozlabs.org/project/linux-mtd/patch/20210308011853.19360-1-ansuelsmth@gmail.com/
[2] https://patchwork.kernel.org/project/linux-arm-kernel/patch/20210305153926.3479-2-p.yadav@ti.com/
Pratyush Yadav (6):
spi: spi-mem: Tell controller when device is ready for calibration
mtd: spi-nor: core: consolidate read op creation
mtd: spi-nor: core: run calibration when initialization is done
spi: cadence-qspi: Use PHY for DAC reads if possible
spi: cadence-qspi: Tune PHY to allow running at higher frequencies
arm64: dts: ti: k3-j721e-som-p0: Enable PHY calibration
arch/arm64/boot/dts/ti/k3-j721e-som-p0.dtsi | 55 ++
drivers/mtd/spi-nor/core.c | 74 +-
drivers/spi/spi-cadence-quadspi.c | 820 +++++++++++++++++++-
drivers/spi/spi-mem.c | 12 +
include/linux/spi/spi-mem.h | 8 +
5 files changed, 916 insertions(+), 53 deletions(-)
---
2.30.0