Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1578691

Re: [PATCH 1/1] mtd: spi-nor: remove WARN_ONCE() message in spi_nor_write()

From Brian Norris <computersforpeace@gmail.com>
Newsgroups linux.kernel
Subject Re: [PATCH 1/1] mtd: spi-nor: remove WARN_ONCE() message in spi_nor_write()
Date 2017-02-10 19:40 +0100
Message-ID <t9ogV-77S-1@gated-at.bofh.it> (permalink)
References <sLrzk-4WB-51@gated-at.bofh.it> <sM97k-7Se-55@gated-at.bofh.it> <sNYKt-3R9-27@gated-at.bofh.it> <t8MEG-8rI-9@gated-at.bofh.it> <t8Xqr-6QJ-31@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thu, Feb 09, 2017 at 02:50:02PM +0100, Cyrille Pitchen wrote:
> In most, if not all, cases this warning is a false positive as for most
> memories it is valid to write a single page with more than one Page Program
> commands or to write data starting from the middle of the page.

Right, I agree that many cases were false positives, and the WARN is
rather scary, so it's definitely good to drop the WARN. And I've already
pulled that patch in, so we're good :)

> The only hardware limitation at the SPI NOR side is that we can't cross the
> page boundary.

Is it the *only* limitation? Marcin pointed out that at least for some
Macronix flash:

http://www.macronix.com/Lists/ApplicationNote/Attachments/1606/AN0302V1%20-%20MX25L_G%20Serial%20Flash%20Programming%20Guide.pdf

  "it is strongly recommended that data be written to the MX25L_G using
  full 256-byte pages"

.

Now I don't claim the original WARN captured this recommendation
correctly, but I was just nudging people to consider the original
intention.

> If we would do so, internally the SPI NOR memory would wrap
> the address instead of incrementing it hence the additional data would be
> written at the beginning of the same page and not at the beginning of the
> next one.

Brian

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: [PATCH 1/1] mtd: spi-nor: remove WARN_ONCE() message in  spi_nor_write() Brian Norris <computersforpeace@gmail.com> - 2017-02-09 03:30 +0100
  Re: [PATCH 1/1] mtd: spi-nor: remove WARN_ONCE() message in  spi_nor_write() Cyrille Pitchen <cyrille.pitchen@atmel.com> - 2017-02-09 15:00 +0100
    Re: [PATCH 1/1] mtd: spi-nor: remove WARN_ONCE() message in  spi_nor_write() Brian Norris <computersforpeace@gmail.com> - 2017-02-10 19:40 +0100

csiph-web