summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xdrivers/mfd/ab5500-core.c16
-rw-r--r--drivers/mfd/db8500-prcmu.c13
-rw-r--r--include/linux/mfd/db8500-prcmu.h3
3 files changed, 23 insertions, 9 deletions
diff --git a/drivers/mfd/ab5500-core.c b/drivers/mfd/ab5500-core.c
index b50da3c5a76..75c773b232f 100755
--- a/drivers/mfd/ab5500-core.c
+++ b/drivers/mfd/ab5500-core.c
@@ -28,7 +28,7 @@
#include <linux/spinlock.h>
#include <linux/mfd/core.h>
#include <linux/version.h>
-#include <mach/prcmu-db5500.h>
+#include <linux/mfd/db5500-prcmu.h>
#define AB5500_NAME_STRING "ab5500"
#define AB5500_ID_FORMAT_STRING "AB5500 %s"
@@ -1332,7 +1332,7 @@ static int ab5500_startup_irq_enabled(struct device *dev, unsigned int irq)
struct ab5500 *ab;
bool val;
- ab = get_irq_chip_data(irq);
+ ab = irq_get_chip_data(irq);
irq -= ab->irq_base;
val = ((ab->startup_events[irq / 8] & BIT(irq % 8)) != 0);
@@ -2303,10 +2303,10 @@ static int ab5500_irq_init(struct ab5500 *ab)
for (i = 0; i < ab5500_plf_data->irq.count; i++) {
irq = ab5500_plf_data->irq.base + i;
- set_irq_chip_data(irq, ab);
- set_irq_chip_and_handler(irq, &ab5500_irq_chip,
+ irq_set_chip_data(irq, ab);
+ irq_set_chip_and_handler(irq, &ab5500_irq_chip,
handle_simple_irq);
- set_irq_nested_thread(irq, 1);
+ irq_set_nested_thread(irq, 1);
#ifdef CONFIG_ARM
set_irq_flags(irq, IRQF_VALID);
#else
@@ -2328,8 +2328,8 @@ static void ab5500_irq_remove(struct ab5500 *ab)
#ifdef CONFIG_ARM
set_irq_flags(irq, 0);
#endif
- set_irq_chip_and_handler(irq, NULL, NULL);
- set_irq_chip_data(irq, NULL);
+ irq_set_chip_and_handler(irq, NULL, NULL);
+ irq_set_chip_data(irq, NULL);
}
}
@@ -2428,7 +2428,7 @@ static int __init ab5500_probe(struct platform_device *pdev)
/* Set up and register the platform devices. */
for (i = 0; i < AB5500_NUM_DEVICES; i++) {
- ab5500_devs[i].mfd_data = ab5500_plf_data->dev_data[i];
+ ab5500_devs[i].platform_data = ab5500_plf_data->dev_data[i];
}
err = mfd_add_devices(&pdev->dev, 0, ab5500_devs,
diff --git a/drivers/mfd/db8500-prcmu.c b/drivers/mfd/db8500-prcmu.c
index 02a15d7cb3b..57939be17ed 100644
--- a/drivers/mfd/db8500-prcmu.c
+++ b/drivers/mfd/db8500-prcmu.c
@@ -1514,7 +1514,7 @@ bool prcmu_is_ac_wake_requested(void)
/**
* prcmu_system_reset - System reset
*
- * Saves the reset reason code and then sets the APE_SOFRST register which
+ * Saves the reset reason code and then sets the APE_SOFTRST register which
* fires interrupt to fw
*/
void prcmu_system_reset(u16 reset_code)
@@ -1524,6 +1524,17 @@ void prcmu_system_reset(u16 reset_code)
}
/**
+ * prcmu_get_reset_code - Retrieve SW reset reason code
+ *
+ * Retrieves the reset reason code stored by prcmu_system_reset() before
+ * last restart.
+ */
+u16 prcmu_get_reset_code(void)
+{
+ return readw(tcdm_base + PRCM_SW_RST_REASON);
+}
+
+/**
* prcmu_reset_modem - ask the PRCMU to reset modem
*/
void prcmu_modem_reset(void)
diff --git a/include/linux/mfd/db8500-prcmu.h b/include/linux/mfd/db8500-prcmu.h
index 917dbcab701..f56d1171269 100644
--- a/include/linux/mfd/db8500-prcmu.h
+++ b/include/linux/mfd/db8500-prcmu.h
@@ -668,6 +668,9 @@ enum prcmu_clock {
PRCMU_NUM_REG_CLOCKS,
PRCMU_SYSCLK = PRCMU_NUM_REG_CLOCKS,
PRCMU_TIMCLK,
+ PRCMU_PLLSOC0,
+ PRCMU_PLLSOC1,
+ PRCMU_PLLDDR,
};
/*