summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJoseph Chen <chenjh@rock-chips.com>2018-04-16 17:39:09 +0800
committerTao Huang <huangtao@rock-chips.com>2018-04-17 11:36:29 +0800
commitf36de44fad54dae4de11f23604467e15d5b6a198 (patch)
treef829cb6c435d85dca8052378357ae425419c2b96 /include
parentefae8c5e28b8bf2c544da76882eabcba1be4aa4c (diff)
mfd: rk808: set fall event higher priority than rise event
When PMIC irq occurs, regmap-irq.c will traverse all PMIC child interrupts from low index 0 to high index, we give fall interrupt high priority to be called earlier than rise, so that it can be override by late rise event. This can helps to solve key release glitch which make a wrongly fall event immediately after rise. Change-Id: Ieda1d6fd3c50cc36742a4740504ec7ce12ea509b Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/mfd/rk808.h12
1 files changed, 10 insertions, 2 deletions
diff --git a/include/linux/mfd/rk808.h b/include/linux/mfd/rk808.h
index ad9e1558fba0..28569148b23f 100644
--- a/include/linux/mfd/rk808.h
+++ b/include/linux/mfd/rk808.h
@@ -472,14 +472,22 @@ enum rk805_reg {
#define DISCHG_ILIM_ENABLE BIT(7)
/* IRQ Definitions */
-#define RK805_IRQ_PWRON_RISE 0
#define RK805_IRQ_VB_LOW 1
#define RK805_IRQ_PWRON 2
#define RK805_IRQ_PWRON_LP 3
#define RK805_IRQ_HOTDIE 4
#define RK805_IRQ_RTC_ALARM 5
#define RK805_IRQ_RTC_PERIOD 6
-#define RK805_IRQ_PWRON_FALL 7
+
+/*
+ * When PMIC irq occurs, regmap-irq.c will traverse all PMIC child
+ * interrupts from low index 0 to high index, we give fall interrupt
+ * high priority to be called earlier than rise, so that it can be
+ * override by late rise event. This can helps to solve key release
+ * glitch which make a wrongly fall event immediately after rise.
+ */
+#define RK805_IRQ_PWRON_FALL 0
+#define RK805_IRQ_PWRON_RISE 7
#define RK805_IRQ_PWRON_RISE_MSK BIT(0)
#define RK805_IRQ_VB_LOW_MSK BIT(1)