summaryrefslogtreecommitdiff
path: root/drivers/mfd
diff options
context:
space:
mode:
authorPradeep Goudagunta <pgoudagunta@nvidia.com>2013-09-02 11:19:09 +0530
committerDan Willemsen <dwillemsen@nvidia.com>2013-09-14 13:45:03 -0700
commit4f8b7e49f4517e5a1be5f5b8eb1f54e7c8fd3b0b (patch)
treecc39e444c9fd5daf4170bd2a825c1144975750b2 /drivers/mfd
parente0617b409ebff9e9f2deeee07b9e0a8ec3ac5490 (diff)
mfd: palmas: Add palmas_thermal init
Initialize palmas_thermal driver, add palmas_thermal as mfd_cell and irq resources. Bug 1355680 Change-Id: Ia874afc435791bb905ea79b963b6e3412c343fc6 Signed-off-by: Pradeep Goudagunta <pgoudagunta@nvidia.com> Reviewed-on: http://git-master/r/267914 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Diffstat (limited to 'drivers/mfd')
-rw-r--r--drivers/mfd/palmas.c20
1 files changed, 18 insertions, 2 deletions
diff --git a/drivers/mfd/palmas.c b/drivers/mfd/palmas.c
index bb348175b32b..c6cd452695e2 100644
--- a/drivers/mfd/palmas.c
+++ b/drivers/mfd/palmas.c
@@ -40,6 +40,15 @@ static const struct resource charger_resource[] = {
},
};
+static const struct resource thermal_resource[] = {
+ {
+ .name = "palmas-junction-temp",
+ .start = PALMAS_HOTDIE_IRQ,
+ .end = PALMAS_HOTDIE_IRQ,
+ .flags = IORESOURCE_IRQ,
+ },
+};
+
enum palmas_ids {
PALMAS_PIN_MUX_ID = 0,
PALMAS_PMIC_ID,
@@ -58,6 +67,7 @@ enum palmas_ids {
PALMAS_CHARGER_ID,
PALMAS_SIM_ID,
PALMAS_PM_ID,
+ PALMAS_THERM_ID,
};
static struct resource palmas_rtc_resources[] = {
@@ -74,8 +84,8 @@ static struct resource palmas_rtc_resources[] = {
BIT(PALMAS_RTC_ID) | BIT(PALMAS_PWRBUTTON_ID) | \
BIT(PALMAS_GPADC_ID) | BIT(PALMAS_RESOURCE_ID) | \
BIT(PALMAS_CLK_ID) | BIT(PALMAS_PWM_ID) | \
- BIT(PALMAS_USB_ID) | BIT(PALMAS_EXTCON_ID)) | \
- BIT(PALMAS_PM_ID)
+ BIT(PALMAS_USB_ID) | BIT(PALMAS_EXTCON_ID) | \
+ BIT(PALMAS_PM_ID) | BIT(PALMAS_THERM_ID))
#define TPS80036_SUB_MODULE (TPS65913_SUB_MODULE | \
BIT(PALMAS_BATTERY_GAUGE_ID) | BIT(PALMAS_CHARGER_ID) | \
@@ -162,6 +172,12 @@ static const struct mfd_cell palmas_children[] = {
.name = "palmas-pm",
.id = PALMAS_PM_ID,
},
+ {
+ .name = "palmas-thermal",
+ .num_resources = ARRAY_SIZE(thermal_resource),
+ .resources = thermal_resource,
+ .id = PALMAS_THERM_ID,
+ },
};
static bool is_volatile_palma_func_reg(struct device *dev, unsigned int reg)