aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/rtc/rtc-rs5c372.c
diff options
context:
space:
mode:
authorLucas Stach <l.stach@pengutronix.de>2013-05-07 19:18:11 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2013-05-07 21:38:26 -0400
commit550fcb8f7cab665ced9386bcf6b5a02df65318b6 (patch)
treec39c732bed9e9c77e88e434d3fb9a966e168a527 /drivers/rtc/rtc-rs5c372.c
parent0f157a5b58d0d2890f0ae20da9fe66aa19a91a4d (diff)
drivers/rtc/rtc-rs5c372.c: add R2221T/L variant to the driver
Register layout is the same, so just add the variant to the appropriate places. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/rtc/rtc-rs5c372.c')
-rw-r--r--drivers/rtc/rtc-rs5c372.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/rtc/rtc-rs5c372.c b/drivers/rtc/rtc-rs5c372.c
index 224d634322b4..ccf54f06396b 100644
--- a/drivers/rtc/rtc-rs5c372.c
+++ b/drivers/rtc/rtc-rs5c372.c
@@ -68,6 +68,7 @@
68enum rtc_type { 68enum rtc_type {
69 rtc_undef = 0, 69 rtc_undef = 0,
70 rtc_r2025sd, 70 rtc_r2025sd,
71 rtc_r2221tl,
71 rtc_rs5c372a, 72 rtc_rs5c372a,
72 rtc_rs5c372b, 73 rtc_rs5c372b,
73 rtc_rv5c386, 74 rtc_rv5c386,
@@ -76,6 +77,7 @@ enum rtc_type {
76 77
77static const struct i2c_device_id rs5c372_id[] = { 78static const struct i2c_device_id rs5c372_id[] = {
78 { "r2025sd", rtc_r2025sd }, 79 { "r2025sd", rtc_r2025sd },
80 { "r2221tl", rtc_r2221tl },
79 { "rs5c372a", rtc_rs5c372a }, 81 { "rs5c372a", rtc_rs5c372a },
80 { "rs5c372b", rtc_rs5c372b }, 82 { "rs5c372b", rtc_rs5c372b },
81 { "rv5c386", rtc_rv5c386 }, 83 { "rv5c386", rtc_rv5c386 },
@@ -529,6 +531,7 @@ static int rs5c_oscillator_setup(struct rs5c372 *rs5c372)
529 rs5c372->time24 = 1; 531 rs5c372->time24 = 1;
530 break; 532 break;
531 case rtc_r2025sd: 533 case rtc_r2025sd:
534 case rtc_r2221tl:
532 case rtc_rv5c386: 535 case rtc_rv5c386:
533 case rtc_rv5c387a: 536 case rtc_rv5c387a:
534 buf[0] |= RV5C387_CTRL1_24; 537 buf[0] |= RV5C387_CTRL1_24;
@@ -609,6 +612,7 @@ static int rs5c372_probe(struct i2c_client *client,
609 rs5c372->time24 = 1; 612 rs5c372->time24 = 1;
610 break; 613 break;
611 case rtc_r2025sd: 614 case rtc_r2025sd:
615 case rtc_r2221tl:
612 case rtc_rv5c386: 616 case rtc_rv5c386:
613 case rtc_rv5c387a: 617 case rtc_rv5c387a:
614 if (rs5c372->regs[RS5C_REG_CTRL1] & RV5C387_CTRL1_24) 618 if (rs5c372->regs[RS5C_REG_CTRL1] & RV5C387_CTRL1_24)
@@ -640,6 +644,7 @@ static int rs5c372_probe(struct i2c_client *client,
640 dev_info(&client->dev, "%s found, %s, driver version " DRV_VERSION "\n", 644 dev_info(&client->dev, "%s found, %s, driver version " DRV_VERSION "\n",
641 ({ char *s; switch (rs5c372->type) { 645 ({ char *s; switch (rs5c372->type) {
642 case rtc_r2025sd: s = "r2025sd"; break; 646 case rtc_r2025sd: s = "r2025sd"; break;
647 case rtc_r2221tl: s = "r2221tl"; break;
643 case rtc_rs5c372a: s = "rs5c372a"; break; 648 case rtc_rs5c372a: s = "rs5c372a"; break;
644 case rtc_rs5c372b: s = "rs5c372b"; break; 649 case rtc_rs5c372b: s = "rs5c372b"; break;
645 case rtc_rv5c386: s = "rv5c386"; break; 650 case rtc_rv5c386: s = "rv5c386"; break;