2019-03-18 15:51:50

by Wolfram Sang

[permalink] [raw]
Subject: [PATCH 0/6] mfd: da9063: remove platform_data

When working with this driver while debugging something else, I noticed that
there are no in-kernel users of platform_data anymore. Removing the support
simplifies the code and gets rid of quite some lines. The biggest refactoring
went to the regulator driver which could maybe benefit from more
refactorization. However, there is no in-kernel user of that driver, so no
testing. I left it at this stage. I think the changes are still at a level
where review and build-testing will give enough confidence.

Besides the regulator thing, it was tested on a Renesas Lager board (R-Car H2).
No regressions encountered. buildbot was happy, too.

The patches are based on v5.1-rc1. I'd vote for all of them going through the
MFD tree. Looking forward to comments!

Wolfram


Wolfram Sang (6):
regulator: da9063: remove platform_data support
input: da9063_onkey: remove platform_data support
mfd: da9063: remove platform_data support
regulator: da9063: move definitions out of a header into the driver
mfd: da9063: remove leftover platform_data definitions
regulator: da9063: platform_data is gone, depend on OF

drivers/input/misc/da9063_onkey.c | 11 +---
drivers/mfd/da9063-core.c | 20 +-----
drivers/mfd/da9063-i2c.c | 1 -
drivers/mfd/da9063-irq.c | 1 -
drivers/regulator/Kconfig | 2 +-
drivers/regulator/da9063-regulator.c | 61 +++++++++++++------
include/linux/mfd/da9063/pdata.h | 114 -----------------------------------
7 files changed, 49 insertions(+), 161 deletions(-)
delete mode 100644 include/linux/mfd/da9063/pdata.h

--
2.11.0



2019-03-18 15:50:01

by Wolfram Sang

[permalink] [raw]
Subject: [PATCH 4/6] regulator: da9063: move definitions out of a header into the driver

Those definitions are only used within the driver meanwhile, so put them
there.

Signed-off-by: Wolfram Sang <[email protected]>
---
drivers/regulator/da9063-regulator.c | 44 +++++++++++++++++++++++++++++++-
include/linux/mfd/da9063/pdata.h | 49 ------------------------------------
2 files changed, 43 insertions(+), 50 deletions(-)

diff --git a/drivers/regulator/da9063-regulator.c b/drivers/regulator/da9063-regulator.c
index 73c85039d0cf..c05859ad63d8 100644
--- a/drivers/regulator/da9063-regulator.c
+++ b/drivers/regulator/da9063-regulator.c
@@ -25,7 +25,6 @@
#include <linux/regulator/machine.h>
#include <linux/regulator/of_regulator.h>
#include <linux/mfd/da9063/core.h>
-#include <linux/mfd/da9063/pdata.h>
#include <linux/mfd/da9063/registers.h>


@@ -34,6 +33,49 @@
REG_FIELD(_reg, __builtin_ffs((int)_mask) - 1, \
sizeof(unsigned int) * 8 - __builtin_clz((_mask)) - 1)

+/* DA9063 and DA9063L regulator IDs */
+enum {
+ /* BUCKs */
+ DA9063_ID_BCORE1,
+ DA9063_ID_BCORE2,
+ DA9063_ID_BPRO,
+ DA9063_ID_BMEM,
+ DA9063_ID_BIO,
+ DA9063_ID_BPERI,
+
+ /* BCORE1 and BCORE2 in merged mode */
+ DA9063_ID_BCORES_MERGED,
+ /* BMEM and BIO in merged mode */
+ DA9063_ID_BMEM_BIO_MERGED,
+ /* When two BUCKs are merged, they cannot be reused separately */
+
+ /* LDOs on both DA9063 and DA9063L */
+ DA9063_ID_LDO3,
+ DA9063_ID_LDO7,
+ DA9063_ID_LDO8,
+ DA9063_ID_LDO9,
+ DA9063_ID_LDO11,
+
+ /* DA9063-only LDOs */
+ DA9063_ID_LDO1,
+ DA9063_ID_LDO2,
+ DA9063_ID_LDO4,
+ DA9063_ID_LDO5,
+ DA9063_ID_LDO6,
+ DA9063_ID_LDO10,
+};
+
+/* Old regulator platform data */
+struct da9063_regulator_data {
+ int id;
+ struct regulator_init_data *initdata;
+};
+
+struct da9063_regulators_pdata {
+ unsigned int n_regulators;
+ struct da9063_regulator_data *regulator_data;
+};
+
/* Regulator capabilities and registers description */
struct da9063_regulator_info {
struct regulator_desc desc;
diff --git a/include/linux/mfd/da9063/pdata.h b/include/linux/mfd/da9063/pdata.h
index 50bed4f89c1a..21a2d107f0cf 100644
--- a/include/linux/mfd/da9063/pdata.h
+++ b/include/linux/mfd/da9063/pdata.h
@@ -16,55 +16,6 @@
#ifndef __MFD_DA9063_PDATA_H__
#define __MFD_DA9063_PDATA_H__

-#include <linux/regulator/machine.h>
-
-/*
- * Regulator configuration
- */
-/* DA9063 and DA9063L regulator IDs */
-enum {
- /* BUCKs */
- DA9063_ID_BCORE1,
- DA9063_ID_BCORE2,
- DA9063_ID_BPRO,
- DA9063_ID_BMEM,
- DA9063_ID_BIO,
- DA9063_ID_BPERI,
-
- /* BCORE1 and BCORE2 in merged mode */
- DA9063_ID_BCORES_MERGED,
- /* BMEM and BIO in merged mode */
- DA9063_ID_BMEM_BIO_MERGED,
- /* When two BUCKs are merged, they cannot be reused separately */
-
- /* LDOs on both DA9063 and DA9063L */
- DA9063_ID_LDO3,
- DA9063_ID_LDO7,
- DA9063_ID_LDO8,
- DA9063_ID_LDO9,
- DA9063_ID_LDO11,
-
- /* DA9063-only LDOs */
- DA9063_ID_LDO1,
- DA9063_ID_LDO2,
- DA9063_ID_LDO4,
- DA9063_ID_LDO5,
- DA9063_ID_LDO6,
- DA9063_ID_LDO10,
-};
-
-/* Regulators platform data */
-struct da9063_regulator_data {
- int id;
- struct regulator_init_data *initdata;
-};
-
-struct da9063_regulators_pdata {
- unsigned n_regulators;
- struct da9063_regulator_data *regulator_data;
-};
-
-
/*
* RGB LED configuration
*/
--
2.11.0


2019-03-18 15:50:06

by Wolfram Sang

[permalink] [raw]
Subject: [PATCH 3/6] mfd: da9063: remove platform_data support

There are no in-kernel users anymore, so remove this outdated interface.

Signed-off-by: Wolfram Sang <[email protected]>
---
drivers/mfd/da9063-core.c | 20 ++------------------
drivers/mfd/da9063-i2c.c | 1 -
drivers/mfd/da9063-irq.c | 1 -
3 files changed, 2 insertions(+), 20 deletions(-)

diff --git a/drivers/mfd/da9063-core.c b/drivers/mfd/da9063-core.c
index 6e4ce49b4405..65ca288b0c90 100644
--- a/drivers/mfd/da9063-core.c
+++ b/drivers/mfd/da9063-core.c
@@ -26,7 +26,6 @@
#include <linux/regmap.h>

#include <linux/mfd/da9063/core.h>
-#include <linux/mfd/da9063/pdata.h>
#include <linux/mfd/da9063/registers.h>

#include <linux/proc_fs.h>
@@ -165,7 +164,6 @@ static int da9063_clear_fault_log(struct da9063 *da9063)

int da9063_device_init(struct da9063 *da9063, unsigned int irq)
{
- struct da9063_pdata *pdata = da9063->dev->platform_data;
int model, variant_id, variant_code;
int ret;

@@ -173,24 +171,10 @@ int da9063_device_init(struct da9063 *da9063, unsigned int irq)
if (ret < 0)
dev_err(da9063->dev, "Cannot clear fault log\n");

- if (pdata) {
- da9063->flags = pdata->flags;
- da9063->irq_base = pdata->irq_base;
- } else {
- da9063->flags = 0;
- da9063->irq_base = -1;
- }
+ da9063->flags = 0;
+ da9063->irq_base = -1;
da9063->chip_irq = irq;

- if (pdata && pdata->init != NULL) {
- ret = pdata->init(da9063);
- if (ret != 0) {
- dev_err(da9063->dev,
- "Platform initialization failed.\n");
- return ret;
- }
- }
-
ret = regmap_read(da9063->regmap, DA9063_REG_CHIP_ID, &model);
if (ret < 0) {
dev_err(da9063->dev, "Cannot read chip model id.\n");
diff --git a/drivers/mfd/da9063-i2c.c b/drivers/mfd/da9063-i2c.c
index 50a24b1921d0..5f707b100e69 100644
--- a/drivers/mfd/da9063-i2c.c
+++ b/drivers/mfd/da9063-i2c.c
@@ -22,7 +22,6 @@

#include <linux/mfd/core.h>
#include <linux/mfd/da9063/core.h>
-#include <linux/mfd/da9063/pdata.h>
#include <linux/mfd/da9063/registers.h>

#include <linux/of.h>
diff --git a/drivers/mfd/da9063-irq.c b/drivers/mfd/da9063-irq.c
index ecc0c8ce6c58..ac02c31c5802 100644
--- a/drivers/mfd/da9063-irq.c
+++ b/drivers/mfd/da9063-irq.c
@@ -19,7 +19,6 @@
#include <linux/interrupt.h>
#include <linux/regmap.h>
#include <linux/mfd/da9063/core.h>
-#include <linux/mfd/da9063/pdata.h>

#define DA9063_REG_EVENT_A_OFFSET 0
#define DA9063_REG_EVENT_B_OFFSET 1
--
2.11.0


2019-03-18 15:50:11

by Wolfram Sang

[permalink] [raw]
Subject: [PATCH 5/6] mfd: da9063: remove leftover platform_data definitions

Not used, not needed, remove them.

Signed-off-by: Wolfram Sang <[email protected]>
---
include/linux/mfd/da9063/pdata.h | 65 ----------------------------------------
1 file changed, 65 deletions(-)
delete mode 100644 include/linux/mfd/da9063/pdata.h

diff --git a/include/linux/mfd/da9063/pdata.h b/include/linux/mfd/da9063/pdata.h
deleted file mode 100644
index 21a2d107f0cf..000000000000
--- a/include/linux/mfd/da9063/pdata.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Platform configuration options for DA9063
- *
- * Copyright 2012 Dialog Semiconductor Ltd.
- *
- * Author: Michal Hajduk, Dialog Semiconductor
- * Author: Krystian Garbaciak, Dialog Semiconductor
- *
- * 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.
- *
- */
-
-#ifndef __MFD_DA9063_PDATA_H__
-#define __MFD_DA9063_PDATA_H__
-
-/*
- * RGB LED configuration
- */
-/* LED IDs for flags in struct led_info. */
-enum {
- DA9063_GPIO11_LED,
- DA9063_GPIO14_LED,
- DA9063_GPIO15_LED,
-
- DA9063_LED_NUM
-};
-#define DA9063_LED_ID_MASK 0x3
-
-/* LED polarity for flags in struct led_info. */
-#define DA9063_LED_HIGH_LEVEL_ACTIVE 0x0
-#define DA9063_LED_LOW_LEVEL_ACTIVE 0x4
-
-
-/*
- * General PMIC configuration
- */
-/* HWMON ADC channels configuration */
-#define DA9063_FLG_FORCE_IN0_MANUAL_MODE 0x0010
-#define DA9063_FLG_FORCE_IN0_AUTO_MODE 0x0020
-#define DA9063_FLG_FORCE_IN1_MANUAL_MODE 0x0040
-#define DA9063_FLG_FORCE_IN1_AUTO_MODE 0x0080
-#define DA9063_FLG_FORCE_IN2_MANUAL_MODE 0x0100
-#define DA9063_FLG_FORCE_IN2_AUTO_MODE 0x0200
-#define DA9063_FLG_FORCE_IN3_MANUAL_MODE 0x0400
-#define DA9063_FLG_FORCE_IN3_AUTO_MODE 0x0800
-
-/* Disable register caching. */
-#define DA9063_FLG_NO_CACHE 0x0008
-
-struct da9063;
-
-/* DA9063 platform data */
-struct da9063_pdata {
- int (*init)(struct da9063 *da9063);
- int irq_base;
- bool key_power;
- unsigned flags;
- struct da9063_regulators_pdata *regulators_pdata;
- struct led_platform_data *leds_pdata;
-};
-
-#endif /* __MFD_DA9063_PDATA_H__ */
--
2.11.0


2019-03-18 15:50:47

by Wolfram Sang

[permalink] [raw]
Subject: [PATCH 6/6] regulator: da9063: platform_data is gone, depend on OF

With OF being the only configuration possibility left, depend on it to
simplify some code.

Signed-off-by: Wolfram Sang <[email protected]>
---
drivers/regulator/Kconfig | 2 +-
drivers/regulator/da9063-regulator.c | 10 ----------
2 files changed, 1 insertion(+), 11 deletions(-)

diff --git a/drivers/regulator/Kconfig b/drivers/regulator/Kconfig
index b7f249ee5e68..6663cd6cb96c 100644
--- a/drivers/regulator/Kconfig
+++ b/drivers/regulator/Kconfig
@@ -256,7 +256,7 @@ config REGULATOR_DA9062

config REGULATOR_DA9063
tristate "Dialog Semiconductor DA9063 regulators"
- depends on MFD_DA9063
+ depends on MFD_DA9063 && OF
help
Say y here to support the BUCKs and LDOs regulators found on
DA9063 PMICs.
diff --git a/drivers/regulator/da9063-regulator.c b/drivers/regulator/da9063-regulator.c
index c05859ad63d8..2eda8d985756 100644
--- a/drivers/regulator/da9063-regulator.c
+++ b/drivers/regulator/da9063-regulator.c
@@ -681,7 +681,6 @@ static const struct regulator_init_data *da9063_get_regulator_initdata(
return NULL;
}

-#ifdef CONFIG_OF
static struct of_regulator_match da9063_matches[] = {
[DA9063_ID_BCORE1] = { .name = "bcore1" },
[DA9063_ID_BCORE2] = { .name = "bcore2" },
@@ -759,15 +758,6 @@ static struct da9063_regulators_pdata *da9063_parse_regulators_dt(
*da9063_reg_matches = da9063_matches;
return pdata;
}
-#else
-static struct da9063_regulators_pdata *da9063_parse_regulators_dt(
- struct platform_device *pdev,
- struct of_regulator_match **da9063_reg_matches)
-{
- *da9063_reg_matches = NULL;
- return ERR_PTR(-ENODEV);
-}
-#endif

static int da9063_regulator_probe(struct platform_device *pdev)
{
--
2.11.0


2019-03-18 15:51:07

by Wolfram Sang

[permalink] [raw]
Subject: [PATCH 2/6] input: da9063_onkey: remove platform_data support

There are no in-kernel users anymore, so remove this outdated interface.

Signed-off-by: Wolfram Sang <[email protected]>
---
drivers/input/misc/da9063_onkey.c | 11 ++---------
1 file changed, 2 insertions(+), 9 deletions(-)

diff --git a/drivers/input/misc/da9063_onkey.c b/drivers/input/misc/da9063_onkey.c
index 3e9c353d82ef..e3a273c74123 100644
--- a/drivers/input/misc/da9063_onkey.c
+++ b/drivers/input/misc/da9063_onkey.c
@@ -22,7 +22,6 @@
#include <linux/regmap.h>
#include <linux/of.h>
#include <linux/mfd/da9063/core.h>
-#include <linux/mfd/da9063/pdata.h>
#include <linux/mfd/da9063/registers.h>
#include <linux/mfd/da9062/core.h>
#include <linux/mfd/da9062/registers.h>
@@ -201,8 +200,6 @@ static void da9063_cancel_poll(void *data)

static int da9063_onkey_probe(struct platform_device *pdev)
{
- struct da9063 *da9063 = dev_get_drvdata(pdev->dev.parent);
- struct da9063_pdata *pdata = dev_get_platdata(da9063->dev);
struct da9063_onkey *onkey;
const struct of_device_id *match;
int irq;
@@ -229,12 +226,8 @@ static int da9063_onkey_probe(struct platform_device *pdev)
return -ENXIO;
}

- if (pdata)
- onkey->key_power = pdata->key_power;
- else
- onkey->key_power =
- !of_property_read_bool(pdev->dev.of_node,
- "dlg,disable-key-power");
+ onkey->key_power = !of_property_read_bool(pdev->dev.of_node,
+ "dlg,disable-key-power");

onkey->input = devm_input_allocate_device(&pdev->dev);
if (!onkey->input) {
--
2.11.0


2019-03-18 15:51:09

by Wolfram Sang

[permalink] [raw]
Subject: [PATCH 1/6] regulator: da9063: remove platform_data support

There are no in-kernel users anymore, so remove this outdated interface.

Signed-off-by: Wolfram Sang <[email protected]>
---
drivers/regulator/da9063-regulator.c | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/drivers/regulator/da9063-regulator.c b/drivers/regulator/da9063-regulator.c
index 2b0c7a85306a..73c85039d0cf 100644
--- a/drivers/regulator/da9063-regulator.c
+++ b/drivers/regulator/da9063-regulator.c
@@ -730,7 +730,6 @@ static struct da9063_regulators_pdata *da9063_parse_regulators_dt(
static int da9063_regulator_probe(struct platform_device *pdev)
{
struct da9063 *da9063 = dev_get_drvdata(pdev->dev.parent);
- struct da9063_pdata *da9063_pdata = dev_get_platdata(da9063->dev);
struct of_regulator_match *da9063_reg_matches = NULL;
struct da9063_regulators_pdata *regl_pdata;
const struct da9063_dev_model *model;
@@ -740,11 +739,7 @@ static int da9063_regulator_probe(struct platform_device *pdev)
bool bcores_merged, bmem_bio_merged;
int id, irq, n, n_regulators, ret, val;

- regl_pdata = da9063_pdata ? da9063_pdata->regulators_pdata : NULL;
-
- if (!regl_pdata)
- regl_pdata = da9063_parse_regulators_dt(pdev,
- &da9063_reg_matches);
+ regl_pdata = da9063_parse_regulators_dt(pdev, &da9063_reg_matches);

if (IS_ERR(regl_pdata) || regl_pdata->n_regulators == 0) {
dev_err(&pdev->dev,
--
2.11.0


2019-03-18 16:35:50

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 0/6] mfd: da9063: remove platform_data

Hi Mark,

On 18 March 2019 15:48, Wolfram Sang wrote:

> To: [email protected]
> Subject: [PATCH 0/6] mfd: da9063: remove platform_data
>
> When working with this driver while debugging something else, I noticed that
> there are no in-kernel users of platform_data anymore. Removing the support
> simplifies the code and gets rid of quite some lines. The biggest refactoring
> went to the regulator driver which could maybe benefit from more
> refactorization. However, there is no in-kernel user of that driver, so no
> testing. I left it at this stage. I think the changes are still at a level
> where review and build-testing will give enough confidence.
>
> Besides the regulator thing, it was tested on a Renesas Lager board (R-Car H2).
> No regressions encountered. buildbot was happy, too.
>
> The patches are based on v5.1-rc1. I'd vote for all of them going through the
> MFD tree. Looking forward to comments!
>
> Wolfram

My regulator tests are currently broken, so I'm looking into it.
I'll read-through and test these patches as soon as I've solved the regressions.

Regards,
Steve

2019-03-19 12:27:52

by Simon Horman

[permalink] [raw]
Subject: Re: [PATCH 3/6] mfd: da9063: remove platform_data support

On Mon, Mar 18, 2019 at 04:47:55PM +0100, Wolfram Sang wrote:
> There are no in-kernel users anymore, so remove this outdated interface.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> drivers/mfd/da9063-core.c | 20 ++------------------
> drivers/mfd/da9063-i2c.c | 1 -
> drivers/mfd/da9063-irq.c | 1 -
> 3 files changed, 2 insertions(+), 20 deletions(-)
>
> diff --git a/drivers/mfd/da9063-core.c b/drivers/mfd/da9063-core.c
> index 6e4ce49b4405..65ca288b0c90 100644
> --- a/drivers/mfd/da9063-core.c
> +++ b/drivers/mfd/da9063-core.c
> @@ -26,7 +26,6 @@
> #include <linux/regmap.h>
>
> #include <linux/mfd/da9063/core.h>
> -#include <linux/mfd/da9063/pdata.h>
> #include <linux/mfd/da9063/registers.h>
>
> #include <linux/proc_fs.h>
> @@ -165,7 +164,6 @@ static int da9063_clear_fault_log(struct da9063 *da9063)
>
> int da9063_device_init(struct da9063 *da9063, unsigned int irq)
> {
> - struct da9063_pdata *pdata = da9063->dev->platform_data;
> int model, variant_id, variant_code;
> int ret;
>
> @@ -173,24 +171,10 @@ int da9063_device_init(struct da9063 *da9063, unsigned int irq)
> if (ret < 0)
> dev_err(da9063->dev, "Cannot clear fault log\n");
>
> - if (pdata) {
> - da9063->flags = pdata->flags;
> - da9063->irq_base = pdata->irq_base;
> - } else {
> - da9063->flags = 0;
> - da9063->irq_base = -1;
> - }
> + da9063->flags = 0;
> + da9063->irq_base = -1;

If the flag and irq_base fields have fixed values can
they be removed? As a follow-up?

> da9063->chip_irq = irq;
>
> - if (pdata && pdata->init != NULL) {
> - ret = pdata->init(da9063);
> - if (ret != 0) {
> - dev_err(da9063->dev,
> - "Platform initialization failed.\n");
> - return ret;
> - }
> - }
> -
> ret = regmap_read(da9063->regmap, DA9063_REG_CHIP_ID, &model);
> if (ret < 0) {
> dev_err(da9063->dev, "Cannot read chip model id.\n");
> diff --git a/drivers/mfd/da9063-i2c.c b/drivers/mfd/da9063-i2c.c
> index 50a24b1921d0..5f707b100e69 100644
> --- a/drivers/mfd/da9063-i2c.c
> +++ b/drivers/mfd/da9063-i2c.c
> @@ -22,7 +22,6 @@
>
> #include <linux/mfd/core.h>
> #include <linux/mfd/da9063/core.h>
> -#include <linux/mfd/da9063/pdata.h>
> #include <linux/mfd/da9063/registers.h>
>
> #include <linux/of.h>
> diff --git a/drivers/mfd/da9063-irq.c b/drivers/mfd/da9063-irq.c
> index ecc0c8ce6c58..ac02c31c5802 100644
> --- a/drivers/mfd/da9063-irq.c
> +++ b/drivers/mfd/da9063-irq.c
> @@ -19,7 +19,6 @@
> #include <linux/interrupt.h>
> #include <linux/regmap.h>
> #include <linux/mfd/da9063/core.h>
> -#include <linux/mfd/da9063/pdata.h>
>
> #define DA9063_REG_EVENT_A_OFFSET 0
> #define DA9063_REG_EVENT_B_OFFSET 1
> --
> 2.11.0
>

2019-03-19 12:50:16

by Simon Horman

[permalink] [raw]
Subject: Re: [PATCH 1/6] regulator: da9063: remove platform_data support

On Mon, Mar 18, 2019 at 04:47:53PM +0100, Wolfram Sang wrote:
> There are no in-kernel users anymore, so remove this outdated interface.
>
> Signed-off-by: Wolfram Sang <[email protected]>

Reviewed-by: Simon Horman <[email protected]>

> ---
> drivers/regulator/da9063-regulator.c | 7 +------
> 1 file changed, 1 insertion(+), 6 deletions(-)
>
> diff --git a/drivers/regulator/da9063-regulator.c b/drivers/regulator/da9063-regulator.c
> index 2b0c7a85306a..73c85039d0cf 100644
> --- a/drivers/regulator/da9063-regulator.c
> +++ b/drivers/regulator/da9063-regulator.c
> @@ -730,7 +730,6 @@ static struct da9063_regulators_pdata *da9063_parse_regulators_dt(
> static int da9063_regulator_probe(struct platform_device *pdev)
> {
> struct da9063 *da9063 = dev_get_drvdata(pdev->dev.parent);
> - struct da9063_pdata *da9063_pdata = dev_get_platdata(da9063->dev);
> struct of_regulator_match *da9063_reg_matches = NULL;
> struct da9063_regulators_pdata *regl_pdata;
> const struct da9063_dev_model *model;
> @@ -740,11 +739,7 @@ static int da9063_regulator_probe(struct platform_device *pdev)
> bool bcores_merged, bmem_bio_merged;
> int id, irq, n, n_regulators, ret, val;
>
> - regl_pdata = da9063_pdata ? da9063_pdata->regulators_pdata : NULL;
> -
> - if (!regl_pdata)
> - regl_pdata = da9063_parse_regulators_dt(pdev,
> - &da9063_reg_matches);
> + regl_pdata = da9063_parse_regulators_dt(pdev, &da9063_reg_matches);
>
> if (IS_ERR(regl_pdata) || regl_pdata->n_regulators == 0) {
> dev_err(&pdev->dev,
> --
> 2.11.0
>

2019-03-19 12:51:35

by Simon Horman

[permalink] [raw]
Subject: Re: [PATCH 6/6] regulator: da9063: platform_data is gone, depend on OF

On Mon, Mar 18, 2019 at 04:47:58PM +0100, Wolfram Sang wrote:
> With OF being the only configuration possibility left, depend on it to
> simplify some code.
>
> Signed-off-by: Wolfram Sang <[email protected]>

Reviewed-by: Simon Horman <[email protected]>

> ---
> drivers/regulator/Kconfig | 2 +-
> drivers/regulator/da9063-regulator.c | 10 ----------
> 2 files changed, 1 insertion(+), 11 deletions(-)
>
> diff --git a/drivers/regulator/Kconfig b/drivers/regulator/Kconfig
> index b7f249ee5e68..6663cd6cb96c 100644
> --- a/drivers/regulator/Kconfig
> +++ b/drivers/regulator/Kconfig
> @@ -256,7 +256,7 @@ config REGULATOR_DA9062
>
> config REGULATOR_DA9063
> tristate "Dialog Semiconductor DA9063 regulators"
> - depends on MFD_DA9063
> + depends on MFD_DA9063 && OF
> help
> Say y here to support the BUCKs and LDOs regulators found on
> DA9063 PMICs.
> diff --git a/drivers/regulator/da9063-regulator.c b/drivers/regulator/da9063-regulator.c
> index c05859ad63d8..2eda8d985756 100644
> --- a/drivers/regulator/da9063-regulator.c
> +++ b/drivers/regulator/da9063-regulator.c
> @@ -681,7 +681,6 @@ static const struct regulator_init_data *da9063_get_regulator_initdata(
> return NULL;
> }
>
> -#ifdef CONFIG_OF
> static struct of_regulator_match da9063_matches[] = {
> [DA9063_ID_BCORE1] = { .name = "bcore1" },
> [DA9063_ID_BCORE2] = { .name = "bcore2" },
> @@ -759,15 +758,6 @@ static struct da9063_regulators_pdata *da9063_parse_regulators_dt(
> *da9063_reg_matches = da9063_matches;
> return pdata;
> }
> -#else
> -static struct da9063_regulators_pdata *da9063_parse_regulators_dt(
> - struct platform_device *pdev,
> - struct of_regulator_match **da9063_reg_matches)
> -{
> - *da9063_reg_matches = NULL;
> - return ERR_PTR(-ENODEV);
> -}
> -#endif
>
> static int da9063_regulator_probe(struct platform_device *pdev)
> {
> --
> 2.11.0
>

2019-03-19 12:51:47

by Simon Horman

[permalink] [raw]
Subject: Re: [PATCH 2/6] input: da9063_onkey: remove platform_data support

On Mon, Mar 18, 2019 at 04:47:54PM +0100, Wolfram Sang wrote:
> There are no in-kernel users anymore, so remove this outdated interface.
>
> Signed-off-by: Wolfram Sang <[email protected]>

Reviewed-by: Simon Horman <[email protected]>

> ---
> drivers/input/misc/da9063_onkey.c | 11 ++---------
> 1 file changed, 2 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/input/misc/da9063_onkey.c b/drivers/input/misc/da9063_onkey.c
> index 3e9c353d82ef..e3a273c74123 100644
> --- a/drivers/input/misc/da9063_onkey.c
> +++ b/drivers/input/misc/da9063_onkey.c
> @@ -22,7 +22,6 @@
> #include <linux/regmap.h>
> #include <linux/of.h>
> #include <linux/mfd/da9063/core.h>
> -#include <linux/mfd/da9063/pdata.h>
> #include <linux/mfd/da9063/registers.h>
> #include <linux/mfd/da9062/core.h>
> #include <linux/mfd/da9062/registers.h>
> @@ -201,8 +200,6 @@ static void da9063_cancel_poll(void *data)
>
> static int da9063_onkey_probe(struct platform_device *pdev)
> {
> - struct da9063 *da9063 = dev_get_drvdata(pdev->dev.parent);
> - struct da9063_pdata *pdata = dev_get_platdata(da9063->dev);
> struct da9063_onkey *onkey;
> const struct of_device_id *match;
> int irq;
> @@ -229,12 +226,8 @@ static int da9063_onkey_probe(struct platform_device *pdev)
> return -ENXIO;
> }
>
> - if (pdata)
> - onkey->key_power = pdata->key_power;
> - else
> - onkey->key_power =
> - !of_property_read_bool(pdev->dev.of_node,
> - "dlg,disable-key-power");
> + onkey->key_power = !of_property_read_bool(pdev->dev.of_node,
> + "dlg,disable-key-power");
>
> onkey->input = devm_input_allocate_device(&pdev->dev);
> if (!onkey->input) {
> --
> 2.11.0
>

2019-03-19 12:52:03

by Simon Horman

[permalink] [raw]
Subject: Re: [PATCH 3/6] mfd: da9063: remove platform_data support

On Mon, Mar 18, 2019 at 04:47:55PM +0100, Wolfram Sang wrote:
> There are no in-kernel users anymore, so remove this outdated interface.
>
> Signed-off-by: Wolfram Sang <[email protected]>

Reviewed-by: Simon Horman <[email protected]>

> ---
> drivers/mfd/da9063-core.c | 20 ++------------------
> drivers/mfd/da9063-i2c.c | 1 -
> drivers/mfd/da9063-irq.c | 1 -
> 3 files changed, 2 insertions(+), 20 deletions(-)
>
> diff --git a/drivers/mfd/da9063-core.c b/drivers/mfd/da9063-core.c
> index 6e4ce49b4405..65ca288b0c90 100644
> --- a/drivers/mfd/da9063-core.c
> +++ b/drivers/mfd/da9063-core.c
> @@ -26,7 +26,6 @@
> #include <linux/regmap.h>
>
> #include <linux/mfd/da9063/core.h>
> -#include <linux/mfd/da9063/pdata.h>
> #include <linux/mfd/da9063/registers.h>
>
> #include <linux/proc_fs.h>
> @@ -165,7 +164,6 @@ static int da9063_clear_fault_log(struct da9063 *da9063)
>
> int da9063_device_init(struct da9063 *da9063, unsigned int irq)
> {
> - struct da9063_pdata *pdata = da9063->dev->platform_data;
> int model, variant_id, variant_code;
> int ret;
>
> @@ -173,24 +171,10 @@ int da9063_device_init(struct da9063 *da9063, unsigned int irq)
> if (ret < 0)
> dev_err(da9063->dev, "Cannot clear fault log\n");
>
> - if (pdata) {
> - da9063->flags = pdata->flags;
> - da9063->irq_base = pdata->irq_base;
> - } else {
> - da9063->flags = 0;
> - da9063->irq_base = -1;
> - }
> + da9063->flags = 0;
> + da9063->irq_base = -1;
> da9063->chip_irq = irq;
>
> - if (pdata && pdata->init != NULL) {
> - ret = pdata->init(da9063);
> - if (ret != 0) {
> - dev_err(da9063->dev,
> - "Platform initialization failed.\n");
> - return ret;
> - }
> - }
> -
> ret = regmap_read(da9063->regmap, DA9063_REG_CHIP_ID, &model);
> if (ret < 0) {
> dev_err(da9063->dev, "Cannot read chip model id.\n");
> diff --git a/drivers/mfd/da9063-i2c.c b/drivers/mfd/da9063-i2c.c
> index 50a24b1921d0..5f707b100e69 100644
> --- a/drivers/mfd/da9063-i2c.c
> +++ b/drivers/mfd/da9063-i2c.c
> @@ -22,7 +22,6 @@
>
> #include <linux/mfd/core.h>
> #include <linux/mfd/da9063/core.h>
> -#include <linux/mfd/da9063/pdata.h>
> #include <linux/mfd/da9063/registers.h>
>
> #include <linux/of.h>
> diff --git a/drivers/mfd/da9063-irq.c b/drivers/mfd/da9063-irq.c
> index ecc0c8ce6c58..ac02c31c5802 100644
> --- a/drivers/mfd/da9063-irq.c
> +++ b/drivers/mfd/da9063-irq.c
> @@ -19,7 +19,6 @@
> #include <linux/interrupt.h>
> #include <linux/regmap.h>
> #include <linux/mfd/da9063/core.h>
> -#include <linux/mfd/da9063/pdata.h>
>
> #define DA9063_REG_EVENT_A_OFFSET 0
> #define DA9063_REG_EVENT_B_OFFSET 1
> --
> 2.11.0
>

2019-03-19 12:52:12

by Simon Horman

[permalink] [raw]
Subject: Re: [PATCH 4/6] regulator: da9063: move definitions out of a header into the driver

On Mon, Mar 18, 2019 at 04:47:56PM +0100, Wolfram Sang wrote:
> Those definitions are only used within the driver meanwhile, so put them
> there.
>
> Signed-off-by: Wolfram Sang <[email protected]>

Reviewed-by: Simon Horman <[email protected]>

> ---
> drivers/regulator/da9063-regulator.c | 44 +++++++++++++++++++++++++++++++-
> include/linux/mfd/da9063/pdata.h | 49 ------------------------------------
> 2 files changed, 43 insertions(+), 50 deletions(-)
>
> diff --git a/drivers/regulator/da9063-regulator.c b/drivers/regulator/da9063-regulator.c
> index 73c85039d0cf..c05859ad63d8 100644
> --- a/drivers/regulator/da9063-regulator.c
> +++ b/drivers/regulator/da9063-regulator.c
> @@ -25,7 +25,6 @@
> #include <linux/regulator/machine.h>
> #include <linux/regulator/of_regulator.h>
> #include <linux/mfd/da9063/core.h>
> -#include <linux/mfd/da9063/pdata.h>
> #include <linux/mfd/da9063/registers.h>
>
>
> @@ -34,6 +33,49 @@
> REG_FIELD(_reg, __builtin_ffs((int)_mask) - 1, \
> sizeof(unsigned int) * 8 - __builtin_clz((_mask)) - 1)
>
> +/* DA9063 and DA9063L regulator IDs */
> +enum {
> + /* BUCKs */
> + DA9063_ID_BCORE1,
> + DA9063_ID_BCORE2,
> + DA9063_ID_BPRO,
> + DA9063_ID_BMEM,
> + DA9063_ID_BIO,
> + DA9063_ID_BPERI,
> +
> + /* BCORE1 and BCORE2 in merged mode */
> + DA9063_ID_BCORES_MERGED,
> + /* BMEM and BIO in merged mode */
> + DA9063_ID_BMEM_BIO_MERGED,
> + /* When two BUCKs are merged, they cannot be reused separately */
> +
> + /* LDOs on both DA9063 and DA9063L */
> + DA9063_ID_LDO3,
> + DA9063_ID_LDO7,
> + DA9063_ID_LDO8,
> + DA9063_ID_LDO9,
> + DA9063_ID_LDO11,
> +
> + /* DA9063-only LDOs */
> + DA9063_ID_LDO1,
> + DA9063_ID_LDO2,
> + DA9063_ID_LDO4,
> + DA9063_ID_LDO5,
> + DA9063_ID_LDO6,
> + DA9063_ID_LDO10,
> +};
> +
> +/* Old regulator platform data */
> +struct da9063_regulator_data {
> + int id;
> + struct regulator_init_data *initdata;
> +};
> +
> +struct da9063_regulators_pdata {
> + unsigned int n_regulators;
> + struct da9063_regulator_data *regulator_data;
> +};
> +
> /* Regulator capabilities and registers description */
> struct da9063_regulator_info {
> struct regulator_desc desc;
> diff --git a/include/linux/mfd/da9063/pdata.h b/include/linux/mfd/da9063/pdata.h
> index 50bed4f89c1a..21a2d107f0cf 100644
> --- a/include/linux/mfd/da9063/pdata.h
> +++ b/include/linux/mfd/da9063/pdata.h
> @@ -16,55 +16,6 @@
> #ifndef __MFD_DA9063_PDATA_H__
> #define __MFD_DA9063_PDATA_H__
>
> -#include <linux/regulator/machine.h>
> -
> -/*
> - * Regulator configuration
> - */
> -/* DA9063 and DA9063L regulator IDs */
> -enum {
> - /* BUCKs */
> - DA9063_ID_BCORE1,
> - DA9063_ID_BCORE2,
> - DA9063_ID_BPRO,
> - DA9063_ID_BMEM,
> - DA9063_ID_BIO,
> - DA9063_ID_BPERI,
> -
> - /* BCORE1 and BCORE2 in merged mode */
> - DA9063_ID_BCORES_MERGED,
> - /* BMEM and BIO in merged mode */
> - DA9063_ID_BMEM_BIO_MERGED,
> - /* When two BUCKs are merged, they cannot be reused separately */
> -
> - /* LDOs on both DA9063 and DA9063L */
> - DA9063_ID_LDO3,
> - DA9063_ID_LDO7,
> - DA9063_ID_LDO8,
> - DA9063_ID_LDO9,
> - DA9063_ID_LDO11,
> -
> - /* DA9063-only LDOs */
> - DA9063_ID_LDO1,
> - DA9063_ID_LDO2,
> - DA9063_ID_LDO4,
> - DA9063_ID_LDO5,
> - DA9063_ID_LDO6,
> - DA9063_ID_LDO10,
> -};
> -
> -/* Regulators platform data */
> -struct da9063_regulator_data {
> - int id;
> - struct regulator_init_data *initdata;
> -};
> -
> -struct da9063_regulators_pdata {
> - unsigned n_regulators;
> - struct da9063_regulator_data *regulator_data;
> -};
> -
> -
> /*
> * RGB LED configuration
> */
> --
> 2.11.0
>

2019-03-19 12:52:29

by Simon Horman

[permalink] [raw]
Subject: Re: [PATCH 5/6] mfd: da9063: remove leftover platform_data definitions

On Mon, Mar 18, 2019 at 04:47:57PM +0100, Wolfram Sang wrote:
> Not used, not needed, remove them.
>
> Signed-off-by: Wolfram Sang <[email protected]>

Reviewed-by: Simon Horman <[email protected]>

> ---
> include/linux/mfd/da9063/pdata.h | 65 ----------------------------------------
> 1 file changed, 65 deletions(-)
> delete mode 100644 include/linux/mfd/da9063/pdata.h
>
> diff --git a/include/linux/mfd/da9063/pdata.h b/include/linux/mfd/da9063/pdata.h
> deleted file mode 100644
> index 21a2d107f0cf..000000000000
> --- a/include/linux/mfd/da9063/pdata.h
> +++ /dev/null
> @@ -1,65 +0,0 @@
> -/*
> - * Platform configuration options for DA9063
> - *
> - * Copyright 2012 Dialog Semiconductor Ltd.
> - *
> - * Author: Michal Hajduk, Dialog Semiconductor
> - * Author: Krystian Garbaciak, Dialog Semiconductor
> - *
> - * 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.
> - *
> - */
> -
> -#ifndef __MFD_DA9063_PDATA_H__
> -#define __MFD_DA9063_PDATA_H__
> -
> -/*
> - * RGB LED configuration
> - */
> -/* LED IDs for flags in struct led_info. */
> -enum {
> - DA9063_GPIO11_LED,
> - DA9063_GPIO14_LED,
> - DA9063_GPIO15_LED,
> -
> - DA9063_LED_NUM
> -};
> -#define DA9063_LED_ID_MASK 0x3
> -
> -/* LED polarity for flags in struct led_info. */
> -#define DA9063_LED_HIGH_LEVEL_ACTIVE 0x0
> -#define DA9063_LED_LOW_LEVEL_ACTIVE 0x4
> -
> -
> -/*
> - * General PMIC configuration
> - */
> -/* HWMON ADC channels configuration */
> -#define DA9063_FLG_FORCE_IN0_MANUAL_MODE 0x0010
> -#define DA9063_FLG_FORCE_IN0_AUTO_MODE 0x0020
> -#define DA9063_FLG_FORCE_IN1_MANUAL_MODE 0x0040
> -#define DA9063_FLG_FORCE_IN1_AUTO_MODE 0x0080
> -#define DA9063_FLG_FORCE_IN2_MANUAL_MODE 0x0100
> -#define DA9063_FLG_FORCE_IN2_AUTO_MODE 0x0200
> -#define DA9063_FLG_FORCE_IN3_MANUAL_MODE 0x0400
> -#define DA9063_FLG_FORCE_IN3_AUTO_MODE 0x0800
> -
> -/* Disable register caching. */
> -#define DA9063_FLG_NO_CACHE 0x0008
> -
> -struct da9063;
> -
> -/* DA9063 platform data */
> -struct da9063_pdata {
> - int (*init)(struct da9063 *da9063);
> - int irq_base;
> - bool key_power;
> - unsigned flags;
> - struct da9063_regulators_pdata *regulators_pdata;
> - struct led_platform_data *leds_pdata;
> -};
> -
> -#endif /* __MFD_DA9063_PDATA_H__ */
> --
> 2.11.0
>

2019-03-19 13:05:00

by Mark Brown

[permalink] [raw]
Subject: Re: [PATCH 4/6] regulator: da9063: move definitions out of a header into the driver

On Mon, Mar 18, 2019 at 04:47:56PM +0100, Wolfram Sang wrote:
> Those definitions are only used within the driver meanwhile, so put them
> there.

Acked-by: Mark Brown <[email protected]>


Attachments:
(No filename) (194.00 B)
signature.asc (499.00 B)
Download all attachments

2019-03-25 20:23:07

by Wolfram Sang

[permalink] [raw]
Subject: Re: [PATCH 3/6] mfd: da9063: remove platform_data support


> > - if (pdata) {
> > - da9063->flags = pdata->flags;
> > - da9063->irq_base = pdata->irq_base;
> > - } else {
> > - da9063->flags = 0;
> > - da9063->irq_base = -1;
> > - }
> > + da9063->flags = 0;
> > + da9063->irq_base = -1;
>
> If the flag and irq_base fields have fixed values can
> they be removed? As a follow-up?

There is likely more simplification possible. But yes, it should be a
follow up patch, I think.


Attachments:
(No filename) (442.00 B)
signature.asc (849.00 B)
Download all attachments

2019-03-29 10:58:47

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 1/6] regulator: da9063: remove platform_data support

Hi,

On 18 March 2019 15:48, Wolfram Sang wrote:

> Subject: [PATCH 1/6] regulator: da9063: remove platform_data support
>
> There are no in-kernel users anymore, so remove this outdated interface.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> drivers/regulator/da9063-regulator.c | 7 +------
> 1 file changed, 1 insertion(+), 6 deletions(-)

Thanks!
Acked-by: Steve Twiss <[email protected]>
Tested-by: Steve Twiss <[email protected]>

Regards,
Steve

2019-03-29 10:59:06

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 2/6] input: da9063_onkey: remove platform_data support

Hi,

On 18 March 2019 15:48, Wolfram Sang wrote:

> Subject: [PATCH 2/6] input: da9063_onkey: remove platform_data support
>
> There are no in-kernel users anymore, so remove this outdated interface.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> drivers/input/misc/da9063_onkey.c | 11 ++---------
> 1 file changed, 2 insertions(+), 9 deletions(-)

Thanks!
Acked-by: Steve Twiss <[email protected]>
Tested-by: Steve Twiss <[email protected]>

Regards,
Steve

2019-03-29 11:01:20

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 3/6] mfd: da9063: remove platform_data support

Hi,

On 18 March 2019 15:48, Wolfram Sang wrote:
> Subject: [PATCH 3/6] mfd: da9063: remove platform_data support
>
> There are no in-kernel users anymore, so remove this outdated interface.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> drivers/mfd/da9063-core.c | 20 ++------------------
> drivers/mfd/da9063-i2c.c | 1 -
> drivers/mfd/da9063-irq.c | 1 -
> 3 files changed, 2 insertions(+), 20 deletions(-)

Thanks!
Acked-by: Steve Twiss <[email protected]>
Tested-by: Steve Twiss <[email protected]>

Regards,
Steve


2019-03-29 11:01:42

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 4/6] regulator: da9063: move definitions out of a header into the driver

Hi,

On 18 March 2019 15:48, Wolfram Sang wrote:

> Subject: [PATCH 4/6] regulator: da9063: move definitions out of a header into the driver
>
> Those definitions are only used within the driver meanwhile, so put them
> there.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> drivers/regulator/da9063-regulator.c | 44
> +++++++++++++++++++++++++++++++-
> include/linux/mfd/da9063/pdata.h | 49 ------------------------------------
> 2 files changed, 43 insertions(+), 50 deletions(-)
>
> diff --git a/drivers/regulator/da9063-regulator.c b/drivers/regulator/da9063-regulator.c

Thanks!
Acked-by: Steve Twiss <[email protected]>
Tested-by: Steve Twiss <[email protected]>

Regards,
Steve

2019-03-29 11:03:31

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 0/6] mfd: da9063: remove platform_data

Hi,

On 18 March 2019 15:48 Wolfram Sang wrote:

> Subject: [PATCH 0/6] mfd: da9063: remove platform_data
>
> When working with this driver while debugging something else, I noticed that
> there are no in-kernel users of platform_data anymore. Removing the support
> simplifies the code and gets rid of quite some lines. The biggest refactoring
> went to the regulator driver which could maybe benefit from more
> refactorization. However, there is no in-kernel user of that driver, so no
> testing. I left it at this stage. I think the changes are still at a level
> where review and build-testing will give enough confidence.
>
> Besides the regulator thing, it was tested on a Renesas Lager board (R-Car H2).
> No regressions encountered. buildbot was happy, too.
>
> The patches are based on v5.1-rc1. I'd vote for all of them going through the
> MFD tree. Looking forward to comments!
>
> Wolfram

I've acked-by and tested-by for all the patches now. Apologies because it took
such a long time to get around to looking at this.

(For my benefit) I regression tested against v5.0 and v5.1-rc1, ok.

Thanks,
Steve

2019-03-29 11:04:11

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 6/6] regulator: da9063: platform_data is gone, depend on OF

Hi,

On 18 March 2019 15:48, Wolfram Sang wrote:

> Subject: [PATCH 6/6] regulator: da9063: platform_data is gone, depend on OF
>
> With OF being the only configuration possibility left, depend on it to
> simplify some code.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> drivers/regulator/Kconfig | 2 +-
> drivers/regulator/da9063-regulator.c | 10 ----------
> 2 files changed, 1 insertion(+), 11 deletions(-)

Thanks!
Acked-by: Steve Twiss <[email protected]>
Tested-by: Steve Twiss <[email protected]>

Regards,
Steve

2019-03-29 11:04:22

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 5/6] mfd: da9063: remove leftover platform_data definitions

Hi,

On 18 March 2019 15:48 Wolfram Sang wrote:

> Subject: [PATCH 5/6] mfd: da9063: remove leftover platform_data definitions
>
> Not used, not needed, remove them.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> include/linux/mfd/da9063/pdata.h | 65 ----------------------------------------
> 1 file changed, 65 deletions(-)
> delete mode 100644 include/linux/mfd/da9063/pdata.h
>
> diff --git a/include/linux/mfd/da9063/pdata.h

Thanks!
Acked-by: Steve Twiss <[email protected]>
Tested-by: Steve Twiss <[email protected]>

Regards,
Steve

2019-03-29 11:29:00

by Wolfram Sang

[permalink] [raw]
Subject: Re: [PATCH 0/6] mfd: da9063: remove platform_data


> I've acked-by and tested-by for all the patches now. Apologies because it took
> such a long time to get around to looking at this.

Thanks for the testing! I think 10 days is actually quite fast :)


Attachments:
(No filename) (209.00 B)
signature.asc (849.00 B)
Download all attachments

2019-03-29 11:29:23

by Steve Twiss

[permalink] [raw]
Subject: RE: [PATCH 0/6] mfd: da9063: remove platform_data

Caveat.

On 29 March 2019 11:02 Steve Twiss, wrote:

> Subject: RE: [PATCH 0/6] mfd: da9063: remove platform_data
>
[...]
>
> I've acked-by and tested-by for all the patches now. Apologies because it took
> such a long time to get around to looking at this.
>
> (For my benefit) I regression tested against v5.0 and v5.1-rc1, ok.

These were tested with two extra patches that are not in vanilla v5.0 or v5.1.-rc1.

One is in discussion and one is applied to linux-next,
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next-history.git/commit/?id=70b464918e5331e488058870fcc6821d54c4e541

E-mail threads are here:

https://lore.kernel.org/lkml/[email protected]/
https://lore.kernel.org/lkml/[email protected]/

Regards,
Steve


2019-04-03 08:03:19

by Lee Jones

[permalink] [raw]
Subject: Re: [PATCH 3/6] mfd: da9063: remove platform_data support

On Mon, 18 Mar 2019, Wolfram Sang wrote:

> There are no in-kernel users anymore, so remove this outdated interface.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> drivers/mfd/da9063-core.c | 20 ++------------------
> drivers/mfd/da9063-i2c.c | 1 -
> drivers/mfd/da9063-irq.c | 1 -
> 3 files changed, 2 insertions(+), 20 deletions(-)

Applied, thanks.

--
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

2019-04-03 08:11:05

by Lee Jones

[permalink] [raw]
Subject: Re: [PATCH 5/6] mfd: da9063: remove leftover platform_data definitions

On Mon, 18 Mar 2019, Wolfram Sang wrote:

> Not used, not needed, remove them.
>
> Signed-off-by: Wolfram Sang <[email protected]>
> ---
> include/linux/mfd/da9063/pdata.h | 65 ----------------------------------------
> 1 file changed, 65 deletions(-)
> delete mode 100644 include/linux/mfd/da9063/pdata.h

Can't take this until the last user has been removed.

But for now:

For my own reference:
Acked-for-MFD-by: Lee Jones <[email protected]>

--
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

2019-04-03 08:51:45

by Wolfram Sang

[permalink] [raw]
Subject: Re: [PATCH 5/6] mfd: da9063: remove leftover platform_data definitions

On Wed, Apr 03, 2019 at 09:07:58AM +0100, Lee Jones wrote:
> On Mon, 18 Mar 2019, Wolfram Sang wrote:
>
> > Not used, not needed, remove them.
> >
> > Signed-off-by: Wolfram Sang <[email protected]>
> > ---
> > include/linux/mfd/da9063/pdata.h | 65 ----------------------------------------
> > 1 file changed, 65 deletions(-)
> > delete mode 100644 include/linux/mfd/da9063/pdata.h
>
> Can't take this until the last user has been removed.
>
> But for now:
>
> For my own reference:
> Acked-for-MFD-by: Lee Jones <[email protected]>

As I wrote in the cover-letter, I'd vote for all patches going in via
MFD. Is that fine with you? Then I'll ping other maintainers for acks.


Attachments:
(No filename) (725.00 B)
signature.asc (849.00 B)
Download all attachments

2019-04-03 09:05:55

by Lee Jones

[permalink] [raw]
Subject: Re: [PATCH 5/6] mfd: da9063: remove leftover platform_data definitions

On Wed, 03 Apr 2019, Wolfram Sang wrote:

> On Wed, Apr 03, 2019 at 09:07:58AM +0100, Lee Jones wrote:
> > On Mon, 18 Mar 2019, Wolfram Sang wrote:
> >
> > > Not used, not needed, remove them.
> > >
> > > Signed-off-by: Wolfram Sang <[email protected]>
> > > ---
> > > include/linux/mfd/da9063/pdata.h | 65 ----------------------------------------
> > > 1 file changed, 65 deletions(-)
> > > delete mode 100644 include/linux/mfd/da9063/pdata.h
> >
> > Can't take this until the last user has been removed.
> >
> > But for now:
> >
> > For my own reference:
> > Acked-for-MFD-by: Lee Jones <[email protected]>
>
> As I wrote in the cover-letter, I'd vote for all patches going in via
> MFD. Is that fine with you? Then I'll ping other maintainers for acks.

That's fine by me too.

--
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

2019-04-03 09:23:52

by Wolfram Sang

[permalink] [raw]
Subject: Re: [PATCH 4/6] regulator: da9063: move definitions out of a header into the driver

On Tue, Mar 19, 2019 at 01:01:34PM +0000, Mark Brown wrote:
> On Mon, Mar 18, 2019 at 04:47:56PM +0100, Wolfram Sang wrote:
> > Those definitions are only used within the driver meanwhile, so put them
> > there.
>
> Acked-by: Mark Brown <[email protected]>

Mark, if you are OK with all the patches going in via MFD, could you ack
the other regulator patches, too? Steve is fine with the patches and
tested them, too.


Attachments:
(No filename) (432.00 B)
signature.asc (849.00 B)
Download all attachments

2019-04-03 09:26:48

by Wolfram Sang

[permalink] [raw]
Subject: Re: [PATCH 2/6] input: da9063_onkey: remove platform_data support


> > Subject: [PATCH 2/6] input: da9063_onkey: remove platform_data support
> >
> > There are no in-kernel users anymore, so remove this outdated interface.
> >
> > Signed-off-by: Wolfram Sang <[email protected]>
> > ---
> > drivers/input/misc/da9063_onkey.c | 11 ++---------
> > 1 file changed, 2 insertions(+), 9 deletions(-)
>
> Thanks!
> Acked-by: Steve Twiss <[email protected]>
> Tested-by: Steve Twiss <[email protected]>

Dmitry, if you are OK with the series going in via MFD, could you ack
this patch? As you see, Steve is fine with the patch and tested it, too.


Attachments:
(No filename) (635.00 B)
signature.asc (849.00 B)
Download all attachments

2019-04-03 10:08:28

by Mark Brown

[permalink] [raw]
Subject: Re: [PATCH 4/6] regulator: da9063: move definitions out of a header into the driver

On Wed, Apr 03, 2019 at 11:22:30AM +0200, Wolfram Sang wrote:

> Mark, if you are OK with all the patches going in via MFD, could you ack
> the other regulator patches, too? Steve is fine with the patches and
> tested them, too.

I don't recall any more patches, sorry. Probably they're fine because
the whole series looked straightforward enough so I guess.

Acked-by: Mark Brown <[email protected]>


Attachments:
(No filename) (413.00 B)
signature.asc (499.00 B)
Download all attachments