* [PATCH v3 0/2] mfd: sec: Add support for the RTC on S2MPA01
@ 2019-02-13 22:24 Stuart Menefy
2019-02-13 22:24 ` [PATCH v3 1/2] mfd: sec: Put one element structure initialisation on one line Stuart Menefy
2019-02-13 22:24 ` [PATCH v3 2/2] mfd: sec: Add support for the RTC on S2MPA01 Stuart Menefy
0 siblings, 2 replies; 5+ messages in thread
From: Stuart Menefy @ 2019-02-13 22:24 UTC (permalink / raw)
To: Sangbeom Kim, Krzysztof Kozlowski, Bartlomiej Zolnierkiewicz,
Lee Jones, linux-kernel, linux-samsung-soc
Cc: Stuart Menefy
Add the RTC on the S2MPA01. As this is appears to be identical to the
RTC on the S2MPS14 we can use the existing code.
Before we can do that however tidy up the existing code as requested by
Lee:
https://lore.kernel.org/lkml/20190213072458.GB1863@dell/
Changes since v2:
- Add patch tidying up existing one element structure initialisation
- Rebase patch 2/2
Changes since v1:
- Remove the duplicated code and simply declare the RTC to be the same
as that on the S2MPS14.
Stuart Menefy (2):
mfd: sec: Put one element structure initialisation on one line
mfd: sec: Add support for the RTC on S2MPA01
drivers/mfd/sec-core.c | 59 +++++++++++++++++---------------------------------
drivers/mfd/sec-irq.c | 3 +++
2 files changed, 23 insertions(+), 39 deletions(-)
--
2.13.6
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v3 1/2] mfd: sec: Put one element structure initialisation on one line
2019-02-13 22:24 [PATCH v3 0/2] mfd: sec: Add support for the RTC on S2MPA01 Stuart Menefy
@ 2019-02-13 22:24 ` Stuart Menefy
2019-03-20 9:58 ` Lee Jones
2019-02-13 22:24 ` [PATCH v3 2/2] mfd: sec: Add support for the RTC on S2MPA01 Stuart Menefy
1 sibling, 1 reply; 5+ messages in thread
From: Stuart Menefy @ 2019-02-13 22:24 UTC (permalink / raw)
To: Sangbeom Kim, Krzysztof Kozlowski, Bartlomiej Zolnierkiewicz,
Lee Jones, linux-kernel, linux-samsung-soc
Cc: Stuart Menefy
Change the layout of the initialisation of structures with one
element to a single line of code. This keeps the coding style
consistent.
Signed-off-by: Stuart Menefy <stuart.menefy@mathembedded.com>
---
drivers/mfd/sec-core.c | 58 +++++++++++++++++---------------------------------
1 file changed, 19 insertions(+), 39 deletions(-)
diff --git a/drivers/mfd/sec-core.c b/drivers/mfd/sec-core.c
index e0835c9df7a1..5ff3fd726f9e 100644
--- a/drivers/mfd/sec-core.c
+++ b/drivers/mfd/sec-core.c
@@ -28,45 +28,33 @@
#include <linux/regmap.h>
static const struct mfd_cell s5m8751_devs[] = {
- {
- .name = "s5m8751-pmic",
- }, {
- .name = "s5m-charger",
- }, {
- .name = "s5m8751-codec",
- },
+ { .name = "s5m8751-pmic", },
+ { .name = "s5m-charger", },
+ { .name = "s5m8751-codec", },
};
static const struct mfd_cell s5m8763_devs[] = {
- {
- .name = "s5m8763-pmic",
- }, {
- .name = "s5m-rtc",
- }, {
- .name = "s5m-charger",
- },
+ { .name = "s5m8763-pmic", },
+ { .name = "s5m-rtc", },
+ { .name = "s5m-charger", },
};
static const struct mfd_cell s5m8767_devs[] = {
+ { .name = "s5m8767-pmic", },
+ { .name = "s5m-rtc", },
{
- .name = "s5m8767-pmic",
- }, {
- .name = "s5m-rtc",
- }, {
.name = "s5m8767-clk",
.of_compatible = "samsung,s5m8767-clk",
- }
+ },
};
static const struct mfd_cell s2mps11_devs[] = {
+ { .name = "s2mps11-regulator", },
+ { .name = "s2mps14-rtc", },
{
- .name = "s2mps11-regulator",
- }, {
- .name = "s2mps14-rtc",
- }, {
.name = "s2mps11-clk",
.of_compatible = "samsung,s2mps11-clk",
- }
+ },
};
static const struct mfd_cell s2mps13_devs[] = {
@@ -79,37 +67,29 @@ static const struct mfd_cell s2mps13_devs[] = {
};
static const struct mfd_cell s2mps14_devs[] = {
+ { .name = "s2mps14-regulator", },
+ { .name = "s2mps14-rtc", },
{
- .name = "s2mps14-regulator",
- }, {
- .name = "s2mps14-rtc",
- }, {
.name = "s2mps14-clk",
.of_compatible = "samsung,s2mps14-clk",
- }
+ },
};
static const struct mfd_cell s2mps15_devs[] = {
+ { .name = "s2mps15-regulator", },
+ { .name = "s2mps15-rtc", },
{
- .name = "s2mps15-regulator",
- }, {
- .name = "s2mps15-rtc",
- }, {
.name = "s2mps13-clk",
.of_compatible = "samsung,s2mps13-clk",
},
};
static const struct mfd_cell s2mpa01_devs[] = {
- {
- .name = "s2mpa01-pmic",
- },
+ { .name = "s2mpa01-pmic", },
};
static const struct mfd_cell s2mpu02_devs[] = {
- {
- .name = "s2mpu02-regulator",
- },
+ { .name = "s2mpu02-regulator", },
};
#ifdef CONFIG_OF
--
2.13.6
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH v3 2/2] mfd: sec: Add support for the RTC on S2MPA01
2019-02-13 22:24 [PATCH v3 0/2] mfd: sec: Add support for the RTC on S2MPA01 Stuart Menefy
2019-02-13 22:24 ` [PATCH v3 1/2] mfd: sec: Put one element structure initialisation on one line Stuart Menefy
@ 2019-02-13 22:24 ` Stuart Menefy
2019-03-20 10:01 ` Lee Jones
1 sibling, 1 reply; 5+ messages in thread
From: Stuart Menefy @ 2019-02-13 22:24 UTC (permalink / raw)
To: Sangbeom Kim, Krzysztof Kozlowski, Bartlomiej Zolnierkiewicz,
Lee Jones, linux-kernel, linux-samsung-soc
Cc: Stuart Menefy
The RTC portion of the S2MPA01 appears to have the same
register layout as the S2MPS14.
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Stuart Menefy <stuart.menefy@mathembedded.com>
---
drivers/mfd/sec-core.c | 1 +
drivers/mfd/sec-irq.c | 3 +++
2 files changed, 4 insertions(+)
diff --git a/drivers/mfd/sec-core.c b/drivers/mfd/sec-core.c
index 5ff3fd726f9e..8a299080cb55 100644
--- a/drivers/mfd/sec-core.c
+++ b/drivers/mfd/sec-core.c
@@ -86,6 +86,7 @@ static const struct mfd_cell s2mps15_devs[] = {
static const struct mfd_cell s2mpa01_devs[] = {
{ .name = "s2mpa01-pmic", },
+ { .name = "s2mps14-rtc", },
};
static const struct mfd_cell s2mpu02_devs[] = {
diff --git a/drivers/mfd/sec-irq.c b/drivers/mfd/sec-irq.c
index ad0099077e7e..a98c5d165039 100644
--- a/drivers/mfd/sec-irq.c
+++ b/drivers/mfd/sec-irq.c
@@ -455,6 +455,9 @@ int sec_irq_init(struct sec_pmic_dev *sec_pmic)
case S5M8767X:
sec_irq_chip = &s5m8767_irq_chip;
break;
+ case S2MPA01:
+ sec_irq_chip = &s2mps14_irq_chip;
+ break;
case S2MPS11X:
sec_irq_chip = &s2mps11_irq_chip;
break;
--
2.13.6
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v3 1/2] mfd: sec: Put one element structure initialisation on one line
2019-02-13 22:24 ` [PATCH v3 1/2] mfd: sec: Put one element structure initialisation on one line Stuart Menefy
@ 2019-03-20 9:58 ` Lee Jones
0 siblings, 0 replies; 5+ messages in thread
From: Lee Jones @ 2019-03-20 9:58 UTC (permalink / raw)
To: Stuart Menefy
Cc: Sangbeom Kim, Krzysztof Kozlowski, Bartlomiej Zolnierkiewicz,
linux-kernel, linux-samsung-soc
On Wed, 13 Feb 2019, Stuart Menefy wrote:
> Change the layout of the initialisation of structures with one
> element to a single line of code. This keeps the coding style
> consistent.
>
> Signed-off-by: Stuart Menefy <stuart.menefy@mathembedded.com>
> ---
> drivers/mfd/sec-core.c | 58 +++++++++++++++++---------------------------------
> 1 file changed, 19 insertions(+), 39 deletions(-)
Applied, thanks.
--
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v3 2/2] mfd: sec: Add support for the RTC on S2MPA01
2019-02-13 22:24 ` [PATCH v3 2/2] mfd: sec: Add support for the RTC on S2MPA01 Stuart Menefy
@ 2019-03-20 10:01 ` Lee Jones
0 siblings, 0 replies; 5+ messages in thread
From: Lee Jones @ 2019-03-20 10:01 UTC (permalink / raw)
To: Stuart Menefy
Cc: Sangbeom Kim, Krzysztof Kozlowski, Bartlomiej Zolnierkiewicz,
linux-kernel, linux-samsung-soc
On Wed, 13 Feb 2019, Stuart Menefy wrote:
> The RTC portion of the S2MPA01 appears to have the same
> register layout as the S2MPS14.
>
> Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
> Signed-off-by: Stuart Menefy <stuart.menefy@mathembedded.com>
Tags should be in chronological order.
That way they can give us more information about the submission path.
I'll fix this.
Applied, thanks.
--
Lee Jones [李琼斯]
Linaro Services Technical Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2019-03-20 10:01 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-13 22:24 [PATCH v3 0/2] mfd: sec: Add support for the RTC on S2MPA01 Stuart Menefy
2019-02-13 22:24 ` [PATCH v3 1/2] mfd: sec: Put one element structure initialisation on one line Stuart Menefy
2019-03-20 9:58 ` Lee Jones
2019-02-13 22:24 ` [PATCH v3 2/2] mfd: sec: Add support for the RTC on S2MPA01 Stuart Menefy
2019-03-20 10:01 ` Lee Jones
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox