public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Matthew Garrett <mjg59@srcf.ucam.org>
To: Frans Pop <elendil@planet.nl>
Cc: linux-kernel@vger.kernel.org, drzeus-mmc@drzeus.cx,
	linux-pm@lists.linux-foundation.org
Subject: Re: sdhci: Loads of scary messages during suspend/resume with SD card inserted
Date: Mon, 29 Sep 2008 12:38:57 +0100	[thread overview]
Message-ID: <20080929113857.GA17379@srcf.ucam.org> (raw)
In-Reply-To: <200809282146.57960.elendil@planet.nl>

On Sun, Sep 28, 2008 at 09:46:57PM +0200, Frans Pop wrote:
> Sep 28 23:12:39 aragorn kernel: ricoh-mmc: Suspending.
> Sep 28 23:12:39 aragorn kernel: ricoh-mmc: Controller is now re-enabled.
> Sep 28 23:12:39 aragorn kernel: mmc0: card 8879 removed

Eep! I'm sure that doesn't sound like a good idea. ricoh-mmc is 
suspending before sdhci is. In the process, it flips the hardware back 
into non-sdhci mode and the sdhci controller stops being able to talk to 
the card. I suspect that this upsets its own suspend routine rather a 
lot. Does this help at all? Not a complete fix, I suspect you'll still 
have issues on resume.

diff --git a/drivers/mmc/host/ricoh_mmc.c b/drivers/mmc/host/ricoh_mmc.c
index a16d760..015c248 100644
--- a/drivers/mmc/host/ricoh_mmc.c
+++ b/drivers/mmc/host/ricoh_mmc.c
@@ -191,20 +191,6 @@ static void __devexit ricoh_mmc_remove(struct pci_dev *pdev)
 	pci_set_drvdata(pdev, NULL);
 }
 
-static int ricoh_mmc_suspend(struct pci_dev *pdev, pm_message_t state)
-{
-	struct pci_dev *fw_dev = NULL;
-
-	fw_dev = pci_get_drvdata(pdev);
-	BUG_ON(fw_dev == NULL);
-
-	printk(KERN_INFO DRIVER_NAME ": Suspending.\n");
-
-	ricoh_mmc_enable(fw_dev);
-
-	return 0;
-}
-
 static int ricoh_mmc_resume(struct pci_dev *pdev)
 {
 	struct pci_dev *fw_dev = NULL;
@@ -224,7 +210,6 @@ static struct pci_driver ricoh_mmc_driver = {
 	.id_table =	pci_ids,
 	.probe = 	ricoh_mmc_probe,
 	.remove =	__devexit_p(ricoh_mmc_remove),
-	.suspend =	ricoh_mmc_suspend,
 	.resume =	ricoh_mmc_resume,
 };


-- 
Matthew Garrett | mjg59@srcf.ucam.org

  parent reply	other threads:[~2008-09-29 11:39 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-28 19:46 sdhci: Loads of scary messages during suspend/resume with SD card inserted Frans Pop
2008-09-28 20:04 ` Frans Pop
2008-09-28 22:42   ` Rafael J. Wysocki
2008-09-29 11:38 ` Matthew Garrett [this message]
2008-09-29 12:11   ` Matthew Garrett
2008-09-29 18:00     ` Frans Pop
2008-10-07 18:01       ` Alex Riesen
2008-11-14  1:41     ` Frans Pop

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=20080929113857.GA17379@srcf.ucam.org \
    --to=mjg59@srcf.ucam.org \
    --cc=drzeus-mmc@drzeus.cx \
    --cc=elendil@planet.nl \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.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