Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions drivers/rtc/rtc-s5m.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#include <linux/platform_device.h>
#include <linux/mfd/samsung/core.h>
#include <linux/mfd/samsung/rtc.h>
#include <linux/mfd/samsung/s2mpg10.h>
#include <linux/mfd/samsung/s2mpg12.h>
#include <linux/mfd/samsung/s2mps14.h>

Expand Down Expand Up @@ -260,6 +261,12 @@ static int s5m_check_pending_alarm_interrupt(struct s5m_rtc_info *info,
val &= S2MPG12_STATUS2_RTCA0E;
break;
case S2MPG10:
ret = regmap_read(info->s5m87xx->regmap_pmic, S2MPG10_PMIC_STATUS2,
&val);
if (ret < 0)
return ret;
val &= S2MPG10_STATUS2_RTCA0E;
break;
case S2MPS15X:
case S2MPS14X:
case S2MPS13X:
Expand Down
3 changes: 3 additions & 0 deletions include/linux/mfd/samsung/s2mpg10.h
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,9 @@ enum s2mpg10_pmic_reg {
S2MPG10_PMIC_LDO_SENSE4,
};

/* Alarm0 pending flag in S2MPG10_PMIC_STATUS2. */
#define S2MPG10_STATUS2_RTCA0E BIT(2)

/* Rail controlled externally, based on PCTRLSELx */
#define S2MPG10_PMIC_CTRL_ENABLE_EXT BIT(0)

Expand Down