mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Trey Ramsay <tramsay@linux.vnet.ibm.com>
To: Chris Ball <cjb@laptop.org>
Cc: linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org,
	Rich Rattanni <rattanni@gmail.com>,
	Radovan Lekanovic <lekanovic@gmail.com>
Subject: Re: [PATCH 1/1] mmc: Bad device can cause mmc driver to hang
Date: Fri, 16 Nov 2012 23:16:21 -0600	[thread overview]
Message-ID: <50A71DA5.2070905@linux.vnet.ibm.com> (raw)
In-Reply-To: <87mwyh9ia0.fsf@octavius.laptop.org>

On 11/16/2012 06:37 PM, Chris Ball wrote:
> Hi Trey, thanks for the analysis,
> 
> On Fri, Nov 16 2012, Trey Ramsay wrote:
>> Good question.  In regards to the original problem were it was hung in
>> mmc_blk_err_check, the new code path will timeout after 10 minutes, log
>> an error, issue a hardware reset and abort the request. Is the hardware
>> reset enough or will that even work when the device isn't coming out of
>> program state? Should we try to refuse all new I/O?
> 
> mmc_hw_reset() only works for eMMC devices with a hooked up reset GPIO
> -- not SD cards -- and at the moment there's only one system (Intel
> Medfield) that supplies a GPIO, so that's not a general solution.
> 
> Maybe we should just merge your patch for now; we'll definitely get at
> least a pr_err() explaining what's going on, which is an improvement.
> Next time someone hits this (if anyone has an SD card that exhibits
> this problem, it'd be very valuable for testing) we can look at going
> farther, such as immediately setting host->flags |= SDHCI_DEVICE_DEAD.
> What do you think?
> 
> - Chris.
> 

Hi Chris,
Sounds good.  Thanks for the explanation. Setting host->flags |=
SDHCI_DEVICE_DEAD is a great idea.  I'll check with my team to see if we
have any hardware that exhibits this problem.  If we do, I can do some
testing on the code you suggested.

Thanks,
Trey


  reply	other threads:[~2012-11-17  5:16 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-31 19:36 drivers/mmc/card/block.c infinite loop in mmc_blk_err_check waiting on R1_READY_FOR_DATA Trey Ramsay
2012-10-31 20:47 ` Chris Ball
     [not found]   ` <50A2A08D.5000601@linux.vnet.ibm.com>
2012-11-13 20:48     ` Chris Ball
2012-11-16 15:31       ` [PATCH 1/1] mmc: Bad device can cause mmc driver to hang Trey Ramsay
2012-11-16 15:37         ` Chris Ball
2012-11-16 23:52           ` Trey Ramsay
2012-11-17  0:37             ` Chris Ball
2012-11-17  5:16               ` Trey Ramsay [this message]
2012-11-17  0:40           ` Trey Ramsay
2012-11-17 14:34         ` Chris Ball

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=50A71DA5.2070905@linux.vnet.ibm.com \
    --to=tramsay@linux.vnet.ibm.com \
    --cc=cjb@laptop.org \
    --cc=lekanovic@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=rattanni@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome