linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/4] ARM: dts: s5pv210: Enable cpufreq support
@ 2019-01-10 20:52 Paweł Chmiel
  2019-01-10 20:52 ` [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes Paweł Chmiel
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Paweł Chmiel @ 2019-01-10 20:52 UTC (permalink / raw)
  To: kgene
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm,
	viresh.kumar, rjw, linux, krzk, linux-kernel, robh+dt,
	linux-arm-kernel, Paweł Chmiel

This patchset enables cpufreq support using s5pv210-cpufreq driver.

First patch adds missing dmc nodes, which are required by driver.

Second patch is cosmetic, it stops driver from flooding kernel log with
 messages, after every change of freq.

Third patch adds defer probe support for regulators, needed by driver.
It was observed, that those regulators can be no yet initialized, when
 driver is probed, so we should wait till we can get them.

Last patch enables required kernel config options.

Changes from v1:
  - Added Acked-by to one of patches
  - Fix compilation error after changes in driver
  - Reorganize code (so it's smaller), inside patch which logs information
    about defered probe of regulators

Paweł Chmiel (4):
  ARM: dts: s5pv210: Add dmc nodes
  cpufreq: s5pv210: Don't flood kernel log after cpufreq change
  cpufreq: s5pv210: Defer probe if getting regulators fail
  ARM: defconfig: s5pv210: Add cpufreq support

 arch/arm/boot/dts/s5pv210.dtsi     | 12 +++++++++++
 arch/arm/configs/s5pv210_defconfig |  6 ++++++
 drivers/cpufreq/s5pv210-cpufreq.c  | 34 ++++++++++++++++++------------
 3 files changed, 38 insertions(+), 14 deletions(-)

-- 
2.17.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes
  2019-01-10 20:52 [PATCH v2 0/4] ARM: dts: s5pv210: Enable cpufreq support Paweł Chmiel
@ 2019-01-10 20:52 ` Paweł Chmiel
  2019-01-11  8:32   ` Krzysztof Kozlowski
  2019-01-10 20:52 ` [PATCH v2 2/4] cpufreq: s5pv210: Don't flood kernel log after cpufreq change Paweł Chmiel
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 11+ messages in thread
From: Paweł Chmiel @ 2019-01-10 20:52 UTC (permalink / raw)
  To: kgene
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm,
	viresh.kumar, rjw, linux, krzk, linux-kernel, robh+dt,
	linux-arm-kernel, Paweł Chmiel

This commit adds dmc nodes, which are needed by s5pv210 cpufreq driver
to work.

Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
---
 arch/arm/boot/dts/s5pv210.dtsi | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/arch/arm/boot/dts/s5pv210.dtsi b/arch/arm/boot/dts/s5pv210.dtsi
index e9613418228d..2d55a3a6e79e 100644
--- a/arch/arm/boot/dts/s5pv210.dtsi
+++ b/arch/arm/boot/dts/s5pv210.dtsi
@@ -25,6 +25,8 @@
 
 	aliases {
 		csis0 = &csis0;
+		dmc0 = &dmc0;
+		dmc1 = &dmc1;
 		fimc0 = &fimc0;
 		fimc1 = &fimc1;
 		fimc2 = &fimc2;
@@ -521,6 +523,16 @@
 			status = "disabled";
 		};
 
+		dmc0: dmc@f0000000 {
+			compatible = "samsung,s5pv210-dmc";
+			reg = <0xf0000000 0x1000>;
+		};
+
+		dmc1: dmc@f1400000 {
+			compatible = "samsung,s5pv210-dmc";
+			reg = <0xf1400000 0x1000>;
+		};
+
 		g2d: g2d@fa000000 {
 			compatible = "samsung,s5pv210-g2d";
 			reg = <0xfa000000 0x1000>;
-- 
2.17.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH v2 2/4] cpufreq: s5pv210: Don't flood kernel log after cpufreq change
  2019-01-10 20:52 [PATCH v2 0/4] ARM: dts: s5pv210: Enable cpufreq support Paweł Chmiel
  2019-01-10 20:52 ` [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes Paweł Chmiel
@ 2019-01-10 20:52 ` Paweł Chmiel
  2019-01-10 20:52 ` [PATCH v2 3/4] cpufreq: s5pv210: Defer probe if getting regulators fail Paweł Chmiel
  2019-01-10 20:52 ` [PATCH v2 4/4] ARM: defconfig: s5pv210: Add cpufreq support Paweł Chmiel
  3 siblings, 0 replies; 11+ messages in thread
From: Paweł Chmiel @ 2019-01-10 20:52 UTC (permalink / raw)
  To: kgene
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm,
	viresh.kumar, rjw, linux, krzk, linux-kernel, robh+dt,
	linux-arm-kernel, Paweł Chmiel

This commit replaces printk with pr_debug, so we don't flood kernel log.

Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
Acked-by: Krzysztof Kozlowski <krzk@kernel.org>
---
Changes from v1:
  - Added Acked-by
---
 drivers/cpufreq/s5pv210-cpufreq.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/cpufreq/s5pv210-cpufreq.c b/drivers/cpufreq/s5pv210-cpufreq.c
index dbecd7667db2..f51697f1e0b3 100644
--- a/drivers/cpufreq/s5pv210-cpufreq.c
+++ b/drivers/cpufreq/s5pv210-cpufreq.c
@@ -481,7 +481,7 @@ static int s5pv210_target(struct cpufreq_policy *policy, unsigned int index)
 				arm_volt, arm_volt_max);
 	}
 
-	printk(KERN_DEBUG "Perf changed[L%d]\n", index);
+	pr_debug("Perf changed[L%d]\n", index);
 
 exit:
 	mutex_unlock(&set_freq_lock);
-- 
2.17.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH v2 3/4] cpufreq: s5pv210: Defer probe if getting regulators fail
  2019-01-10 20:52 [PATCH v2 0/4] ARM: dts: s5pv210: Enable cpufreq support Paweł Chmiel
  2019-01-10 20:52 ` [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes Paweł Chmiel
  2019-01-10 20:52 ` [PATCH v2 2/4] cpufreq: s5pv210: Don't flood kernel log after cpufreq change Paweł Chmiel
@ 2019-01-10 20:52 ` Paweł Chmiel
  2019-01-11  9:46   ` Krzysztof Kozlowski
  2019-01-10 20:52 ` [PATCH v2 4/4] ARM: defconfig: s5pv210: Add cpufreq support Paweł Chmiel
  3 siblings, 1 reply; 11+ messages in thread
From: Paweł Chmiel @ 2019-01-10 20:52 UTC (permalink / raw)
  To: kgene
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm,
	viresh.kumar, rjw, linux, krzk, linux-kernel, robh+dt,
	linux-arm-kernel, Paweł Chmiel

There is possibility, that when probing driver, regulators are not yet
initialized. In this case we should return EPROBE_DEFER and wait till
they're initialized, since they're required currently for cpufreq driver
to work. Also move regulator initialization code at beginning of probe,
so we can defer as fast as posibble.

Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
---
Changes from v1:
  - Fix compilation error
  - Reorganize code so it's smaller
---
 drivers/cpufreq/s5pv210-cpufreq.c | 32 ++++++++++++++++++-------------
 1 file changed, 19 insertions(+), 13 deletions(-)

diff --git a/drivers/cpufreq/s5pv210-cpufreq.c b/drivers/cpufreq/s5pv210-cpufreq.c
index f51697f1e0b3..6df95941ba96 100644
--- a/drivers/cpufreq/s5pv210-cpufreq.c
+++ b/drivers/cpufreq/s5pv210-cpufreq.c
@@ -594,6 +594,25 @@ static int s5pv210_cpufreq_probe(struct platform_device *pdev)
 	 * this whole driver as soon as S5PV210 gets migrated to use
 	 * cpufreq-dt driver.
 	 */
+	arm_regulator = regulator_get(NULL, "vddarm");
+	if (IS_ERR(arm_regulator)) {
+		if (PTR_ERR(arm_regulator) == -EPROBE_DEFER)
+			pr_debug("vddarm regulator not ready, defer\n");
+		else
+			pr_err("failed to get regulator vddarm\n");
+		return PTR_ERR(arm_regulator);
+	}
+
+	int_regulator = regulator_get(NULL, "vddint");
+	if (IS_ERR(int_regulator)) {
+		if (PTR_ERR(int_regulator) == -EPROBE_DEFER)
+			pr_debug("vddint regulator not ready, defer\n");
+		else
+			pr_err("failed to get regulator vddint\n");
+		regulator_put(arm_regulator);
+		return PTR_ERR(int_regulator);
+	}
+
 	np = of_find_compatible_node(NULL, NULL, "samsung,s5pv210-clock");
 	if (!np) {
 		pr_err("%s: failed to find clock controller DT node\n",
@@ -633,19 +652,6 @@ static int s5pv210_cpufreq_probe(struct platform_device *pdev)
 		}
 	}
 
-	arm_regulator = regulator_get(NULL, "vddarm");
-	if (IS_ERR(arm_regulator)) {
-		pr_err("failed to get regulator vddarm\n");
-		return PTR_ERR(arm_regulator);
-	}
-
-	int_regulator = regulator_get(NULL, "vddint");
-	if (IS_ERR(int_regulator)) {
-		pr_err("failed to get regulator vddint\n");
-		regulator_put(arm_regulator);
-		return PTR_ERR(int_regulator);
-	}
-
 	register_reboot_notifier(&s5pv210_cpufreq_reboot_notifier);
 
 	return cpufreq_register_driver(&s5pv210_driver);
-- 
2.17.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH v2 4/4] ARM: defconfig: s5pv210: Add cpufreq support
  2019-01-10 20:52 [PATCH v2 0/4] ARM: dts: s5pv210: Enable cpufreq support Paweł Chmiel
                   ` (2 preceding siblings ...)
  2019-01-10 20:52 ` [PATCH v2 3/4] cpufreq: s5pv210: Defer probe if getting regulators fail Paweł Chmiel
@ 2019-01-10 20:52 ` Paweł Chmiel
  2019-01-13  9:34   ` Krzysztof Kozlowski
  3 siblings, 1 reply; 11+ messages in thread
From: Paweł Chmiel @ 2019-01-10 20:52 UTC (permalink / raw)
  To: kgene
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm,
	viresh.kumar, rjw, linux, krzk, linux-kernel, robh+dt,
	linux-arm-kernel, Paweł Chmiel

This commit enables cpufreq support for all s5pv210 devices.

Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
---
 arch/arm/configs/s5pv210_defconfig | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/arm/configs/s5pv210_defconfig b/arch/arm/configs/s5pv210_defconfig
index 951196bdf008..fd4f28aabda6 100644
--- a/arch/arm/configs/s5pv210_defconfig
+++ b/arch/arm/configs/s5pv210_defconfig
@@ -11,6 +11,12 @@ CONFIG_ARCH_S5PV210=y
 CONFIG_VMSPLIT_2G=y
 CONFIG_ARM_APPENDED_DTB=y
 CONFIG_CMDLINE="root=/dev/ram0 rw ramdisk=8192 initrd=0x20800000,8M console=ttySAC1,115200 init=/linuxrc"
+CONFIG_CPU_FREQ=y
+CONFIG_CPU_FREQ_STAT=y
+CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND=y
+CONFIG_CPU_FREQ_GOV_POWERSAVE=m
+CONFIG_CPU_FREQ_GOV_USERSPACE=m
+CONFIG_CPU_FREQ_GOV_CONSERVATIVE=m
 CONFIG_VFP=y
 CONFIG_NEON=y
 CONFIG_MODULES=y
-- 
2.17.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes
  2019-01-10 20:52 ` [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes Paweł Chmiel
@ 2019-01-11  8:32   ` Krzysztof Kozlowski
  2019-01-11  9:41     ` Viresh Kumar
  0 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2019-01-11  8:32 UTC (permalink / raw)
  To: Paweł Chmiel
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm,
	viresh.kumar, rjw, linux, robh+dt, linux-kernel, kgene,
	linux-arm-kernel

On Thu, 10 Jan 2019 at 21:53, Paweł Chmiel
<pawel.mikolaj.chmiel@gmail.com> wrote:
>
> This commit adds dmc nodes, which are needed by s5pv210 cpufreq driver
> to work.
>
> Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
> ---
>  arch/arm/boot/dts/s5pv210.dtsi | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
>

Thanks, applied (actually I applied v1 - I hope there were no changes).

Best regards,
Krzysztof

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes
  2019-01-11  8:32   ` Krzysztof Kozlowski
@ 2019-01-11  9:41     ` Viresh Kumar
  2019-01-11  9:47       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 11+ messages in thread
From: Viresh Kumar @ 2019-01-11  9:41 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm, rjw,
	linux, robh+dt, linux-kernel, kgene, linux-arm-kernel,
	Paweł Chmiel

On 11-01-19, 09:32, Krzysztof Kozlowski wrote:
> On Thu, 10 Jan 2019 at 21:53, Paweł Chmiel
> <pawel.mikolaj.chmiel@gmail.com> wrote:
> >
> > This commit adds dmc nodes, which are needed by s5pv210 cpufreq driver
> > to work.
> >
> > Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
> > ---
> >  arch/arm/boot/dts/s5pv210.dtsi | 12 ++++++++++++
> >  1 file changed, 12 insertions(+)
> >
> 
> Thanks, applied (actually I applied v1 - I hope there were no changes).

Would you like to Ack the other patches so that I can apply them ?

-- 
viresh

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH v2 3/4] cpufreq: s5pv210: Defer probe if getting regulators fail
  2019-01-10 20:52 ` [PATCH v2 3/4] cpufreq: s5pv210: Defer probe if getting regulators fail Paweł Chmiel
@ 2019-01-11  9:46   ` Krzysztof Kozlowski
  2019-01-11  9:53     ` Paweł Chmiel
  0 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2019-01-11  9:46 UTC (permalink / raw)
  To: Paweł Chmiel
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm,
	viresh.kumar, rjw, linux, robh+dt, linux-kernel, kgene,
	linux-arm-kernel

On Thu, 10 Jan 2019 at 21:53, Paweł Chmiel
<pawel.mikolaj.chmiel@gmail.com> wrote:
>
> There is possibility, that when probing driver, regulators are not yet
> initialized. In this case we should return EPROBE_DEFER and wait till
> they're initialized, since they're required currently for cpufreq driver
> to work. Also move regulator initialization code at beginning of probe,
> so we can defer as fast as posibble.
>
> Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
> ---
> Changes from v1:
>   - Fix compilation error
>   - Reorganize code so it's smaller
> ---
>  drivers/cpufreq/s5pv210-cpufreq.c | 32 ++++++++++++++++++-------------
>  1 file changed, 19 insertions(+), 13 deletions(-)
>
> diff --git a/drivers/cpufreq/s5pv210-cpufreq.c b/drivers/cpufreq/s5pv210-cpufreq.c
> index f51697f1e0b3..6df95941ba96 100644
> --- a/drivers/cpufreq/s5pv210-cpufreq.c
> +++ b/drivers/cpufreq/s5pv210-cpufreq.c
> @@ -594,6 +594,25 @@ static int s5pv210_cpufreq_probe(struct platform_device *pdev)
>          * this whole driver as soon as S5PV210 gets migrated to use
>          * cpufreq-dt driver.
>          */
> +       arm_regulator = regulator_get(NULL, "vddarm");
> +       if (IS_ERR(arm_regulator)) {
> +               if (PTR_ERR(arm_regulator) == -EPROBE_DEFER)
> +                       pr_debug("vddarm regulator not ready, defer\n");
> +               else
> +                       pr_err("failed to get regulator vddarm\n");
> +               return PTR_ERR(arm_regulator);
> +       }
> +
> +       int_regulator = regulator_get(NULL, "vddint");
> +       if (IS_ERR(int_regulator)) {
> +               if (PTR_ERR(int_regulator) == -EPROBE_DEFER)
> +                       pr_debug("vddint regulator not ready, defer\n");
> +               else
> +                       pr_err("failed to get regulator vddint\n");
> +               regulator_put(arm_regulator);
> +               return PTR_ERR(int_regulator);
> +       }
> +

Error paths are now not correct. You should put the regulators when
returning later. The previous code had these error paths wrong as well
- not iounmapping - but if you move things around, maybe let's fix
things.

Best regards,
Krzysztof

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes
  2019-01-11  9:41     ` Viresh Kumar
@ 2019-01-11  9:47       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 11+ messages in thread
From: Krzysztof Kozlowski @ 2019-01-11  9:47 UTC (permalink / raw)
  To: Viresh Kumar
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm, rjw,
	linux, robh+dt, linux-kernel, kgene, linux-arm-kernel,
	Paweł Chmiel

On Fri, 11 Jan 2019 at 10:41, Viresh Kumar <viresh.kumar@linaro.org> wrote:
>
> On 11-01-19, 09:32, Krzysztof Kozlowski wrote:
> > On Thu, 10 Jan 2019 at 21:53, Paweł Chmiel
> > <pawel.mikolaj.chmiel@gmail.com> wrote:
> > >
> > > This commit adds dmc nodes, which are needed by s5pv210 cpufreq driver
> > > to work.
> > >
> > > Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
> > > ---
> > >  arch/arm/boot/dts/s5pv210.dtsi | 12 ++++++++++++
> > >  1 file changed, 12 insertions(+)
> > >
> >
> > Thanks, applied (actually I applied v1 - I hope there were no changes).
>
> Would you like to Ack the other patches so that I can apply them ?

Sure, let me take a look. Anyway, I will take patch 4/4 (defconfig). I
left it for later because of ongoing discussion.

Best regards,
Krzysztof

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH v2 3/4] cpufreq: s5pv210: Defer probe if getting regulators fail
  2019-01-11  9:46   ` Krzysztof Kozlowski
@ 2019-01-11  9:53     ` Paweł Chmiel
  0 siblings, 0 replies; 11+ messages in thread
From: Paweł Chmiel @ 2019-01-11  9:53 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Mark Rutland, DTML, linux-samsung-soc, linux-pm, Viresh Kumar,
	rjw, linux, Rob Herring, linux-kernel, Kukjin Kim,
	linux-arm-kernel

pt., 11 sty 2019 o 10:46 Krzysztof Kozlowski <krzk@kernel.org> napisał(a):
>
> On Thu, 10 Jan 2019 at 21:53, Paweł Chmiel
> <pawel.mikolaj.chmiel@gmail.com> wrote:
> >
> > There is possibility, that when probing driver, regulators are not yet
> > initialized. In this case we should return EPROBE_DEFER and wait till
> > they're initialized, since they're required currently for cpufreq driver
> > to work. Also move regulator initialization code at beginning of probe,
> > so we can defer as fast as posibble.
> >
> > Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
> > ---
> > Changes from v1:
> >   - Fix compilation error
> >   - Reorganize code so it's smaller
> > ---
> >  drivers/cpufreq/s5pv210-cpufreq.c | 32 ++++++++++++++++++-------------
> >  1 file changed, 19 insertions(+), 13 deletions(-)
> >
> > diff --git a/drivers/cpufreq/s5pv210-cpufreq.c b/drivers/cpufreq/s5pv210-cpufreq.c
> > index f51697f1e0b3..6df95941ba96 100644
> > --- a/drivers/cpufreq/s5pv210-cpufreq.c
> > +++ b/drivers/cpufreq/s5pv210-cpufreq.c
> > @@ -594,6 +594,25 @@ static int s5pv210_cpufreq_probe(struct platform_device *pdev)
> >          * this whole driver as soon as S5PV210 gets migrated to use
> >          * cpufreq-dt driver.
> >          */
> > +       arm_regulator = regulator_get(NULL, "vddarm");
> > +       if (IS_ERR(arm_regulator)) {
> > +               if (PTR_ERR(arm_regulator) == -EPROBE_DEFER)
> > +                       pr_debug("vddarm regulator not ready, defer\n");
> > +               else
> > +                       pr_err("failed to get regulator vddarm\n");
> > +               return PTR_ERR(arm_regulator);
> > +       }
> > +
> > +       int_regulator = regulator_get(NULL, "vddint");
> > +       if (IS_ERR(int_regulator)) {
> > +               if (PTR_ERR(int_regulator) == -EPROBE_DEFER)
> > +                       pr_debug("vddint regulator not ready, defer\n");
> > +               else
> > +                       pr_err("failed to get regulator vddint\n");
> > +               regulator_put(arm_regulator);
> > +               return PTR_ERR(int_regulator);
> > +       }
> > +
>
> Error paths are now not correct. You should put the regulators when
> returning later. The previous code had these error paths wrong as well
> - not iounmapping - but if you move things around, maybe let's fix
> things.
Ok, will fix this in new version and will resend it (only this one
patch, since all other looks ok/applied).
Also will add missing iounmapping/etc to fix all other error paths.

Thanks
>
> Best regards,
> Krzysztof

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH v2 4/4] ARM: defconfig: s5pv210: Add cpufreq support
  2019-01-10 20:52 ` [PATCH v2 4/4] ARM: defconfig: s5pv210: Add cpufreq support Paweł Chmiel
@ 2019-01-13  9:34   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 11+ messages in thread
From: Krzysztof Kozlowski @ 2019-01-13  9:34 UTC (permalink / raw)
  To: Paweł Chmiel
  Cc: mark.rutland, devicetree, linux-samsung-soc, linux-pm,
	viresh.kumar, rjw, linux, robh+dt, linux-kernel, kgene,
	linux-arm-kernel

On Thu, Jan 10, 2019 at 09:52:15PM +0100, Paweł Chmiel wrote:
> This commit enables cpufreq support for all s5pv210 devices.
> 
> Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
> ---
>  arch/arm/configs/s5pv210_defconfig | 6 ++++++

Thanks, applied.

Best regards,
Krzysztof


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2019-01-13  9:34 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-10 20:52 [PATCH v2 0/4] ARM: dts: s5pv210: Enable cpufreq support Paweł Chmiel
2019-01-10 20:52 ` [PATCH v2 1/4] ARM: dts: s5pv210: Add dmc nodes Paweł Chmiel
2019-01-11  8:32   ` Krzysztof Kozlowski
2019-01-11  9:41     ` Viresh Kumar
2019-01-11  9:47       ` Krzysztof Kozlowski
2019-01-10 20:52 ` [PATCH v2 2/4] cpufreq: s5pv210: Don't flood kernel log after cpufreq change Paweł Chmiel
2019-01-10 20:52 ` [PATCH v2 3/4] cpufreq: s5pv210: Defer probe if getting regulators fail Paweł Chmiel
2019-01-11  9:46   ` Krzysztof Kozlowski
2019-01-11  9:53     ` Paweł Chmiel
2019-01-10 20:52 ` [PATCH v2 4/4] ARM: defconfig: s5pv210: Add cpufreq support Paweł Chmiel
2019-01-13  9:34   ` Krzysztof Kozlowski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).