All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Ball <cjb@laptop.org>
To: Matt Fleming <matt@console-pimps.org>
Cc: Jaehoon Chung <jh80.chung@samsung.com>,
	linux-mmc@vger.kernel.org,
	Kyungmin Park <kyungmin.park@samsung.com>,
	Marek Szyprowski <m.szyprowski@samsung.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Ben Dooks <ben-linux@fluff.org>,
	Ben Hutchings <ben@decadent.org.uk>,
	Yunpeng Gao <yunpeng.gao@intel.com>
Subject: Re: [PATCH 2/2] sdhci: disable MMC_CAP_NEEDS_POLL in nonremovable case
Date: Wed, 15 Sep 2010 21:38:55 +0100	[thread overview]
Message-ID: <20100915203855.GA6620@void.printf.net> (raw)
In-Reply-To: <20100915151142.GB21538@console-pimps.org>

Hi Matt,

On Wed, Sep 15, 2010 at 04:11:42PM +0100, Matt Fleming wrote:
> Chris, are you OK to pick this up (including Jaehoon's change)? Or
> would you prefer me to resubmit?

Thanks, that's fine, I've applied both patches to mmc-next:

http://git.kernel.org/?p=linux/kernel/git/cjb/mmc.git;a=commit;h=c1e1b0d22967e9ddd02c3099e894c888798c56ea
http://git.kernel.org/?p=linux/kernel/git/cjb/mmc.git;a=commit;h=5c0e8a196827961f7256879e5e45d34ad5d61430

I modified the changelog and indentation for this one, resulting in the
patch below; please check it over and let me know if anything's wrong:

From: Jaehoon Chung <jh80.chung@samsung.com>
Date: Wed, 15 Sep 2010 15:30:20 -0400
Subject: [PATCH 2/2] mmc: sdhci: disable MMC_CAP_NEEDS_POLL in nonremovable case

When a controller requires SDHCI_QUIRK_BROKEN_CARD_DETECTION, we poll
for card insertion/removal, and that creates interrupts.  There's no
need to be doing this if we have a non-removable card.

This patch requires cards to be removable before we're willing to set
MMC_CAP_NEEDS_POLL.

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Acked-by: Kyungmin Park <kyungmin.park@samsung.com>
Cc: Matt Fleming <matt@console-pimps.org>
[cjb: modified changelog and code indentation]
Signed-off-by: Chris Ball <cjb@laptop.org>
---
 drivers/mmc/host/sdhci.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index ac8b12b..fb6b170 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -1846,7 +1846,8 @@ int sdhci_add_host(struct sdhci_host *host)
 	if (caps & SDHCI_CAN_DO_HISPD)
 		mmc->caps |= MMC_CAP_SD_HIGHSPEED;
 
-	if (host->quirks & SDHCI_QUIRK_BROKEN_CARD_DETECTION)
+	if ((host->quirks & SDHCI_QUIRK_BROKEN_CARD_DETECTION) &&
+	    mmc_card_is_removable(mmc))
 		mmc->caps |= MMC_CAP_NEEDS_POLL;
 
 	mmc->ocr_avail = 0;
-- 
1.7.2.2

-- 
Chris Ball   <cjb@laptop.org>   <http://printf.net/>
One Laptop Per Child

  parent reply	other threads:[~2010-09-15 20:38 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-27  6:34 [PATCH] sdhci: disable MMC_CAP_NEEDS_POLL in nonremovable case Jaehoon Chung
2010-08-27  7:09 ` Matt Fleming
2010-08-27  7:14   ` Kyungmin Park
2010-08-27 11:55     ` Gao, Yunpeng
2010-08-28 13:37       ` Matt Fleming
2010-08-28 13:53         ` [PATCH 1/2] mmc: Add helper function to check if a card is removable Matt Fleming
2010-08-28 13:53           ` [PATCH 2/2] sdhci: disable MMC_CAP_NEEDS_POLL in nonremovable case Matt Fleming
2010-08-30  1:06             ` Kyungmin Park
2010-09-02  8:51             ` Jaehoon Chung
2010-09-02  9:14               ` Matt Fleming
2010-09-08  1:27                 ` Jaehoon Chung
2010-09-15 15:11                   ` Matt Fleming
2010-09-15 15:14                     ` Matt Fleming
2010-09-15 20:38                     ` Chris Ball [this message]
2010-09-16  2:20                       ` Chris Ball
2010-09-16  9:02                         ` Matt Fleming
2010-09-26  7:31                           ` zhangfei gao
2010-09-27  8:43                             ` Matt Fleming
2010-08-28 14:13           ` [PATCH 1/2] mmc: Add helper function to check if a card is removable Ben Hutchings
2010-08-28 14:28             ` Matt Fleming
2010-08-30  9:59           ` [PATCH v2] " Matt Fleming
2010-09-02  8:48             ` Jaehoon Chung

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=20100915203855.GA6620@void.printf.net \
    --to=cjb@laptop.org \
    --cc=akpm@linux-foundation.org \
    --cc=ben-linux@fluff.org \
    --cc=ben@decadent.org.uk \
    --cc=jh80.chung@samsung.com \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-mmc@vger.kernel.org \
    --cc=m.szyprowski@samsung.com \
    --cc=matt@console-pimps.org \
    --cc=yunpeng.gao@intel.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.