All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ulf Hansson <ulf.hansson@linaro.org>
To: linux-mmc@vger.kernel.org, Ulf Hansson <ulf.hansson@linaro.org>
Cc: Jaehoon Chung <jh80.chung@samsung.com>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Linus Walleij <linus.walleij@linaro.org>,
	linux-omap@vger.kernel.org, Tony Lindgren <tony@atomide.com>,
	Jarkko Nikula <jarkko.nikula@bitmer.com>
Subject: [PATCH v3 11/15] mmc: omap: Don't use mmc_card_present() when validating for inserted card
Date: Fri, 13 Jan 2017 14:14:12 +0100	[thread overview]
Message-ID: <1484313256-25993-12-git-send-email-ulf.hansson@linaro.org> (raw)
In-Reply-To: <1484313256-25993-1-git-send-email-ulf.hansson@linaro.org>

The mmc_card_present() function helps the mmc core to track an internal
state of the card device. More importantly, it's not intended to be used by
mmc host drivers to check for an inserted card. Therefore, let's stop using
it and instead rely on checking for a valid pointer to a struct mmc_card,
as it should be good enough.

Cc: linux-omap@vger.kernel.org
Cc: Tony Lindgren <tony@atomide.com>
Cc: Jarkko Nikula <jarkko.nikula@bitmer.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Acked-by: Tony Lindgren <tony@atomide.com>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
---
 drivers/mmc/host/omap.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/omap.c b/drivers/mmc/host/omap.c
index be3c49f..bd49f34 100644
--- a/drivers/mmc/host/omap.c
+++ b/drivers/mmc/host/omap.c
@@ -893,7 +893,7 @@ static void mmc_omap_cover_handler(unsigned long param)
 	 * If no card is inserted, we postpone polling until
 	 * the cover has been closed.
 	 */
-	if (slot->mmc->card == NULL || !mmc_card_present(slot->mmc->card))
+	if (slot->mmc->card == NULL)
 		return;
 
 	mod_timer(&slot->cover_timer,
-- 
1.9.1


  parent reply	other threads:[~2017-01-13 13:15 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-13 13:14 [PATCH v3 00/15] mmc: core: A start to slim down public mmc headers Ulf Hansson
2017-01-13 13:14 ` [PATCH v3 01/15] ARM: pxa: Don't rely on public mmc header to include leds.h Ulf Hansson
2017-01-13 13:14   ` Ulf Hansson
2017-01-20  8:01   ` Robert Jarzmik
2017-01-20  8:01     ` Robert Jarzmik
2017-01-20  8:27     ` Ulf Hansson
2017-01-20  8:27       ` Ulf Hansson
2017-01-20 19:34       ` Robert Jarzmik
2017-01-20 19:34         ` Robert Jarzmik
2017-01-22 10:25         ` Robert Jarzmik
2017-01-22 10:25           ` Robert Jarzmik
2017-01-24  7:57           ` Ulf Hansson
2017-01-24  7:57             ` Ulf Hansson
2017-01-24 16:34             ` Robert Jarzmik
2017-01-24 16:34               ` Robert Jarzmik
2017-01-13 13:14 ` [PATCH v3 02/15] ARM: davinci: " Ulf Hansson
2017-01-13 13:14   ` Ulf Hansson
2017-01-13 13:26   ` Sekhar Nori
2017-01-13 13:26     ` Sekhar Nori
2017-01-13 13:14 ` [PATCH v3 03/15] ARM: davinci: Don't rely on public mmc header to include interrupt.h Ulf Hansson
2017-01-13 13:14   ` Ulf Hansson
2017-01-13 13:38   ` Sekhar Nori
2017-01-13 13:38     ` Sekhar Nori
2017-01-13 13:14 ` [PATCH v3 04/15] MIPS: Alchemy: " Ulf Hansson
2017-01-13 13:14   ` Ulf Hansson
2017-01-17 14:50   ` Ralf Baechle
2017-01-13 13:14 ` [PATCH v3 05/15] mmc: core: First step in cleaning up public mmc header files Ulf Hansson
2017-01-16  2:54   ` Shawn Lin
2017-01-13 13:14 ` [PATCH v3 06/15] mmc: core: First step in cleaning up private " Ulf Hansson
2017-01-16  2:56   ` Shawn Lin
2017-01-13 13:14 ` [PATCH v3 07/15] mmc: core: Move public functions from core.h to private headers Ulf Hansson
2017-01-16  3:01   ` Shawn Lin
2017-01-17 15:07     ` Ulf Hansson
2017-01-13 13:14 ` [PATCH v3 08/15] mmc: core: Move some host specific public functions to host.h Ulf Hansson
2017-01-16  3:02   ` Shawn Lin
2017-01-13 13:14 ` [PATCH v3 09/15] mmc: core: Move erase/trim/discard defines from public core.h to mmc.h Ulf Hansson
2017-01-16  3:05   ` Shawn Lin
2017-01-17 15:06     ` Ulf Hansson
2017-01-13 13:14 ` [PATCH v3 10/15] mmc: core: Remove unused struct _mmc_csd from public mmc.h header Ulf Hansson
2017-01-16  3:07   ` Shawn Lin
2017-01-17 15:07     ` Ulf Hansson
2017-01-13 13:14 ` Ulf Hansson [this message]
2017-01-13 13:14 ` [PATCH v3 12/15] mmc: vub300: Don't use mmc_card_present() when validating for inserted card Ulf Hansson
2017-01-13 13:14 ` [PATCH v3 13/15] mmc: core: Move public functions from card.h to private headers Ulf Hansson
2017-01-16  3:10   ` Shawn Lin
2017-01-13 13:14 ` [PATCH v3 14/15] mmc: core: Move public functions from host.h " Ulf Hansson
2017-01-16  3:14   ` Shawn Lin
2017-01-13 13:14 ` [PATCH v3 15/15] mmc: core: Don't use extern declarations of public mmc functions Ulf Hansson
2017-01-16  3:16   ` Shawn Lin
2017-01-17 15:08 ` [PATCH v3 00/15] mmc: core: A start to slim down public mmc headers Ulf Hansson

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=1484313256-25993-12-git-send-email-ulf.hansson@linaro.org \
    --to=ulf.hansson@linaro.org \
    --cc=adrian.hunter@intel.com \
    --cc=jarkko.nikula@bitmer.com \
    --cc=jh80.chung@samsung.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=tony@atomide.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.