All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] sdhci: wakeup from runtime PM
@ 2016-03-25 16:05 ` Ludovic Desroches
  0 siblings, 0 replies; 25+ messages in thread
From: Ludovic Desroches @ 2016-03-25 16:05 UTC (permalink / raw)
  To: ulf.hansson, adrian.hunter
  Cc: linux-kernel, linux-mmc, linux-pm, nicolas.ferre, Ludovic Desroches

Hi,

When not using the SDHCI controller, it is logical to save power by suspending
it. The issue is that SDHCI assumes that the controller is completely disabled.
It means the only way to wake up on a card event is to have a gpio for the card
detection (so two pins for the same signal). A possible workaround is to use
polling but the controller will be resumed/suspended between each attempts.

We have already discussed a long time about this and it seems we don't agree.
In my opinion, even if I can't disable all clocks, I should use runtime PM 
to save some power.

I propose two patches, one which is a draft to try to solve it at sdhci level
and one at sdhci-of-at91 level.

Concerning the first one, I don't understand why we need to reject irqs if
runtime_suspended is true. Only SDHCI_INT_CARD_INT irq is enabled so why we
should have other IRQs than this one?

Since you were not in favour of allowing to wakeup on SDHCI_INT_CARD_INSERT or
SDHCI_INT_CARD_REMOVE, I assume you won't take it so I
solved my issue only by modifying my driver.

I have not noticed side effects. I have compared a wakeup with a gpio for card
detection and the controller card detect. It seems the two paths are rougly
the same (mmc_detect_change -> mmc_rescan then resume is performed).

Regards

Ludovic

^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2016-04-11 12:09 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-25 16:05 [PATCH] sdhci: wakeup from runtime PM Ludovic Desroches
2016-03-25 16:05 ` Ludovic Desroches
2016-03-25 16:05 ` [PATCH] DRAFT: shdci: allows custom wakeup irqs for " Ludovic Desroches
2016-03-25 16:05   ` Ludovic Desroches
2016-03-25 16:46   ` kbuild test robot
2016-03-25 16:46     ` kbuild test robot
2016-03-25 16:50   ` kbuild test robot
2016-03-25 16:50     ` kbuild test robot
2016-03-25 17:12   ` kbuild test robot
2016-03-25 17:12     ` kbuild test robot
2016-03-25 17:27   ` kbuild test robot
2016-03-25 17:27     ` kbuild test robot
2016-03-25 16:05 ` [PATCH] mmc: sdhci-of-at91: allow the use of controller card detect as wake up Ludovic Desroches
2016-03-25 16:05   ` Ludovic Desroches
2016-03-25 17:11   ` [PATCH] mmc: sdhci-of-at91: fix semicolon.cocci warnings kbuild test robot
2016-03-25 17:11     ` kbuild test robot
2016-03-25 17:11   ` [PATCH] mmc: sdhci-of-at91: allow the use of controller card detect as wake up kbuild test robot
2016-03-25 17:11     ` kbuild test robot
2016-04-05 12:40 ` [PATCH] sdhci: wakeup from runtime PM Adrian Hunter
2016-04-07  9:11   ` Ulf Hansson
2016-04-07 15:12     ` Ludovic Desroches
2016-04-08  8:35       ` Ulf Hansson
2016-04-08 15:19         ` Alan Stern
2016-04-08 20:51           ` Ulf Hansson
2016-04-11 12:09         ` Ludovic Desroches

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.