From: Brian Norris <computersforpeace@gmail.com>
To: Michal Suchanek <hramrach@gmail.com>
Cc: "Hou Zhiqiang" <B48286@freescale.com>,
"David Woodhouse" <dwmw2@infradead.org>,
"Han Xu" <han.xu@freescale.com>,
"Rafał Miłecki" <zajec5@gmail.com>,
"Ben Hutchings" <ben@decadent.org.uk>,
"Marek Vasut" <marex@denx.de>, "Gabor Juhos" <juhosg@openwrt.org>,
"Bean Huo 霍斌斌," <beanhuo@micron.com>,
linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org,
"Heiner Kallweit" <hkallweit1@gmail.com>,
"Huang Shijie" <shijie.huang@arm.com>
Subject: Re: [PATCH v4 0/7] Add spi-nor SPI transfer error handling
Date: Thu, 19 Nov 2015 15:43:23 -0800 [thread overview]
Message-ID: <20151119234323.GO64635@google.com> (raw)
In-Reply-To: <cover.1439543572.git.hramrach@gmail.com>
Hi Michal,
On Fri, Aug 14, 2015 at 09:23:06AM -0000, Michal Suchanek wrote:
> Hello,
>
> with these patches SPI transfer errors are not silently ignored but rather
> reported to spi-nor users.
>
> This should prevent silently dropping data to the floor in cases when the SPI
> transfer fails and the failure is detected.
>
> It has been pointed out that MTD users do not handle the case when data is read
> only partially so this version adds the last patch which handles this in
> spi-nor.
>
> Thanks
>
> Michal
>
> Michal Suchanek (7):
> mtd: spi-nor: change return value of read/write
> mtd: m25p80: return amount of data transferred or error in read/write
> mtd: fsl-quadspi: return amount of data read/written or error
> mtd: spi-nor: check return value from read/write
> mtd: spi-nor: stop passing around retlen
Patches 1 to 5 look good to me, though there is a new spi-nor driver
since you sent this. Can you rebase/fixup?
> mtd: spi-nor: simplify write loop
> mtd: spi-nor: add read loop
I posted some comments for these. I get the feeling that patch 6 is
over-complicated and should be just a simple assertion. And I'm still
not 100% sure on the approach for patch 7, since it's not clear whether
the responsibility lies in the SPI layer or in MTD.
Brian
> drivers/mtd/devices/m25p80.c | 33 +++++++++------
> drivers/mtd/spi-nor/fsl-quadspi.c | 29 ++++++-------
> drivers/mtd/spi-nor/spi-nor.c | 85 +++++++++++++++++++++++----------------
> include/linux/mtd/spi-nor.h | 8 ++--
> 4 files changed, 91 insertions(+), 64 deletions(-)
>
> --
> 2.1.4
>
prev parent reply other threads:[~2015-11-19 23:43 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-14 9:23 [PATCH v4 0/7] Add spi-nor SPI transfer error handling Michal Suchanek
2015-08-14 9:23 ` [PATCH v4 4/7] mtd: spi-nor: check return value from read/write Michal Suchanek
2015-08-14 9:23 ` [PATCH v4 2/7] mtd: m25p80: return amount of data transferred or error in read/write Michal Suchanek
2015-08-14 9:23 ` [PATCH v4 1/7] mtd: spi-nor: change return value of read/write Michal Suchanek
2015-08-14 9:23 ` [PATCH v4 3/7] mtd: fsl-quadspi: return amount of data read/written or error Michal Suchanek
2015-08-14 9:23 ` [PATCH v4 5/7] mtd: spi-nor: stop passing around retlen Michal Suchanek
2015-08-14 9:23 ` [PATCH v4 6/7] mtd: spi-nor: simplify write loop Michal Suchanek
2015-11-19 23:18 ` Brian Norris
2015-11-20 18:59 ` Michal Suchanek
2015-08-14 9:23 ` [PATCH v4 7/7] mtd: spi-nor: add read loop Michal Suchanek
2015-08-14 10:02 ` Andrew Murray
2015-08-14 10:08 ` Michal Suchanek
2015-11-05 3:39 ` Hou Zhiqiang
2015-11-05 3:39 ` Hou Zhiqiang
2015-11-20 19:18 ` Michal Suchanek
2016-01-12 6:35 ` Zhiqiang Hou
2015-11-19 23:39 ` Brian Norris
2015-11-20 6:26 ` Heiner Kallweit
2015-08-15 1:51 ` [PATCH v4 0/7] Add spi-nor SPI transfer error handling Bean Huo 霍斌斌 (beanhuo)
2015-08-15 1:51 ` Bean Huo 霍斌斌 (beanhuo)
2015-08-16 10:20 ` Michal Suchanek
2015-11-19 23:43 ` Brian Norris [this message]
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=20151119234323.GO64635@google.com \
--to=computersforpeace@gmail.com \
--cc=B48286@freescale.com \
--cc=beanhuo@micron.com \
--cc=ben@decadent.org.uk \
--cc=dwmw2@infradead.org \
--cc=han.xu@freescale.com \
--cc=hkallweit1@gmail.com \
--cc=hramrach@gmail.com \
--cc=juhosg@openwrt.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=marex@denx.de \
--cc=shijie.huang@arm.com \
--cc=zajec5@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.