Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1542749 > unrolled thread
| Started by | Hans de Goede <hdegoede@redhat.com> |
|---|---|
| First post | 2016-12-15 15:10 +0100 |
| Last post | 2016-12-17 16:10 +0100 |
| Articles | 4 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH v2 1/2] mfd: axp20x: Add a few missing defines for AXP288 specific registers Hans de Goede <hdegoede@redhat.com> - 2016-12-15 15:10 +0100
[PATCH v2 2/2] mfd: axp20x: Fix axp288 volatile ranges Hans de Goede <hdegoede@redhat.com> - 2016-12-15 15:10 +0100
Re: [PATCH v2 2/2] mfd: axp20x: Fix axp288 volatile ranges Chen-Yu Tsai <wens@csie.org> - 2016-12-17 16:10 +0100
Re: [PATCH v2 1/2] mfd: axp20x: Add a few missing defines for AXP288 specific registers Chen-Yu Tsai <wens@csie.org> - 2016-12-17 16:10 +0100
| From | Hans de Goede <hdegoede@redhat.com> |
|---|---|
| Date | 2016-12-15 15:10 +0100 |
| Subject | [PATCH v2 1/2] mfd: axp20x: Add a few missing defines for AXP288 specific registers |
| Message-ID | <sOETo-6HQ-19@gated-at.bofh.it> |
Add defines for the AXP288_POWER_REASON and AXP288_RT_BATT_V_H and
AXP288_RT_BATT_V_L registers. While at it also move the
AXP288_TS_ADC_H-AXP288_GP_ADC_L defines, which for some reason where
in a different place, together with the rest of the AXP288 specific
defines.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
include/linux/mfd/axp20x.h | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/include/linux/mfd/axp20x.h b/include/linux/mfd/axp20x.h
index fe93e00..a0b1f4f 100644
--- a/include/linux/mfd/axp20x.h
+++ b/include/linux/mfd/axp20x.h
@@ -229,9 +229,16 @@ enum {
#define AXP22X_BATLOW_THRES1 0xe6
/* AXP288 specific registers */
+#define AXP288_POWER_REASON 0x02
#define AXP288_PMIC_ADC_H 0x56
#define AXP288_PMIC_ADC_L 0x57
+#define AXP288_TS_ADC_H 0x58
+#define AXP288_TS_ADC_L 0x59
+#define AXP288_GP_ADC_H 0x5a
+#define AXP288_GP_ADC_L 0x5b
#define AXP288_ADC_TS_PIN_CTRL 0x84
+#define AXP288_RT_BATT_V_H 0xa0
+#define AXP288_RT_BATT_V_L 0xa1
/* Fuel Gauge */
#define AXP288_FG_RDC1_REG 0xba
@@ -508,11 +515,6 @@ enum axp809_irqs {
AXP809_IRQ_GPIO0_INPUT,
};
-#define AXP288_TS_ADC_H 0x58
-#define AXP288_TS_ADC_L 0x59
-#define AXP288_GP_ADC_H 0x5a
-#define AXP288_GP_ADC_L 0x5b
-
struct axp20x_dev {
struct device *dev;
int irq;
--
2.9.3
[toc] | [next] | [standalone]
| From | Hans de Goede <hdegoede@redhat.com> |
|---|---|
| Date | 2016-12-15 15:10 +0100 |
| Subject | [PATCH v2 2/2] mfd: axp20x: Fix axp288 volatile ranges |
| Message-ID | <sOETo-6HQ-21@gated-at.bofh.it> |
| In reply to | #1542749 |
The axp288 pmic has a lot more volatile registers then we were
listing in axp288_volatile_ranges, fix this.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
Changes in v2:
-Add the following extra regs to axp288_volatile_ranges: AXP288_POWER_REASON,
AXP20X_TIMER_CTRL, AXP288_RT_BATT_V_H, AXP288_RT_BATT_V_L
---
drivers/mfd/axp20x.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/mfd/axp20x.c b/drivers/mfd/axp20x.c
index a294121..d3370c2 100644
--- a/drivers/mfd/axp20x.c
+++ b/drivers/mfd/axp20x.c
@@ -117,7 +117,12 @@ static const struct regmap_range axp288_writeable_ranges[] = {
};
static const struct regmap_range axp288_volatile_ranges[] = {
+ regmap_reg_range(AXP20X_PWR_INPUT_STATUS, AXP288_POWER_REASON),
regmap_reg_range(AXP20X_IRQ1_EN, AXP20X_IPSOUT_V_HIGH_L),
+ regmap_reg_range(AXP20X_TIMER_CTRL, AXP20X_TIMER_CTRL),
+ regmap_reg_range(AXP22X_GPIO_STATE, AXP22X_GPIO_STATE),
+ regmap_reg_range(AXP288_RT_BATT_V_H, AXP288_RT_BATT_V_L),
+ regmap_reg_range(AXP20X_FG_RES, AXP288_FG_CC_CAP_REG),
};
static const struct regmap_access_table axp288_writeable_table = {
--
2.9.3
[toc] | [prev] | [next] | [standalone]
| From | Chen-Yu Tsai <wens@csie.org> |
|---|---|
| Date | 2016-12-17 16:10 +0100 |
| Subject | Re: [PATCH v2 2/2] mfd: axp20x: Fix axp288 volatile ranges |
| Message-ID | <sPoMy-2MF-3@gated-at.bofh.it> |
| In reply to | #1542750 |
On Thu, Dec 15, 2016 at 10:07 PM, Hans de Goede <hdegoede@redhat.com> wrote: > The axp288 pmic has a lot more volatile registers then we were > listing in axp288_volatile_ranges, fix this. > > Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Chen-Yu Tsai <wens@csie.org>
[toc] | [prev] | [next] | [standalone]
| From | Chen-Yu Tsai <wens@csie.org> |
|---|---|
| Date | 2016-12-17 16:10 +0100 |
| Subject | Re: [PATCH v2 1/2] mfd: axp20x: Add a few missing defines for AXP288 specific registers |
| Message-ID | <sPoMy-2MF-5@gated-at.bofh.it> |
| In reply to | #1542749 |
On Thu, Dec 15, 2016 at 10:07 PM, Hans de Goede <hdegoede@redhat.com> wrote: > Add defines for the AXP288_POWER_REASON and AXP288_RT_BATT_V_H and > AXP288_RT_BATT_V_L registers. While at it also move the > AXP288_TS_ADC_H-AXP288_GP_ADC_L defines, which for some reason where > in a different place, together with the rest of the AXP288 specific > defines. > > Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Chen-Yu Tsai <wens@csie.org>
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web