From: Chanwoo Choi <cw00.choi-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
To: "Krzysztof Kozłowski"
<k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
Cc: lee.jones-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org,
broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
mturquette-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org,
a.zummo-BfzFCNDTiLLj+vYz1yj4TQ@public.gmane.org,
lgirdwood-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
sbkim73-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org,
sameo-VuQAYsv1563Yd54FQh9/CA@public.gmane.org,
geunsik.lim-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org,
inki.dae-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org,
kyungmin.park-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 2/5] regulator: s2mps11: Add support S2MPS13 regulator device
Date: Tue, 18 Nov 2014 09:57:23 +0900 [thread overview]
Message-ID: <546A9973.6080706@samsung.com> (raw)
In-Reply-To: <5469CA11.3000409-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
Hi Krzysztof,
On 11/17/2014 07:12 PM, Krzysztof Kozłowski wrote:
> On 17.11.2014 01:42, Chanwoo Choi wrote:
>> This patch adds S2MPS13 regulator device to existing S2MPS11 device driver.
>> The S2MPS13 has just different number of regulators from S2MPS14.
>> The S2MPS13 regulator device includes LDO[1-40] and BUCK[1-10].
>>
>> Cc: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
>> Signed-off-by: Chanwoo Choi <cw00.choi-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
>> ---
>> drivers/mfd/sec-core.c | 13 +++
>> drivers/regulator/Kconfig | 10 +-
>> drivers/regulator/s2mps11.c | 102 +++++++++++++++++++-
>> include/linux/mfd/samsung/core.h | 1 +
>> include/linux/mfd/samsung/s2mps13.h | 186 ++++++++++++++++++++++++++++++++++++
>> 5 files changed, 304 insertions(+), 8 deletions(-)
>> create mode 100644 include/linux/mfd/samsung/s2mps13.h
>>
>> diff --git a/drivers/mfd/sec-core.c b/drivers/mfd/sec-core.c
>> index 48c0d4a..5b8527d 100644
>> --- a/drivers/mfd/sec-core.c
>> +++ b/drivers/mfd/sec-core.c
>> @@ -27,6 +27,7 @@
>> #include <linux/mfd/samsung/irq.h>
>> #include <linux/mfd/samsung/s2mpa01.h>
>> #include <linux/mfd/samsung/s2mps11.h>
>> +#include <linux/mfd/samsung/s2mps13.h>
>> #include <linux/mfd/samsung/s2mps14.h>
>> #include <linux/mfd/samsung/s2mpu02.h>
>> #include <linux/mfd/samsung/s5m8763.h>
>> @@ -207,6 +208,15 @@ static const struct regmap_config s2mps11_regmap_config = {
>> .cache_type = REGCACHE_FLAT,
>> };
>>
>> +static const struct regmap_config s2mps13_regmap_config = {
>> + .reg_bits = 8,
>> + .val_bits = 8,
>> +
>> + .max_register = S2MPS13_REG_LDODSCH5,
>> + .volatile_reg = s2mps11_volatile,
>> + .cache_type = REGCACHE_FLAT,
>> +};
>> +
>> static const struct regmap_config s2mps14_regmap_config = {
>> .reg_bits = 8,
>> .val_bits = 8,
>> @@ -338,6 +348,9 @@ static int sec_pmic_probe(struct i2c_client *i2c,
>> case S2MPS11X:
>> regmap = &s2mps11_regmap_config;
>> break;
>> + case S2MPS13X:
>> + regmap = &s2mps13_regmap_config;
>> + break;
>> case S2MPS14X:
>> regmap = &s2mps14_regmap_config;
>> break;
>
> Hi,
>
> Shouldn't this (with header file) be part of previous patch (1/5)?
The header file(linux/mfd/samsung/s2mps13.h) is used in this patch(2/5).
But, First patch(1/5) don't use some definitions in header file.
So, header file is included in this patch.
>
> Rest looks fine:
> Reviewed-by: Krzysztof Kozlowski <k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
Thanks for your review.
Best Regards,
Chanwoo Choi
>
>> diff --git a/drivers/regulator/Kconfig b/drivers/regulator/Kconfig
>> index 55d7b7b..5e06134 100644
>> --- a/drivers/regulator/Kconfig
>> +++ b/drivers/regulator/Kconfig
>> @@ -529,13 +529,13 @@ config REGULATOR_S2MPA01
>> via I2C bus. S2MPA01 has 10 Bucks and 26 LDO outputs.
>>
>> config REGULATOR_S2MPS11
>> - tristate "Samsung S2MPS11/S2MPS14/S2MPU02 voltage regulator"
>> + tristate "Samsung S2MPS11/S2MPS13/S2MPS14/S2MPU02 voltage regulator"
>> depends on MFD_SEC_CORE
>> help
>> - This driver supports a Samsung S2MPS11/S2MPS14/S2MPU02 voltage output
>> - regulator via I2C bus. The chip is comprised of high efficient Buck
>> - converters including Dual-Phase Buck converter, Buck-Boost converter,
>> - various LDOs.
>> + This driver supports a Samsung S2MPS11/S2MPS13/S2MPS14/S2MPU02 voltage
>> + output regulator via I2C bus. The chip is comprised of high efficient
>> + Buck converters including Dual-Phase Buck converter, Buck-Boost
>> + converter, various LDOs.
>>
>> config REGULATOR_S5M8767
>> tristate "Samsung S5M8767A voltage regulator"
>> diff --git a/drivers/regulator/s2mps11.c b/drivers/regulator/s2mps11.c
>> index adab82d..738dc77 100644
>> --- a/drivers/regulator/s2mps11.c
>> +++ b/drivers/regulator/s2mps11.c
>> @@ -30,6 +30,7 @@
>> #include <linux/of_gpio.h>
>> #include <linux/mfd/samsung/core.h>
>> #include <linux/mfd/samsung/s2mps11.h>
>> +#include <linux/mfd/samsung/s2mps13.h>
>> #include <linux/mfd/samsung/s2mps14.h>
>> #include <linux/mfd/samsung/s2mpu02.h>
>>
>> @@ -45,10 +46,10 @@ struct s2mps11_info {
>> enum sec_device_type dev_type;
>>
>> /*
>> - * One bit for each S2MPS14/S2MPU02 regulator whether the suspend mode
>> - * was enabled.
>> + * One bit for each S2MPS13/S2MPS14/S2MPU02 regulator whether
>> + * the suspend mode was enabled.
>> */
>> - unsigned long long s2mps14_suspend_state:35;
>> + unsigned long long s2mps14_suspend_state:50;
>>
>> /* Array of size rdev_num with GPIO-s for external sleep control */
>> int *ext_control_gpio;
>> @@ -369,12 +370,101 @@ static const struct regulator_desc s2mps11_regulators[] = {
>> regulator_desc_s2mps11_buck6_10(10, MIN_750_MV, STEP_12_5_MV),
>> };
>>
>> +static struct regulator_ops s2mps14_reg_ops;
>> +
>> +#define regulator_desc_s2mps13_ldo(num, min, step, min_sel) { \
>> + .name = "LDO"#num, \
>> + .id = S2MPS13_LDO##num, \
>> + .ops = &s2mps14_reg_ops, \
>> + .type = REGULATOR_VOLTAGE, \
>> + .owner = THIS_MODULE, \
>> + .min_uV = min, \
>> + .uV_step = step, \
>> + .linear_min_sel = min_sel, \
>> + .n_voltages = S2MPS14_LDO_N_VOLTAGES, \
>> + .vsel_reg = S2MPS13_REG_L1CTRL + num - 1, \
>> + .vsel_mask = S2MPS14_LDO_VSEL_MASK, \
>> + .enable_reg = S2MPS13_REG_L1CTRL + num - 1, \
>> + .enable_mask = S2MPS14_ENABLE_MASK \
>> +}
>> +
>> +#define regulator_desc_s2mps13_buck(num, min, step, min_sel) { \
>> + .name = "BUCK"#num, \
>> + .id = S2MPS13_BUCK##num, \
>> + .ops = &s2mps14_reg_ops, \
>> + .type = REGULATOR_VOLTAGE, \
>> + .owner = THIS_MODULE, \
>> + .min_uV = min, \
>> + .uV_step = step, \
>> + .linear_min_sel = min_sel, \
>> + .n_voltages = S2MPS14_BUCK_N_VOLTAGES, \
>> + .ramp_delay = S2MPS13_BUCK_RAMP_DELAY, \
>> + .vsel_reg = S2MPS13_REG_B1OUT + (num - 1) * 2, \
>> + .vsel_mask = S2MPS14_BUCK_VSEL_MASK, \
>> + .enable_reg = S2MPS13_REG_B1CTRL + (num - 1) * 2, \
>> + .enable_mask = S2MPS14_ENABLE_MASK \
>> +}
>> +
>> +static const struct regulator_desc s2mps13_regulators[] = {
>> + regulator_desc_s2mps13_ldo(1, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(2, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(3, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(4, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(5, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(6, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(7, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(8, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(9, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(10, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(11, MIN_800_MV, STEP_25_MV, 0x10),
>> + regulator_desc_s2mps13_ldo(12, MIN_800_MV, STEP_25_MV, 0x10),
>> + regulator_desc_s2mps13_ldo(13, MIN_800_MV, STEP_25_MV, 0x10),
>> + regulator_desc_s2mps13_ldo(14, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(15, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(16, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(17, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(18, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(19, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(20, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(21, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(22, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(23, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(24, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(25, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(26, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(27, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(28, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(29, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(30, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(31, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(32, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(33, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(34, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(35, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(36, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(37, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(38, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(39, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(40, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_buck(1, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(2, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(3, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(4, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(5, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(6, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(7, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(8, MIN_1000_MV, STEP_12_5_MV, 0x20),
>> + regulator_desc_s2mps13_buck(9, MIN_1000_MV, STEP_12_5_MV, 0x20),
>> + regulator_desc_s2mps13_buck(10, MIN_500_MV, STEP_6_25_MV, 0x10),
>> +};
>> +
>> static int s2mps14_regulator_enable(struct regulator_dev *rdev)
>> {
>> struct s2mps11_info *s2mps11 = rdev_get_drvdata(rdev);
>> unsigned int val;
>>
>> switch (s2mps11->dev_type) {
>> + case S2MPS13X:
>> case S2MPS14X:
>> if (s2mps11->s2mps14_suspend_state & (1 << rdev_get_id(rdev)))
>> val = S2MPS14_ENABLE_SUSPEND;
>> @@ -406,6 +496,7 @@ static int s2mps14_regulator_set_suspend_disable(struct regulator_dev *rdev)
>>
>> /* Below LDO should be always on or does not support suspend mode. */
>> switch (s2mps11->dev_type) {
>> + case S2MPS13X:
>> case S2MPS14X:
>> switch (rdev_id) {
>> case S2MPS14_LDO3:
>> @@ -831,6 +922,10 @@ static int s2mps11_pmic_probe(struct platform_device *pdev)
>> s2mps11->rdev_num = ARRAY_SIZE(s2mps11_regulators);
>> regulators = s2mps11_regulators;
>> break;
>> + case S2MPS13X:
>> + s2mps11->rdev_num = ARRAY_SIZE(s2mps13_regulators);
>> + regulators = s2mps13_regulators;
>> + break;
>> case S2MPS14X:
>> s2mps11->rdev_num = ARRAY_SIZE(s2mps14_regulators);
>> regulators = s2mps14_regulators;
>> @@ -927,6 +1022,7 @@ out:
>>
>> static const struct platform_device_id s2mps11_pmic_id[] = {
>> { "s2mps11-pmic", S2MPS11X},
>> + { "s2mps13-pmic", S2MPS13X},
>> { "s2mps14-pmic", S2MPS14X},
>> { "s2mpu02-pmic", S2MPU02},
>> { },
>> diff --git a/include/linux/mfd/samsung/core.h b/include/linux/mfd/samsung/core.h
>> index 0c0343e..3fdb7cf 100644
>> --- a/include/linux/mfd/samsung/core.h
>> +++ b/include/linux/mfd/samsung/core.h
>> @@ -28,6 +28,7 @@
>> #define MIN_800_MV 800000
>> #define MIN_750_MV 750000
>> #define MIN_600_MV 600000
>> +#define MIN_500_MV 500000
>>
>> /* Macros to represent steps for LDO/BUCK */
>> #define STEP_50_MV 50000
>> diff --git a/include/linux/mfd/samsung/s2mps13.h b/include/linux/mfd/samsung/s2mps13.h
>> new file mode 100644
>> index 0000000..ce5dda8
>> --- /dev/null
>> +++ b/include/linux/mfd/samsung/s2mps13.h
>> @@ -0,0 +1,186 @@
>> +/*
>> + * s2mps13.h
>> + *
>> + * Copyright (c) 2014 Samsung Electronics Co., Ltd
>> + * http://www.samsung.com
>> + *
>> + * This program is free software; you can redistribute it and/or modify it
>> + * under the terms of the GNU General Public License as published by the
>> + * Free Software Foundation; either version 2 of the License, or (at your
>> + * option) any later version.
>> + *
>> + * This program is distributed in the hope that it will be useful,
>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
>> + * GNU General Public License for more details.
>> + *
>> + */
>> +
>> +#ifndef __LINUX_MFD_S2MPS13_H
>> +#define __LINUX_MFD_S2MPS13_H
>> +
>> +/* S2MPS13 registers */
>> +enum s2mps13_reg {
>> + S2MPS13_REG_ID,
>> + S2MPS13_REG_INT1,
>> + S2MPS13_REG_INT2,
>> + S2MPS13_REG_INT3,
>> + S2MPS13_REG_INT1M,
>> + S2MPS13_REG_INT2M,
>> + S2MPS13_REG_INT3M,
>> + S2MPS13_REG_ST1,
>> + S2MPS13_REG_ST2,
>> + S2MPS13_REG_PWRONSRC,
>> + S2MPS13_REG_OFFSRC,
>> + S2MPS13_REG_BU_CHG,
>> + S2MPS13_REG_RTCCTRL,
>> + S2MPS13_REG_CTRL1,
>> + S2MPS13_REG_CTRL2,
>> + S2MPS13_REG_RSVD1,
>> + S2MPS13_REG_RSVD2,
>> + S2MPS13_REG_RSVD3,
>> + S2MPS13_REG_RSVD4,
>> + S2MPS13_REG_RSVD5,
>> + S2MPS13_REG_RSVD6,
>> + S2MPS13_REG_CTRL3,
>> + S2MPS13_REG_RSVD7,
>> + S2MPS13_REG_RSVD8,
>> + S2MPS13_REG_WRSTBI,
>> + S2MPS13_REG_B1CTRL,
>> + S2MPS13_REG_B1OUT,
>> + S2MPS13_REG_B2CTRL,
>> + S2MPS13_REG_B2OUT,
>> + S2MPS13_REG_B3CTRL,
>> + S2MPS13_REG_B3OUT,
>> + S2MPS13_REG_B4CTRL,
>> + S2MPS13_REG_B4OUT,
>> + S2MPS13_REG_B5CTRL,
>> + S2MPS13_REG_B5OUT,
>> + S2MPS13_REG_B6CTRL,
>> + S2MPS13_REG_B6OUT,
>> + S2MPS13_REG_B7CTRL,
>> + S2MPS13_REG_B7OUT,
>> + S2MPS13_REG_B8CTRL,
>> + S2MPS13_REG_B8OUT,
>> + S2MPS13_REG_B9CTRL,
>> + S2MPS13_REG_B9OUT,
>> + S2MPS13_REG_B10CTRL,
>> + S2MPS13_REG_B10OUT,
>> + S2MPS13_REG_BB1CTRL,
>> + S2MPS13_REG_BB1OUT,
>> + S2MPS13_REG_BUCK_RAMP1,
>> + S2MPS13_REG_BUCK_RAMP2,
>> + S2MPS13_REG_LDO_DVS1,
>> + S2MPS13_REG_LDO_DVS2,
>> + S2MPS13_REG_LDO_DVS3,
>> + S2MPS13_REG_B6OUT2,
>> + S2MPS13_REG_L1CTRL,
>> + S2MPS13_REG_L2CTRL,
>> + S2MPS13_REG_L3CTRL,
>> + S2MPS13_REG_L4CTRL,
>> + S2MPS13_REG_L5CTRL,
>> + S2MPS13_REG_L6CTRL,
>> + S2MPS13_REG_L7CTRL,
>> + S2MPS13_REG_L8CTRL,
>> + S2MPS13_REG_L9CTRL,
>> + S2MPS13_REG_L10CTRL,
>> + S2MPS13_REG_L11CTRL,
>> + S2MPS13_REG_L12CTRL,
>> + S2MPS13_REG_L13CTRL,
>> + S2MPS13_REG_L14CTRL,
>> + S2MPS13_REG_L15CTRL,
>> + S2MPS13_REG_L16CTRL,
>> + S2MPS13_REG_L17CTRL,
>> + S2MPS13_REG_L18CTRL,
>> + S2MPS13_REG_L19CTRL,
>> + S2MPS13_REG_L20CTRL,
>> + S2MPS13_REG_L21CTRL,
>> + S2MPS13_REG_L22CTRL,
>> + S2MPS13_REG_L23CTRL,
>> + S2MPS13_REG_L24CTRL,
>> + S2MPS13_REG_L25CTRL,
>> + S2MPS13_REG_L26CTRL,
>> + S2MPS13_REG_L27CTRL,
>> + S2MPS13_REG_L28CTRL,
>> + S2MPS13_REG_L30CTRL,
>> + S2MPS13_REG_L31CTRL,
>> + S2MPS13_REG_L32CTRL,
>> + S2MPS13_REG_L33CTRL,
>> + S2MPS13_REG_L34CTRL,
>> + S2MPS13_REG_L35CTRL,
>> + S2MPS13_REG_L36CTRL,
>> + S2MPS13_REG_L37CTRL,
>> + S2MPS13_REG_L38CTRL,
>> + S2MPS13_REG_L39CTRL,
>> + S2MPS13_REG_L40CTRL,
>> + S2MPS13_REG_LDODSCH1,
>> + S2MPS13_REG_LDODSCH2,
>> + S2MPS13_REG_LDODSCH3,
>> + S2MPS13_REG_LDODSCH4,
>> + S2MPS13_REG_LDODSCH5,
>> +};
>> +
>> +/* regulator ids */
>> +enum s2mps13_regulators {
>> + S2MPS13_LDO1,
>> + S2MPS13_LDO2,
>> + S2MPS13_LDO3,
>> + S2MPS13_LDO4,
>> + S2MPS13_LDO5,
>> + S2MPS13_LDO6,
>> + S2MPS13_LDO7,
>> + S2MPS13_LDO8,
>> + S2MPS13_LDO9,
>> + S2MPS13_LDO10,
>> + S2MPS13_LDO11,
>> + S2MPS13_LDO12,
>> + S2MPS13_LDO13,
>> + S2MPS13_LDO14,
>> + S2MPS13_LDO15,
>> + S2MPS13_LDO16,
>> + S2MPS13_LDO17,
>> + S2MPS13_LDO18,
>> + S2MPS13_LDO19,
>> + S2MPS13_LDO20,
>> + S2MPS13_LDO21,
>> + S2MPS13_LDO22,
>> + S2MPS13_LDO23,
>> + S2MPS13_LDO24,
>> + S2MPS13_LDO25,
>> + S2MPS13_LDO26,
>> + S2MPS13_LDO27,
>> + S2MPS13_LDO28,
>> + S2MPS13_LDO29,
>> + S2MPS13_LDO30,
>> + S2MPS13_LDO31,
>> + S2MPS13_LDO32,
>> + S2MPS13_LDO33,
>> + S2MPS13_LDO34,
>> + S2MPS13_LDO35,
>> + S2MPS13_LDO36,
>> + S2MPS13_LDO37,
>> + S2MPS13_LDO38,
>> + S2MPS13_LDO39,
>> + S2MPS13_LDO40,
>> + S2MPS13_BUCK1,
>> + S2MPS13_BUCK2,
>> + S2MPS13_BUCK3,
>> + S2MPS13_BUCK4,
>> + S2MPS13_BUCK5,
>> + S2MPS13_BUCK6,
>> + S2MPS13_BUCK7,
>> + S2MPS13_BUCK8,
>> + S2MPS13_BUCK9,
>> + S2MPS13_BUCK10,
>> +
>> + S2MPS13_REGULATOR_MAX,
>> +};
>> +
>> +/*
>> + * Default ramp delay in uv/us. Datasheet says that ramp delay can be
>> + * controlled however it does not specify which register is used for that.
>> + * Let's assume that default value will be set.
>> + */
>> +#define S2MPS13_BUCK_RAMP_DELAY 12500
>> +
>> +#endif /* __LINUX_MFD_S2MPS13_H */
>>
>
>
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
WARNING: multiple messages have this Message-ID (diff)
From: Chanwoo Choi <cw00.choi@samsung.com>
To: "Krzysztof Kozłowski" <k.kozlowski@samsung.com>
Cc: lee.jones@linaro.org, broonie@kernel.org, mturquette@linaro.org,
a.zummo@towertech.it, lgirdwood@gmail.com, sbkim73@samsung.com,
sameo@linux.intel.com, geunsik.lim@samsung.com,
inki.dae@samsung.com, kyungmin.park@samsung.com,
linux-kernel@vger.kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH 2/5] regulator: s2mps11: Add support S2MPS13 regulator device
Date: Tue, 18 Nov 2014 09:57:23 +0900 [thread overview]
Message-ID: <546A9973.6080706@samsung.com> (raw)
In-Reply-To: <5469CA11.3000409@samsung.com>
Hi Krzysztof,
On 11/17/2014 07:12 PM, Krzysztof Kozłowski wrote:
> On 17.11.2014 01:42, Chanwoo Choi wrote:
>> This patch adds S2MPS13 regulator device to existing S2MPS11 device driver.
>> The S2MPS13 has just different number of regulators from S2MPS14.
>> The S2MPS13 regulator device includes LDO[1-40] and BUCK[1-10].
>>
>> Cc: Mark Brown <broonie@kernel.org>
>> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
>> ---
>> drivers/mfd/sec-core.c | 13 +++
>> drivers/regulator/Kconfig | 10 +-
>> drivers/regulator/s2mps11.c | 102 +++++++++++++++++++-
>> include/linux/mfd/samsung/core.h | 1 +
>> include/linux/mfd/samsung/s2mps13.h | 186 ++++++++++++++++++++++++++++++++++++
>> 5 files changed, 304 insertions(+), 8 deletions(-)
>> create mode 100644 include/linux/mfd/samsung/s2mps13.h
>>
>> diff --git a/drivers/mfd/sec-core.c b/drivers/mfd/sec-core.c
>> index 48c0d4a..5b8527d 100644
>> --- a/drivers/mfd/sec-core.c
>> +++ b/drivers/mfd/sec-core.c
>> @@ -27,6 +27,7 @@
>> #include <linux/mfd/samsung/irq.h>
>> #include <linux/mfd/samsung/s2mpa01.h>
>> #include <linux/mfd/samsung/s2mps11.h>
>> +#include <linux/mfd/samsung/s2mps13.h>
>> #include <linux/mfd/samsung/s2mps14.h>
>> #include <linux/mfd/samsung/s2mpu02.h>
>> #include <linux/mfd/samsung/s5m8763.h>
>> @@ -207,6 +208,15 @@ static const struct regmap_config s2mps11_regmap_config = {
>> .cache_type = REGCACHE_FLAT,
>> };
>>
>> +static const struct regmap_config s2mps13_regmap_config = {
>> + .reg_bits = 8,
>> + .val_bits = 8,
>> +
>> + .max_register = S2MPS13_REG_LDODSCH5,
>> + .volatile_reg = s2mps11_volatile,
>> + .cache_type = REGCACHE_FLAT,
>> +};
>> +
>> static const struct regmap_config s2mps14_regmap_config = {
>> .reg_bits = 8,
>> .val_bits = 8,
>> @@ -338,6 +348,9 @@ static int sec_pmic_probe(struct i2c_client *i2c,
>> case S2MPS11X:
>> regmap = &s2mps11_regmap_config;
>> break;
>> + case S2MPS13X:
>> + regmap = &s2mps13_regmap_config;
>> + break;
>> case S2MPS14X:
>> regmap = &s2mps14_regmap_config;
>> break;
>
> Hi,
>
> Shouldn't this (with header file) be part of previous patch (1/5)?
The header file(linux/mfd/samsung/s2mps13.h) is used in this patch(2/5).
But, First patch(1/5) don't use some definitions in header file.
So, header file is included in this patch.
>
> Rest looks fine:
> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Thanks for your review.
Best Regards,
Chanwoo Choi
>
>> diff --git a/drivers/regulator/Kconfig b/drivers/regulator/Kconfig
>> index 55d7b7b..5e06134 100644
>> --- a/drivers/regulator/Kconfig
>> +++ b/drivers/regulator/Kconfig
>> @@ -529,13 +529,13 @@ config REGULATOR_S2MPA01
>> via I2C bus. S2MPA01 has 10 Bucks and 26 LDO outputs.
>>
>> config REGULATOR_S2MPS11
>> - tristate "Samsung S2MPS11/S2MPS14/S2MPU02 voltage regulator"
>> + tristate "Samsung S2MPS11/S2MPS13/S2MPS14/S2MPU02 voltage regulator"
>> depends on MFD_SEC_CORE
>> help
>> - This driver supports a Samsung S2MPS11/S2MPS14/S2MPU02 voltage output
>> - regulator via I2C bus. The chip is comprised of high efficient Buck
>> - converters including Dual-Phase Buck converter, Buck-Boost converter,
>> - various LDOs.
>> + This driver supports a Samsung S2MPS11/S2MPS13/S2MPS14/S2MPU02 voltage
>> + output regulator via I2C bus. The chip is comprised of high efficient
>> + Buck converters including Dual-Phase Buck converter, Buck-Boost
>> + converter, various LDOs.
>>
>> config REGULATOR_S5M8767
>> tristate "Samsung S5M8767A voltage regulator"
>> diff --git a/drivers/regulator/s2mps11.c b/drivers/regulator/s2mps11.c
>> index adab82d..738dc77 100644
>> --- a/drivers/regulator/s2mps11.c
>> +++ b/drivers/regulator/s2mps11.c
>> @@ -30,6 +30,7 @@
>> #include <linux/of_gpio.h>
>> #include <linux/mfd/samsung/core.h>
>> #include <linux/mfd/samsung/s2mps11.h>
>> +#include <linux/mfd/samsung/s2mps13.h>
>> #include <linux/mfd/samsung/s2mps14.h>
>> #include <linux/mfd/samsung/s2mpu02.h>
>>
>> @@ -45,10 +46,10 @@ struct s2mps11_info {
>> enum sec_device_type dev_type;
>>
>> /*
>> - * One bit for each S2MPS14/S2MPU02 regulator whether the suspend mode
>> - * was enabled.
>> + * One bit for each S2MPS13/S2MPS14/S2MPU02 regulator whether
>> + * the suspend mode was enabled.
>> */
>> - unsigned long long s2mps14_suspend_state:35;
>> + unsigned long long s2mps14_suspend_state:50;
>>
>> /* Array of size rdev_num with GPIO-s for external sleep control */
>> int *ext_control_gpio;
>> @@ -369,12 +370,101 @@ static const struct regulator_desc s2mps11_regulators[] = {
>> regulator_desc_s2mps11_buck6_10(10, MIN_750_MV, STEP_12_5_MV),
>> };
>>
>> +static struct regulator_ops s2mps14_reg_ops;
>> +
>> +#define regulator_desc_s2mps13_ldo(num, min, step, min_sel) { \
>> + .name = "LDO"#num, \
>> + .id = S2MPS13_LDO##num, \
>> + .ops = &s2mps14_reg_ops, \
>> + .type = REGULATOR_VOLTAGE, \
>> + .owner = THIS_MODULE, \
>> + .min_uV = min, \
>> + .uV_step = step, \
>> + .linear_min_sel = min_sel, \
>> + .n_voltages = S2MPS14_LDO_N_VOLTAGES, \
>> + .vsel_reg = S2MPS13_REG_L1CTRL + num - 1, \
>> + .vsel_mask = S2MPS14_LDO_VSEL_MASK, \
>> + .enable_reg = S2MPS13_REG_L1CTRL + num - 1, \
>> + .enable_mask = S2MPS14_ENABLE_MASK \
>> +}
>> +
>> +#define regulator_desc_s2mps13_buck(num, min, step, min_sel) { \
>> + .name = "BUCK"#num, \
>> + .id = S2MPS13_BUCK##num, \
>> + .ops = &s2mps14_reg_ops, \
>> + .type = REGULATOR_VOLTAGE, \
>> + .owner = THIS_MODULE, \
>> + .min_uV = min, \
>> + .uV_step = step, \
>> + .linear_min_sel = min_sel, \
>> + .n_voltages = S2MPS14_BUCK_N_VOLTAGES, \
>> + .ramp_delay = S2MPS13_BUCK_RAMP_DELAY, \
>> + .vsel_reg = S2MPS13_REG_B1OUT + (num - 1) * 2, \
>> + .vsel_mask = S2MPS14_BUCK_VSEL_MASK, \
>> + .enable_reg = S2MPS13_REG_B1CTRL + (num - 1) * 2, \
>> + .enable_mask = S2MPS14_ENABLE_MASK \
>> +}
>> +
>> +static const struct regulator_desc s2mps13_regulators[] = {
>> + regulator_desc_s2mps13_ldo(1, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(2, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(3, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(4, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(5, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(6, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(7, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(8, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(9, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(10, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(11, MIN_800_MV, STEP_25_MV, 0x10),
>> + regulator_desc_s2mps13_ldo(12, MIN_800_MV, STEP_25_MV, 0x10),
>> + regulator_desc_s2mps13_ldo(13, MIN_800_MV, STEP_25_MV, 0x10),
>> + regulator_desc_s2mps13_ldo(14, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(15, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(16, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(17, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(18, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(19, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(20, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(21, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(22, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(23, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(24, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(25, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(26, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(27, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(28, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(29, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(30, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(31, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(32, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(33, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(34, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(35, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(36, MIN_800_MV, STEP_12_5_MV, 0x00),
>> + regulator_desc_s2mps13_ldo(37, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(38, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_ldo(39, MIN_1000_MV, STEP_25_MV, 0x08),
>> + regulator_desc_s2mps13_ldo(40, MIN_1400_MV, STEP_50_MV, 0x0C),
>> + regulator_desc_s2mps13_buck(1, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(2, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(3, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(4, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(5, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(6, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(7, MIN_500_MV, STEP_6_25_MV, 0x10),
>> + regulator_desc_s2mps13_buck(8, MIN_1000_MV, STEP_12_5_MV, 0x20),
>> + regulator_desc_s2mps13_buck(9, MIN_1000_MV, STEP_12_5_MV, 0x20),
>> + regulator_desc_s2mps13_buck(10, MIN_500_MV, STEP_6_25_MV, 0x10),
>> +};
>> +
>> static int s2mps14_regulator_enable(struct regulator_dev *rdev)
>> {
>> struct s2mps11_info *s2mps11 = rdev_get_drvdata(rdev);
>> unsigned int val;
>>
>> switch (s2mps11->dev_type) {
>> + case S2MPS13X:
>> case S2MPS14X:
>> if (s2mps11->s2mps14_suspend_state & (1 << rdev_get_id(rdev)))
>> val = S2MPS14_ENABLE_SUSPEND;
>> @@ -406,6 +496,7 @@ static int s2mps14_regulator_set_suspend_disable(struct regulator_dev *rdev)
>>
>> /* Below LDO should be always on or does not support suspend mode. */
>> switch (s2mps11->dev_type) {
>> + case S2MPS13X:
>> case S2MPS14X:
>> switch (rdev_id) {
>> case S2MPS14_LDO3:
>> @@ -831,6 +922,10 @@ static int s2mps11_pmic_probe(struct platform_device *pdev)
>> s2mps11->rdev_num = ARRAY_SIZE(s2mps11_regulators);
>> regulators = s2mps11_regulators;
>> break;
>> + case S2MPS13X:
>> + s2mps11->rdev_num = ARRAY_SIZE(s2mps13_regulators);
>> + regulators = s2mps13_regulators;
>> + break;
>> case S2MPS14X:
>> s2mps11->rdev_num = ARRAY_SIZE(s2mps14_regulators);
>> regulators = s2mps14_regulators;
>> @@ -927,6 +1022,7 @@ out:
>>
>> static const struct platform_device_id s2mps11_pmic_id[] = {
>> { "s2mps11-pmic", S2MPS11X},
>> + { "s2mps13-pmic", S2MPS13X},
>> { "s2mps14-pmic", S2MPS14X},
>> { "s2mpu02-pmic", S2MPU02},
>> { },
>> diff --git a/include/linux/mfd/samsung/core.h b/include/linux/mfd/samsung/core.h
>> index 0c0343e..3fdb7cf 100644
>> --- a/include/linux/mfd/samsung/core.h
>> +++ b/include/linux/mfd/samsung/core.h
>> @@ -28,6 +28,7 @@
>> #define MIN_800_MV 800000
>> #define MIN_750_MV 750000
>> #define MIN_600_MV 600000
>> +#define MIN_500_MV 500000
>>
>> /* Macros to represent steps for LDO/BUCK */
>> #define STEP_50_MV 50000
>> diff --git a/include/linux/mfd/samsung/s2mps13.h b/include/linux/mfd/samsung/s2mps13.h
>> new file mode 100644
>> index 0000000..ce5dda8
>> --- /dev/null
>> +++ b/include/linux/mfd/samsung/s2mps13.h
>> @@ -0,0 +1,186 @@
>> +/*
>> + * s2mps13.h
>> + *
>> + * Copyright (c) 2014 Samsung Electronics Co., Ltd
>> + * http://www.samsung.com
>> + *
>> + * This program is free software; you can redistribute it and/or modify it
>> + * under the terms of the GNU General Public License as published by the
>> + * Free Software Foundation; either version 2 of the License, or (at your
>> + * option) any later version.
>> + *
>> + * This program is distributed in the hope that it will be useful,
>> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
>> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
>> + * GNU General Public License for more details.
>> + *
>> + */
>> +
>> +#ifndef __LINUX_MFD_S2MPS13_H
>> +#define __LINUX_MFD_S2MPS13_H
>> +
>> +/* S2MPS13 registers */
>> +enum s2mps13_reg {
>> + S2MPS13_REG_ID,
>> + S2MPS13_REG_INT1,
>> + S2MPS13_REG_INT2,
>> + S2MPS13_REG_INT3,
>> + S2MPS13_REG_INT1M,
>> + S2MPS13_REG_INT2M,
>> + S2MPS13_REG_INT3M,
>> + S2MPS13_REG_ST1,
>> + S2MPS13_REG_ST2,
>> + S2MPS13_REG_PWRONSRC,
>> + S2MPS13_REG_OFFSRC,
>> + S2MPS13_REG_BU_CHG,
>> + S2MPS13_REG_RTCCTRL,
>> + S2MPS13_REG_CTRL1,
>> + S2MPS13_REG_CTRL2,
>> + S2MPS13_REG_RSVD1,
>> + S2MPS13_REG_RSVD2,
>> + S2MPS13_REG_RSVD3,
>> + S2MPS13_REG_RSVD4,
>> + S2MPS13_REG_RSVD5,
>> + S2MPS13_REG_RSVD6,
>> + S2MPS13_REG_CTRL3,
>> + S2MPS13_REG_RSVD7,
>> + S2MPS13_REG_RSVD8,
>> + S2MPS13_REG_WRSTBI,
>> + S2MPS13_REG_B1CTRL,
>> + S2MPS13_REG_B1OUT,
>> + S2MPS13_REG_B2CTRL,
>> + S2MPS13_REG_B2OUT,
>> + S2MPS13_REG_B3CTRL,
>> + S2MPS13_REG_B3OUT,
>> + S2MPS13_REG_B4CTRL,
>> + S2MPS13_REG_B4OUT,
>> + S2MPS13_REG_B5CTRL,
>> + S2MPS13_REG_B5OUT,
>> + S2MPS13_REG_B6CTRL,
>> + S2MPS13_REG_B6OUT,
>> + S2MPS13_REG_B7CTRL,
>> + S2MPS13_REG_B7OUT,
>> + S2MPS13_REG_B8CTRL,
>> + S2MPS13_REG_B8OUT,
>> + S2MPS13_REG_B9CTRL,
>> + S2MPS13_REG_B9OUT,
>> + S2MPS13_REG_B10CTRL,
>> + S2MPS13_REG_B10OUT,
>> + S2MPS13_REG_BB1CTRL,
>> + S2MPS13_REG_BB1OUT,
>> + S2MPS13_REG_BUCK_RAMP1,
>> + S2MPS13_REG_BUCK_RAMP2,
>> + S2MPS13_REG_LDO_DVS1,
>> + S2MPS13_REG_LDO_DVS2,
>> + S2MPS13_REG_LDO_DVS3,
>> + S2MPS13_REG_B6OUT2,
>> + S2MPS13_REG_L1CTRL,
>> + S2MPS13_REG_L2CTRL,
>> + S2MPS13_REG_L3CTRL,
>> + S2MPS13_REG_L4CTRL,
>> + S2MPS13_REG_L5CTRL,
>> + S2MPS13_REG_L6CTRL,
>> + S2MPS13_REG_L7CTRL,
>> + S2MPS13_REG_L8CTRL,
>> + S2MPS13_REG_L9CTRL,
>> + S2MPS13_REG_L10CTRL,
>> + S2MPS13_REG_L11CTRL,
>> + S2MPS13_REG_L12CTRL,
>> + S2MPS13_REG_L13CTRL,
>> + S2MPS13_REG_L14CTRL,
>> + S2MPS13_REG_L15CTRL,
>> + S2MPS13_REG_L16CTRL,
>> + S2MPS13_REG_L17CTRL,
>> + S2MPS13_REG_L18CTRL,
>> + S2MPS13_REG_L19CTRL,
>> + S2MPS13_REG_L20CTRL,
>> + S2MPS13_REG_L21CTRL,
>> + S2MPS13_REG_L22CTRL,
>> + S2MPS13_REG_L23CTRL,
>> + S2MPS13_REG_L24CTRL,
>> + S2MPS13_REG_L25CTRL,
>> + S2MPS13_REG_L26CTRL,
>> + S2MPS13_REG_L27CTRL,
>> + S2MPS13_REG_L28CTRL,
>> + S2MPS13_REG_L30CTRL,
>> + S2MPS13_REG_L31CTRL,
>> + S2MPS13_REG_L32CTRL,
>> + S2MPS13_REG_L33CTRL,
>> + S2MPS13_REG_L34CTRL,
>> + S2MPS13_REG_L35CTRL,
>> + S2MPS13_REG_L36CTRL,
>> + S2MPS13_REG_L37CTRL,
>> + S2MPS13_REG_L38CTRL,
>> + S2MPS13_REG_L39CTRL,
>> + S2MPS13_REG_L40CTRL,
>> + S2MPS13_REG_LDODSCH1,
>> + S2MPS13_REG_LDODSCH2,
>> + S2MPS13_REG_LDODSCH3,
>> + S2MPS13_REG_LDODSCH4,
>> + S2MPS13_REG_LDODSCH5,
>> +};
>> +
>> +/* regulator ids */
>> +enum s2mps13_regulators {
>> + S2MPS13_LDO1,
>> + S2MPS13_LDO2,
>> + S2MPS13_LDO3,
>> + S2MPS13_LDO4,
>> + S2MPS13_LDO5,
>> + S2MPS13_LDO6,
>> + S2MPS13_LDO7,
>> + S2MPS13_LDO8,
>> + S2MPS13_LDO9,
>> + S2MPS13_LDO10,
>> + S2MPS13_LDO11,
>> + S2MPS13_LDO12,
>> + S2MPS13_LDO13,
>> + S2MPS13_LDO14,
>> + S2MPS13_LDO15,
>> + S2MPS13_LDO16,
>> + S2MPS13_LDO17,
>> + S2MPS13_LDO18,
>> + S2MPS13_LDO19,
>> + S2MPS13_LDO20,
>> + S2MPS13_LDO21,
>> + S2MPS13_LDO22,
>> + S2MPS13_LDO23,
>> + S2MPS13_LDO24,
>> + S2MPS13_LDO25,
>> + S2MPS13_LDO26,
>> + S2MPS13_LDO27,
>> + S2MPS13_LDO28,
>> + S2MPS13_LDO29,
>> + S2MPS13_LDO30,
>> + S2MPS13_LDO31,
>> + S2MPS13_LDO32,
>> + S2MPS13_LDO33,
>> + S2MPS13_LDO34,
>> + S2MPS13_LDO35,
>> + S2MPS13_LDO36,
>> + S2MPS13_LDO37,
>> + S2MPS13_LDO38,
>> + S2MPS13_LDO39,
>> + S2MPS13_LDO40,
>> + S2MPS13_BUCK1,
>> + S2MPS13_BUCK2,
>> + S2MPS13_BUCK3,
>> + S2MPS13_BUCK4,
>> + S2MPS13_BUCK5,
>> + S2MPS13_BUCK6,
>> + S2MPS13_BUCK7,
>> + S2MPS13_BUCK8,
>> + S2MPS13_BUCK9,
>> + S2MPS13_BUCK10,
>> +
>> + S2MPS13_REGULATOR_MAX,
>> +};
>> +
>> +/*
>> + * Default ramp delay in uv/us. Datasheet says that ramp delay can be
>> + * controlled however it does not specify which register is used for that.
>> + * Let's assume that default value will be set.
>> + */
>> +#define S2MPS13_BUCK_RAMP_DELAY 12500
>> +
>> +#endif /* __LINUX_MFD_S2MPS13_H */
>>
>
>
next prev parent reply other threads:[~2014-11-18 0:57 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-17 0:42 [PATCH 0/5] mfd: sec-core: Add support S2MPS13 PMIC device Chanwoo Choi
2014-11-17 0:42 ` [PATCH 1/5] mfd: sec-core: Add support for S2MPS13 device Chanwoo Choi
[not found] ` <1416184980-532-2-git-send-email-cw00.choi-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-11-18 0:26 ` Sangbeom Kim
2014-11-18 0:26 ` Sangbeom Kim
2014-11-18 8:22 ` Lee Jones
2014-11-18 8:33 ` Chanwoo Choi
2014-11-18 8:33 ` Chanwoo Choi
2014-11-17 0:42 ` [PATCH 2/5] regulator: s2mps11: Add support S2MPS13 regulator device Chanwoo Choi
[not found] ` <1416184980-532-3-git-send-email-cw00.choi-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-11-17 10:12 ` Krzysztof Kozłowski
2014-11-17 10:12 ` Krzysztof Kozłowski
[not found] ` <5469CA11.3000409-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-11-18 0:57 ` Chanwoo Choi [this message]
2014-11-18 0:57 ` Chanwoo Choi
2014-11-17 23:48 ` Mark Brown
2014-11-17 23:48 ` Mark Brown
2014-11-18 0:28 ` Sangbeom Kim
2014-11-18 0:28 ` Sangbeom Kim
2014-11-18 8:17 ` Lee Jones
2014-11-18 8:41 ` Chanwoo Choi
2014-11-17 0:42 ` [PATCH 3/5] clk: s2mps11: Add the support for S2MPS13 PMIC clock Chanwoo Choi
2014-11-17 10:16 ` Krzysztof Kozłowski
[not found] ` <5469CAF9.6020700-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-11-18 1:06 ` Chanwoo Choi
2014-11-18 1:06 ` Chanwoo Choi
2014-11-17 0:42 ` [PATCH 4/5] rtc: s5m: Add the support for S2MPS13 RTC Chanwoo Choi
[not found] ` <1416184980-532-5-git-send-email-cw00.choi-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-11-17 10:19 ` Krzysztof Kozłowski
2014-11-17 10:19 ` Krzysztof Kozłowski
2014-11-18 1:14 ` Chanwoo Choi
[not found] ` <546A9D7D.7040207-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-11-18 10:01 ` Krzysztof Kozlowski
2014-11-18 10:01 ` Krzysztof Kozlowski
2014-11-18 0:38 ` Sangbeom Kim
2014-11-18 0:38 ` Sangbeom Kim
2014-11-18 0:55 ` Chanwoo Choi
2014-11-18 8:25 ` Lee Jones
2014-11-18 8:53 ` Chanwoo Choi
2014-11-18 8:53 ` Chanwoo Choi
2014-11-17 0:43 ` [PATCH 5/5] mfd: s2mps11: Add binding documentation for Samsung S2MPS13 PMIC Chanwoo Choi
[not found] ` <1416184980-532-6-git-send-email-cw00.choi-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2014-11-17 10:20 ` Krzysztof Kozłowski
2014-11-17 10:20 ` Krzysztof Kozłowski
2014-11-18 0:40 ` Sangbeom Kim
2014-11-18 0:40 ` Sangbeom Kim
2014-11-18 8:19 ` Lee Jones
2014-11-18 8:19 ` Lee Jones
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=546A9973.6080706@samsung.com \
--to=cw00.choi-sze3o3uu22jbdgjk7y7tuq@public.gmane.org \
--cc=a.zummo-BfzFCNDTiLLj+vYz1yj4TQ@public.gmane.org \
--cc=broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=geunsik.lim-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org \
--cc=inki.dae-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org \
--cc=k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org \
--cc=kyungmin.park-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org \
--cc=lee.jones-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=lgirdwood-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=mturquette-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=sameo-VuQAYsv1563Yd54FQh9/CA@public.gmane.org \
--cc=sbkim73-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.