summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com>2011-09-20 10:40:09 +0200
committerRobert Marklund <robert.marklund@stericsson.com>2011-10-05 13:00:26 +0200
commit04f95db6652f5f969441c509730547d804ae9b13 (patch)
tree1badda58386e8d0c37aaf7da814f2c7a3f7a33f9 /include
parent14164bd172c178c3e37d53d2fa7c4d7671f13e45 (diff)
regulator: restore ab8500 and db8500 regulators to linux-next state
State is restored to the following patch in linux-next tree: commit 4b8f00480cecabdffd80d7a7bf79a99508422666 Author: Linus Walleij <linus.walleij@linaro.org> Date: Mon Aug 29 14:49:49 2011 +0200 Merge branch 'mfd-prcmu' into next Change-Id: I603d50f61f99ccec89c1f6e32f7d95e6c925cb87 Signed-off-by: Mian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com> Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/32091 Reviewed-by: Jonas ABERG <jonas.aberg@stericsson.com> Tested-by: Jonas ABERG <jonas.aberg@stericsson.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/regulator/ab8500-debug.h21
-rw-r--r--include/linux/regulator/ab8500.h26
-rw-r--r--include/linux/regulator/db8500-prcmu.h8
-rw-r--r--include/linux/regulator/dbx500-prcmu.h96
4 files changed, 12 insertions, 139 deletions
diff --git a/include/linux/regulator/ab8500-debug.h b/include/linux/regulator/ab8500-debug.h
deleted file mode 100644
index 01655fc7fc1..00000000000
--- a/include/linux/regulator/ab8500-debug.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright (C) ST-Ericsson SA 2010
- *
- * License Terms: GNU General Public License v2
- *
- * Authors: Bengt Jonsson <bengt.g.jonsson@stericsson.com> for ST-Ericsson
- */
-
-#ifndef __LINUX_MFD_AB8500_REGULATOR_DEBUG_H
-#define __LINUX_MFD_AB8500_REGULATOR_DEBUG_H
-
-#ifdef CONFIG_REGULATOR_AB8500_DEBUG
-/* AB8500 debug force/restore functions */
-void ab8500_regulator_debug_force(void);
-void ab8500_regulator_debug_restore(void);
-#else
-static inline void ab8500_regulator_debug_force(void) {}
-static inline void ab8500_regulator_debug_restore(void) {}
-#endif
-
-#endif
diff --git a/include/linux/regulator/ab8500.h b/include/linux/regulator/ab8500.h
index 09ddc33ae61..76579f964a2 100644
--- a/include/linux/regulator/ab8500.h
+++ b/include/linux/regulator/ab8500.h
@@ -17,33 +17,29 @@ enum ab8500_regulator_id {
AB8500_LDO_AUX3,
AB8500_LDO_INTCORE,
AB8500_LDO_TVOUT,
+ AB8500_LDO_USB,
AB8500_LDO_AUDIO,
AB8500_LDO_ANAMIC1,
AB8500_LDO_ANAMIC2,
AB8500_LDO_DMIC,
AB8500_LDO_ANA,
- AB8500_SYSCLKREQ_2,
- AB8500_SYSCLKREQ_4,
AB8500_NUM_REGULATORS,
};
/* AB8500 register initialization */
struct ab8500_regulator_reg_init {
int id;
- u8 mask;
u8 value;
};
-#define INIT_REGULATOR_REGISTER(_id, _mask, _value) \
- { \
- .id = _id, \
- .mask = _mask, \
- .value = _value, \
+#define INIT_REGULATOR_REGISTER(_id, _value) \
+ { \
+ .id = _id, \
+ .value = _value, \
}
/* AB8500 registers */
enum ab8500_regulator_reg {
- AB8500_REGUREQUESTCTRL1,
AB8500_REGUREQUESTCTRL2,
AB8500_REGUREQUESTCTRL3,
AB8500_REGUREQUESTCTRL4,
@@ -60,28 +56,18 @@ enum ab8500_regulator_reg {
AB8500_REGUMISC1,
AB8500_VAUDIOSUPPLY,
AB8500_REGUCTRL1VAMIC,
- AB8500_VSMPS1REGU,
- AB8500_VSMPS2REGU,
- AB8500_VSMPS3REGU, /* NOTE! PRCMU register */
AB8500_VPLLVANAREGU,
AB8500_VREFDDR,
AB8500_EXTSUPPLYREGU,
AB8500_VAUX12REGU,
AB8500_VRF1VAUX3REGU,
- AB8500_VSMPS1SEL1,
- AB8500_VSMPS1SEL2,
- AB8500_VSMPS1SEL3,
- AB8500_VSMPS2SEL1,
- AB8500_VSMPS2SEL2,
- AB8500_VSMPS2SEL3,
- AB8500_VSMPS3SEL1, /* NOTE! PRCMU register */
- AB8500_VSMPS3SEL2, /* NOTE! PRCMU register */
AB8500_VAUX1SEL,
AB8500_VAUX2SEL,
AB8500_VRF1VAUX3SEL,
AB8500_REGUCTRL2SPARE,
AB8500_REGUCTRLDISCH,
AB8500_REGUCTRLDISCH2,
+ AB8500_VSMPS1SEL1,
AB8500_NUM_REGULATOR_REGISTERS,
};
diff --git a/include/linux/regulator/db8500-prcmu.h b/include/linux/regulator/db8500-prcmu.h
index a3138ea2177..612062313b6 100644
--- a/include/linux/regulator/db8500-prcmu.h
+++ b/include/linux/regulator/db8500-prcmu.h
@@ -11,8 +11,6 @@
#ifndef __REGULATOR_H__
#define __REGULATOR_H__
-#include <linux/regulator/dbx500-prcmu.h>
-
/* Number of DB8500 regulators and regulator enumeration */
enum db8500_regulator_id {
DB8500_REGULATOR_VAPE,
@@ -38,4 +36,10 @@ enum db8500_regulator_id {
DB8500_NUM_REGULATORS
};
+/*
+ * Exported interface for CPUIdle only. This function is called with all
+ * interrupts turned off.
+ */
+int power_state_active_is_enabled(void);
+
#endif
diff --git a/include/linux/regulator/dbx500-prcmu.h b/include/linux/regulator/dbx500-prcmu.h
deleted file mode 100644
index a18cf6c4107..00000000000
--- a/include/linux/regulator/dbx500-prcmu.h
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * Copyright (C) ST-Ericsson SA 2010
- *
- * Author: Bengt Jonsson <bengt.jonsson@stericsson.com> for ST-Ericsson,
- * Jonas Aaberg <jonas.aberg@stericsson.com> for ST-Ericsson
- *
- * License Terms: GNU General Public License v2
- *
- */
-
-#ifndef DBX500_REGULATOR_H
-#define DBX500_REGULATOR_H
-
-#include <linux/device.h>
-
-struct ux500_regulator;
-
-#ifdef CONFIG_REGULATOR
-/*
- * NOTE! The device will be connected to the correct regulator by this
- * new framework. A list with connections will match up dev_name(dev)
- * to the specific regulator. This follows the same principle as the
- * normal regulator framework.
- *
- * This framework shall only be used in special cases when a regulator
- * has to be enabled/disabled in atomic context.
- */
-
-void power_state_active_enable(void);
-int power_state_active_disable(void);
-/*
- * Exported interface for CPUIdle only. This function is called with all
- * interrupts turned off.
- */
-int power_state_active_is_enabled(void);
-
-/**
- * ux500_regulator_get()
- *
- * @dev: Drivers device struct
- *
- * Returns a ux500_regulator struct. Shall be used as argument for
- * ux500_regulator_atomic_enable/disable calls.
- * Return ERR_PTR(-EINVAL) upon no matching regulator found.
- */
-struct ux500_regulator *__must_check ux500_regulator_get(struct device *dev);
-
-/**
- * ux500_regulator_atomic_enable()
- *
- * @regulator: Regulator handle, provided from ux500_regulator_get.
- *
- * The enable/disable functions keep an internal counter, so every
- * enable must be paired with an disable in order to turn off regulator.
- */
-int ux500_regulator_atomic_enable(struct ux500_regulator *regulator);
-
-/**
- * ux500_regulator_atomic_disable()
- *
- * @regulator: Regulator handle, provided from ux500_regulator_get.
- *
- */
-int ux500_regulator_atomic_disable(struct ux500_regulator *regulator);
-
-/**
- * ux500_regulator_put()
- *
- * @regulator: Regulator handle, provided from ux500_regulator_get.
- */
-void ux500_regulator_put(struct ux500_regulator *regulator);
-#else
-static inline struct ux500_regulator *__must_check
-ux500_regulator_get(struct device *dev)
-{
- return ERR_PTR(-EINVAL);
-}
-
-static inline int
-ux500_regulator_atomic_enable(struct ux500_regulator *regulator)
-{
- return -EINVAL;
-}
-
-static inline int
-ux500_regulator_atomic_disable(struct ux500_regulator *regulator)
-{
- return -EINVAL;
-}
-
-static inline void ux500_regulator_put(struct ux500_regulator *regulator)
-{
-}
-#endif
-
-#endif