diff options
author | philipl@overt.org <philipl@overt.org> | 2009-01-18 14:11:20 -0500 |
---|---|---|
committer | Pierre Ossman <drzeus@drzeus.cx> | 2009-02-02 14:57:06 -0500 |
commit | 06cc1c880095063fa40b0a640ac0003b43107b40 (patch) | |
tree | 29872c44aeaa25ed9eb9b1fe2ffdc8f385713d34 /drivers/mmc | |
parent | cc30d60e4ca0b68e7e3f906eddd1e5b995d349f8 (diff) |
ricoh_mmc: Use suspend_late/resume_early
If ricoh_mmc suspends before sdhci_pci, it will pull the card
out from under the controller, which could leave the system in
a very confused state.
Using suspend_late/resume_early ensures that sdhci_pci suspends first
and resumes second.
Signed-off-by: Philip Langdale <philipl@overt.org>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
Diffstat (limited to 'drivers/mmc')
-rw-r--r-- | drivers/mmc/host/ricoh_mmc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/mmc/host/ricoh_mmc.c b/drivers/mmc/host/ricoh_mmc.c index be9e7b32b34e..f62790513322 100644 --- a/drivers/mmc/host/ricoh_mmc.c +++ b/drivers/mmc/host/ricoh_mmc.c | |||
@@ -196,7 +196,7 @@ static void __devexit ricoh_mmc_remove(struct pci_dev *pdev) | |||
196 | pci_set_drvdata(pdev, NULL); | 196 | pci_set_drvdata(pdev, NULL); |
197 | } | 197 | } |
198 | 198 | ||
199 | static int ricoh_mmc_suspend(struct pci_dev *pdev, pm_message_t state) | 199 | static int ricoh_mmc_suspend_late(struct pci_dev *pdev, pm_message_t state) |
200 | { | 200 | { |
201 | struct pci_dev *fw_dev = NULL; | 201 | struct pci_dev *fw_dev = NULL; |
202 | 202 | ||
@@ -210,7 +210,7 @@ static int ricoh_mmc_suspend(struct pci_dev *pdev, pm_message_t state) | |||
210 | return 0; | 210 | return 0; |
211 | } | 211 | } |
212 | 212 | ||
213 | static int ricoh_mmc_resume(struct pci_dev *pdev) | 213 | static int ricoh_mmc_resume_early(struct pci_dev *pdev) |
214 | { | 214 | { |
215 | struct pci_dev *fw_dev = NULL; | 215 | struct pci_dev *fw_dev = NULL; |
216 | 216 | ||
@@ -229,8 +229,8 @@ static struct pci_driver ricoh_mmc_driver = { | |||
229 | .id_table = pci_ids, | 229 | .id_table = pci_ids, |
230 | .probe = ricoh_mmc_probe, | 230 | .probe = ricoh_mmc_probe, |
231 | .remove = __devexit_p(ricoh_mmc_remove), | 231 | .remove = __devexit_p(ricoh_mmc_remove), |
232 | .suspend = ricoh_mmc_suspend, | 232 | .suspend_late = ricoh_mmc_suspend_late, |
233 | .resume = ricoh_mmc_resume, | 233 | .resume_early = ricoh_mmc_resume_early, |
234 | }; | 234 | }; |
235 | 235 | ||
236 | /*****************************************************************************\ | 236 | /*****************************************************************************\ |