rtc: rtc-ds1307: enable support for mcp794xx as a wakeup source without IRQ
PATCH 1/1 rtc: rtc-ds1307: enable support for mcp794xx as a wakeup source without IRQ
This patch extends the fixes for ds1337, ds1339, ds3231 in 8bc2a40730ec to mcp794xx devices, so that those parts can similarly be used as a wakeup source without an IRQ to the processor.
Tested on Raspberry Pi ZeroW with MCP79400.
---
drivers/rtc/rtc-ds1307.c +2 -1
@@ -1487,7 +1487,8 @@ static int ds1307_probe(struct i2c_clienbreak ;case mcp794xx: rtc_ops = &mcp794xx_rtc_ops; -if (ds1307->client->irq >0 && chip->alarm) { + if (chip->alarm && (ds1307->client->irq > 0 || +
ds1307_can_wakeup_device)) { irq_handler = mcp794xx_irq;
want_irq = true;
}
Signature · 8 lines
You received this message because you are subscribed to "rtc-linux". Membership options at http://groups.google.com/group/rtc-linux . Please read http://groups.google.com/group/rtc-linux/web/checklist before submitting a driver. --- You received this message because you are subscribed to the Google Groups "rtc-linux" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
Hi,
Quoted 11 lines · David Lowe
This patch extends the fixes for ds1337, ds1339, ds3231 in
8bc2a40730ecto mcp794xx devices, so that those parts can similarly be used as a wakeup source without an IRQ to the processor.Tested on Raspberry Pi ZeroW with MCP79400.
Signed-off-by David Lowe <[email protected]>---
drivers/rtc/rtc-ds1307.c static int ds1307_probe(struct i2c_clien · line 1492
Quoted 7 lines
drivers/rtc/rtc-ds1307.c +2
-1@@ -1487,7 +1487,8 @@ static int ds1307_probe(struct i2c_clienbreak ;case mcp794xx: rtc_ops = &mcp794xx_rtc_ops; -if (ds1307->client->irq >0 && chip->alarm) { +if (chip->alarm && (ds1307->client->irq >0 || + ds1307_can_wakeup_device)) { irq_handler = mcp794xx_irq;
This seems right but your mailer as mangled the patch. Can you resend?
Quoted 2 lines
drivers/rtc/rtc-ds1307.c +0
-0want_irq = true; }
Signature · 13 lines
Alexandre Belloni, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com -- You received this message because you are subscribed to "rtc-linux". Membership options at http://groups.google.com/group/rtc-linux . Please read http://groups.google.com/group/rtc-linux/web/checklist before submitting a driver. --- You received this message because you are subscribed to the Google Groups "rtc-linux" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.