public inbox for stable@vger.kernel.org
 help / color / mirror / Atom feed
From: "Christian Löhle" <CLoehle@hyperstone.com>
To: "gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
	"stable@vger.kernel.org" <stable@vger.kernel.org>
Cc: Ulf Hansson <ulf.hansson@linaro.org>,
	Adrian Hunter <adrian.hunter@intel.com>
Subject: Re: [PATCH] mmc: block: fix read single on recovery logic
Date: Fri, 18 Feb 2022 10:36:47 +0000	[thread overview]
Message-ID: <03b3664476424756867d9dd76f984002@hyperstone.com> (raw)
In-Reply-To: <Yg92AW1onRd47G9z@kroah.com>

This is the backport for 4.19, it applied for more recent branches and is not applicable to 4.14.



From: gregkh@linuxfoundation.org <gregkh@linuxfoundation.org>
Sent: Friday, February 18, 2022 11:33 AM
To: Christian Löhle
Cc: stable@vger.kernel.org; Ulf Hansson; Adrian Hunter
Subject: Re: [PATCH] mmc: block: fix read single on recovery logic
    
On Fri, Feb 18, 2022 at 09:50:54AM +0000, Christian Löhle wrote:
> commit 54309fde1a352ad2674ebba004a79f7d20b9f037 upstream.
> 
> On reads with MMC_READ_MULTIPLE_BLOCK that fail,
> the recovery handler will use MMC_READ_SINGLE_BLOCK for
> each of the blocks, up to MMC_READ_SINGLE_RETRIES times each.
> The logic for this is fixed to never report unsuccessful reads
> as success to the block layer.
> 
> On command error with retries remaining, blk_update_request was
> called with whatever value error was set last to.
> In case it was last set to BLK_STS_OK (default), the read will be
> reported as success, even though there was no data read from the device.
> This could happen on a CRC mismatch for the response,
> a card rejecting the command (e.g. again due to a CRC mismatch).
> In case it was last set to BLK_STS_IOERR, the error is reported correctly,
> but no retries will be attempted.
> 
> Fixes: 81196976ed946c ("mmc: block: Add blk-mq support")
> 
> Signed-off-by: Christian Loehle <cloehle@hyperstone.com>
> ---
>  drivers/mmc/core/block.c | 28 ++++++++++++++--------------
>  1 file changed, 14 insertions(+), 14 deletions(-)

What stable branch(s) is this backport for?

thanks,

greg k-h
    =
Hyperstone GmbH | Reichenaustr. 39a  | 78467 Konstanz
Managing Director: Dr. Jan Peter Berns.
Commercial register of local courts: Freiburg HRB381782


  reply	other threads:[~2022-02-18 10:36 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-17 19:14 FAILED: patch "[PATCH] mmc: block: fix read single on recovery logic" failed to apply to 4.19-stable tree gregkh
2022-02-18  9:50 ` [PATCH] mmc: block: fix read single on recovery logic Christian Löhle
2022-02-18 10:33   ` gregkh
2022-02-18 10:36     ` Christian Löhle [this message]
2022-02-18 10:49       ` gregkh
     [not found]       ` <916c2090-5b39-e9e8-190e-d0f8a77adfa3@intel.com>
2022-02-18 11:05         ` Christian Löhle
2022-02-18 11:47           ` Greg Kroah-Hartman

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=03b3664476424756867d9dd76f984002@hyperstone.com \
    --to=cloehle@hyperstone.com \
    --cc=adrian.hunter@intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=stable@vger.kernel.org \
    --cc=ulf.hansson@linaro.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