summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRajagopala V <rajagopala.v@stericsson.com>2011-12-14 15:36:15 +0530
committerPhilippe Langlais <philippe.langlais@stericsson.com>2012-05-22 10:59:24 +0200
commitd7285f989c8182e01922bed16683e36beec767bd (patch)
tree7e9c53d8a16dd2095b4d46c68b23c8c23d98fb8e /include
parentdb39c4b3e55e394aff1accaf4f4a632e6bc9ff22 (diff)
mfd: db5500-prcmu: Mbox4 support for watchdog
PRCMU driver interface for A9 watchdog management. - mbox4 for enabling and disabling wdog - interface for loading ang kicking wdog ST-Ericsson ID: 316540 ST-Ericsson FOSS-OUT ID: Trivial ST-Ericsson Linux next: NA Change-Id: Iea6d0887dd0432d5c2d20ef0ca15f3d534609fd3 Signed-off-by: Rajagopala V <rajagopala.v@stericsson.com> Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/42490 Reviewed-by: Rabin VINCENT <rabin.vincent@stericsson.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/mfd/db5500-prcmu.h32
-rw-r--r--include/linux/mfd/dbx500-prcmu.h10
2 files changed, 37 insertions, 5 deletions
diff --git a/include/linux/mfd/db5500-prcmu.h b/include/linux/mfd/db5500-prcmu.h
index cf97d25a913..681c8f99bf1 100644
--- a/include/linux/mfd/db5500-prcmu.h
+++ b/include/linux/mfd/db5500-prcmu.h
@@ -65,6 +65,13 @@ int db5500_prcmu_config_hotdog(u8 threshold);
int db5500_prcmu_config_hotmon(u8 low, u8 high);
int db5500_prcmu_start_temp_sense(u16 cycles32k);
int db5500_prcmu_stop_temp_sense(void);
+
+int db5500_prcmu_config_a9wdog(u8 num, bool sleep_auto_off);
+int db5500_prcmu_enable_a9wdog(u8 id);
+int db5500_prcmu_disable_a9wdog(u8 id);
+int db5500_prcmu_kick_a9wdog(u8 id);
+int db5500_prcmu_load_a9wdog(u8 id, u32 timeout);
+
#else /* !CONFIG_UX500_SOC_DB5500 */
static inline void db5500_prcmu_early_init(void) {}
@@ -227,6 +234,31 @@ static inline int db5500_prcmu_stop_temp_sense(void)
return 0;
}
+static inline int db5500_prcmu_config_a9wdog(u8 num, bool sleep_auto_off)
+{
+ return 0;
+}
+
+static inline int db5500_prcmu_enable_a9wdog(u8 id)
+{
+ return 0;
+}
+
+static inline int db5500_prcmu_disable_a9wdog(u8 id)
+{
+ return 0;
+}
+
+static inline int db5500_prcmu_kick_a9wdog(u8 id)
+{
+ return 0;
+}
+
+static inline int db5500_prcmu_load_a9wdog(u8 id, u32 timeout)
+{
+ return 0;
+}
+
#endif /* CONFIG_MFD_DB5500_PRCMU */
#endif /* __MFD_DB5500_PRCMU_H */
diff --git a/include/linux/mfd/dbx500-prcmu.h b/include/linux/mfd/dbx500-prcmu.h
index 45a0ae0cc39..eb9cee31407 100644
--- a/include/linux/mfd/dbx500-prcmu.h
+++ b/include/linux/mfd/dbx500-prcmu.h
@@ -556,7 +556,7 @@ static inline void prcmu_write_masked(unsigned int reg, u32 mask, u32 value)
static inline int prcmu_enable_a9wdog(u8 id)
{
if (cpu_is_u5500())
- return -EINVAL;
+ return db5500_prcmu_enable_a9wdog(id);
else
return db8500_prcmu_enable_a9wdog(id);
}
@@ -564,7 +564,7 @@ static inline int prcmu_enable_a9wdog(u8 id)
static inline int prcmu_disable_a9wdog(u8 id)
{
if (cpu_is_u5500())
- return -EINVAL;
+ return db5500_prcmu_disable_a9wdog(id);
else
return db8500_prcmu_disable_a9wdog(id);
}
@@ -572,7 +572,7 @@ static inline int prcmu_disable_a9wdog(u8 id)
static inline int prcmu_kick_a9wdog(u8 id)
{
if (cpu_is_u5500())
- return -EINVAL;
+ return db5500_prcmu_kick_a9wdog(id);
else
return db8500_prcmu_kick_a9wdog(id);
}
@@ -580,7 +580,7 @@ static inline int prcmu_kick_a9wdog(u8 id)
static inline int prcmu_load_a9wdog(u8 id, u32 timeout)
{
if (cpu_is_u5500())
- return -EINVAL;
+ return db5500_prcmu_load_a9wdog(id, timeout);
else
return db8500_prcmu_load_a9wdog(id, timeout);
}
@@ -588,7 +588,7 @@ static inline int prcmu_load_a9wdog(u8 id, u32 timeout)
static inline int prcmu_config_a9wdog(u8 num, bool sleep_auto_off)
{
if (cpu_is_u5500())
- return -EINVAL;
+ return db5500_prcmu_config_a9wdog(num, sleep_auto_off);
else
return db8500_prcmu_config_a9wdog(num, sleep_auto_off);
}