drivers/rtc/rtc-ds3232.c: make it possible to share an irq
authorBharat Bhushan <r65777@freescale.com>
Thu, 3 Apr 2014 21:50:04 +0000 (14:50 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 3 Apr 2014 23:21:21 +0000 (16:21 -0700)
It's possible to have RTC irq shared with other device (e.g.  t4240qds
board shares ds3232irq with phy one).  Handle this in driver.

Signed-off-by: Bharat Bhushan <Bharat.Bhushan@freescale.com>
Cc: Scott Wood <scottwood@freescale.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/rtc/rtc-ds3232.c

index 15497c578af57a0e496cae4c22b5e1f56517d570..813c6aa70d3d277131856478662492f3b4d99c6e 100644 (file)
@@ -418,8 +418,8 @@ static int ds3232_probe(struct i2c_client *client,
        }
 
        if (client->irq >= 0) {
-               ret = devm_request_irq(&client->dev, client->irq, ds3232_irq, 0,
-                                "ds3232", client);
+               ret = devm_request_irq(&client->dev, client->irq, ds3232_irq,
+                                      IRQF_SHARED, "ds3232", client);
                if (ret) {
                        dev_err(&client->dev, "unable to request IRQ\n");
                }