From: Marek Vasut <marex@denx.de>
To: Huang Shijie <b32955@freescale.com>
Cc: devicetree@vger.kernel.org, linux-doc@vger.kernel.org,
linux-spi@vger.kernel.org, linux-mtd@lists.infradead.org,
computersforpeace@gmail.com, dwmw2@infradead.org,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v1 2/7] mtd: spi-nor: add DDR quad read support
Date: Thu, 24 Apr 2014 15:43:51 +0200 [thread overview]
Message-ID: <201404241543.51752.marex@denx.de> (raw)
In-Reply-To: <20140424045332.GB29664@localhost>
On Thursday, April 24, 2014 at 06:53:34 AM, Huang Shijie wrote:
> On Wed, Apr 23, 2014 at 09:45:57PM +0200, Marek Vasut wrote:
> > On Wednesday, April 23, 2014 at 12:16:50 PM, Huang Shijie wrote:
> > > This patch adds the DDR quad read support by the following:
> > > [1] add SPI_NOR_DDR_QUAD read mode.
> > >
> > > [2] add DDR Quad read opcodes:
> > > SPINOR_OP_READ_1_4_4_D / SPINOR_OP_READ4_1_4_4_D
> > >
> > > [3] add set_ddr_quad_mode() to initialize for the DDR quad read.
> > >
> > > Currently it only works for Spansion NOR.
> > >
> > > [3] set the dummy with 8 for DDR quad read.
> > >
> > > The m25p80.c can not support the DDR quad read, the SPI NOR
> > >
> > > controller can set the dummy value in its driver, such as
> > > fsl-quadspi.c.
> > >
> > > Test this patch for Spansion s25fl128s NOR flash.
> > >
> > > Signed-off-by: Huang Shijie <b32955@freescale.com>
> > > ---
> > >
> > > drivers/mtd/spi-nor/spi-nor.c | 50
> > >
> > > +++++++++++++++++++++++++++++++++++++++- include/linux/mtd/spi-nor.h
> > > |
> > >
> > > 8 +++++-
> > > 2 files changed, 54 insertions(+), 4 deletions(-)
> > >
> > > diff --git a/drivers/mtd/spi-nor/spi-nor.c
> > > b/drivers/mtd/spi-nor/spi-nor.c index 1a12f81..e2f69db 100644
> > > --- a/drivers/mtd/spi-nor/spi-nor.c
> > > +++ b/drivers/mtd/spi-nor/spi-nor.c
> > > @@ -74,6 +74,15 @@ static int read_cr(struct spi_nor *nor)
> > >
> > > static inline int spi_nor_read_dummy_cycles(struct spi_nor *nor)
> > > {
> > >
> > > switch (nor->flash_read) {
> > >
> > > + case SPI_NOR_DDR_QUAD:
> > > + /*
> > > + * The m25p80.c can not support the DDR quad read.
> > > + * We set the dummy cycles to 8 by default. If the SPI NOR
> > > + * controller driver has already set it before call the
> > > + * spi_nor_scan(), we just keep it as it is.
> > > + */
> > > + if (nor->read_dummy)
> > > + return nor->read_dummy;
> >
> > Can the controller set this variable to zero ?
>
> The default value of this variable is zero. It it meaningless to set zero.
> The DDR Quad read definitely will use a non-zero dummy.
Can you back this by some documentation please ?
I mean, I know I am a hardass here, but please understand I'd like to understand
the decisions that are being made.
next prev parent reply other threads:[~2014-04-24 13:43 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <a>
2014-01-03 3:01 ` [PATCH 0/3] mtd: gpmi: add subpage read support Huang Shijie
2014-02-21 6:51 ` Huang Shijie
2014-03-07 7:27 ` Brian Norris
2014-03-07 7:32 ` Huang Shijie
2014-03-07 7:34 ` Brian Norris
2014-01-03 3:01 ` [PATCH 1/3] mtd: nand: add "page" argument for read_subpage hook Huang Shijie
2014-01-03 3:01 ` [PATCH 2/3] mtd: gpmi: do not use the mtd->writesize Huang Shijie
2014-01-03 3:01 ` [PATCH 3/3] mtd: gpmi: add subpage read support Huang Shijie
2014-04-23 10:16 ` [PATCH v1 0/7] mtd: spi-nor: Add the DDR quad " Huang Shijie
2014-04-23 10:16 ` [PATCH v1 1/7] mtd: spi-nor: fix the wrong dummy value Huang Shijie
2014-04-23 19:41 ` Marek Vasut
2014-04-24 4:50 ` Huang Shijie
2014-04-24 13:45 ` Marek Vasut
2014-04-23 10:16 ` [PATCH v1 2/7] mtd: spi-nor: add DDR quad read support Huang Shijie
2014-04-23 19:45 ` Marek Vasut
2014-04-24 4:53 ` Huang Shijie
2014-04-24 13:43 ` Marek Vasut [this message]
2014-04-24 14:26 ` Huang Shijie
2014-04-23 10:16 ` [PATCH v1 3/7] Documentation: mtd: add a new document for SPI NOR flash Huang Shijie
2014-04-23 10:16 ` [PATCH v1 4/7] Documentation: fsl-quadspi: update the document Huang Shijie
2014-04-23 10:16 ` [PATCH v1 5/7] mtd: fsl-quadspi: get the dummy cycles for DDR Quad read from the DT property Huang Shijie
2014-04-23 19:48 ` Marek Vasut
2014-04-24 4:58 ` Huang Shijie
2014-04-24 13:41 ` Marek Vasut
2014-04-24 14:27 ` Huang Shijie
2014-04-23 10:16 ` [PATCH v1 6/7] mtd: fsl-quadspi: use the information stored in spi-nor{} Huang Shijie
2014-04-23 10:16 ` [PATCH v1 7/7] mtd: fsl-quadspi: add the DDR quad read support Huang Shijie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201404241543.51752.marex@denx.de \
--to=marex@denx.de \
--cc=b32955@freescale.com \
--cc=computersforpeace@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=dwmw2@infradead.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=linux-spi@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox