From: Axel Lin Date: Sat, 13 Aug 2011 11:15:01 +0000 (+0800) Subject: ASoC: soc-jack: Fix checking return value of request_any_context_irq X-Git-Tag: upstream/snapshot3+hdmi~8996^2~40 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d2b4c7bd7eabfaa2e3e5b8107d5eeb56ac879813;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git ASoC: soc-jack: Fix checking return value of request_any_context_irq request_any_context_irq() returns a negative value on failure. On success, it returns either IRQC_IS_HARDIRQ or IRQC_IS_NESTED. Signed-off-by: Axel Lin Signed-off-by: Mark Brown Cc: stable@kernel.orG --- diff --git a/sound/soc/soc-jack.c b/sound/soc/soc-jack.c index 7c17b98..38b0013 100644 --- a/sound/soc/soc-jack.c +++ b/sound/soc/soc-jack.c @@ -327,7 +327,7 @@ int snd_soc_jack_add_gpios(struct snd_soc_jack *jack, int count, IRQF_TRIGGER_FALLING, gpios[i].name, &gpios[i]); - if (ret) + if (ret < 0) goto err; if (gpios[i].wake) {