Patchwork [v2,2/5] rtc: s5m: Fix unsuccesful IRQ request during probe

login
register
mail settings
Submitter Krzysztof Kozlowski
Date Nov. 28, 2013, 8:09 a.m.
Message ID <1385626183-22990-3-git-send-email-k.kozlowski@samsung.com>
Download mbox | patch
Permalink /patch/294798/
State New
Headers show

Comments

Krzysztof Kozlowski - Nov. 28, 2013, 8:09 a.m.
Probe failed for rtc-s5m:
	s5m-rtc s5m-rtc: Failed to request alarm IRQ: 12: -22
	s5m-rtc: probe of s5m-rtc failed with error -22

Fix rtc-s5m interrupt request by using regmap_irq_get_virq() for mapping
the IRQ.

Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
 drivers/rtc/rtc-s5m.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
Mark Brown - Nov. 28, 2013, 1:46 p.m.
On Thu, Nov 28, 2013 at 09:09:40AM +0100, Krzysztof Kozlowski wrote:
> Probe failed for rtc-s5m:
> 	s5m-rtc s5m-rtc: Failed to request alarm IRQ: 12: -22
> 	s5m-rtc: probe of s5m-rtc failed with error -22
> 
> Fix rtc-s5m interrupt request by using regmap_irq_get_virq() for mapping
> the IRQ.

Reviwed-by: Mark Brown <broonie@linaro.org>

Presumably should CC stable.
Sangbeom Kim - Nov. 29, 2013, 12:10 a.m.
On Thursday, November 28, 2013 10:47 PM, Mark Brown wrote:
> > Fix rtc-s5m interrupt request by using regmap_irq_get_virq() for mapping
> > the IRQ.
> 
> Reviwed-by: Mark Brown <broonie@linaro.org>

Acked-by: Sangbeom Kim <sbkim73@samsung.com>

Thanks,
Sangbeom.

Patch

diff --git a/drivers/rtc/rtc-s5m.c b/drivers/rtc/rtc-s5m.c
index 088cf3a..66686d9 100644
--- a/drivers/rtc/rtc-s5m.c
+++ b/drivers/rtc/rtc-s5m.c
@@ -548,11 +548,13 @@  static int s5m_rtc_probe(struct platform_device *pdev)
 
 	switch (pdata->device_type) {
 	case S5M8763X:
-		info->irq = s5m87xx->irq_base + S5M8763_IRQ_ALARM0;
+		info->irq = regmap_irq_get_virq(s5m87xx->irq_data,
+				S5M8763_IRQ_ALARM0);
 		break;
 
 	case S5M8767X:
-		info->irq = s5m87xx->irq_base + S5M8767_IRQ_RTCA1;
+		info->irq = regmap_irq_get_virq(s5m87xx->irq_data,
+				S5M8767_IRQ_RTCA1);
 		break;
 
 	default: