Skip to contentSkip to conversation

mmc: sdhci-s3c: pass IRQF ONESHOT to request threaded irq

PATCH In review Heiko Stübner 2 participants 2 messages Jun 3, 2012 – Jun 4, 2012

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mmc: sdhci-s3c: pass IRQF ONESHOT to request threaded irq

Fix a boot regression in existing kernels causing:

genirq: Threaded irq requested with handler=NULL and !ONESHOT for irq XXX

caused by 1c6c6952 (genirq: Reject bogus threaded irq requests).

---
Witnessed on a s3c2416 with 3.5-rc1

 drivers/mmc/host/sdhci-s3c.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/mmc/host/sdhci-s3c.c +1 -1
index f473d8b..460ddb5 100644
@@ -408,7 +408,7 @@ static void sdhci_s3c_setup_card_detect_gpio(struct sdhci_s3c *sc)
 		if (sc->ext_cd_irq &&
 		    request_threaded_irq(sc->ext_cd_irq, NULL,
 					 sdhci_s3c_gpio_card_detect_thread,
-					 IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING,
+					 IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING | IRQF_ONESHOT,
 					 dev_name(dev), sc) == 0) {
 			int status = gpio_get_value(sc->ext_cd_gpio);
 			if (pdata->ext_cd_gpio_invert)
Signature · 1 line
1.7.2.3
#1 lore raw

drivers/mmc/host/sdhci-s3c.c static void sdhci_s3c_setup_card_detect_gpio(struct sdhci_s3c *sc) · line 413

Quoted 6 lines · Heiko St??bner
drivers/mmc/host/sdhci-s3c.c +1 -1
 		    request_threaded_irq(sc->ext_cd_irq, NULL,
 					 sdhci_s3c_gpio_card_detect_thread,
-					 IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING,
+					 IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING | IRQF_ONESHOT,
 					 dev_name(dev), sc) == 0) {
 			int status = gpio_get_value(sc->ext_cd_gpio);

Separate issue but shouldn't this be request_any_context_irq()? Most GPIOs work just fine in atomic context, though I don't know if the MMC core limits things.