* [PATCH v3 0/2] regulator: Fix pbias regulator enable
@ 2015-09-04 12:00 Kishon Vijay Abraham I
2015-09-04 12:00 ` [PATCH v3 2/2] ARM: dts: <omap2/3/4/5/dra7>: use "ti,pbias-<platform>" compatible string for pbias Kishon Vijay Abraham I
[not found] ` <1441368025-21182-1-git-send-email-kishon-l0cyMroinI0@public.gmane.org>
0 siblings, 2 replies; 7+ messages in thread
From: Kishon Vijay Abraham I @ 2015-09-04 12:00 UTC (permalink / raw)
To: tony-4v6yS6AI5VpBDgjK7y7TUQ, broonie-DgEjT+Ai2ygdnm+yROfE0A,
devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-mmc-u79uwXL29TY76Z2rM5mHXA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA
Cc: ulf.hansson-QSEj5FYQhm4dnm+yROfE0A,
robh+dt-DgEjT+Ai2ygdnm+yROfE0A, pawel.moll-5wv7dgnIgG8,
mark.rutland-5wv7dgnIgG8, ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg,
galak-sgV2jX0FEOL9JmXXK+q4OQ, bcousson-rdvid1DuHRBWk0Htik3J/w,
linux-lFZ/pmaqli7XmaaqVzeoHQ, lgirdwood-Re5JQEeQqe8AvxtiuMwx3w,
linux-omap-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
nsekhar-l0cyMroinI0, kishon-l0cyMroinI0
vsel_reg and enable_reg of the pbias regulator descriptor should actually
have the offset from syscon.
However after
"ARM: dts: <platform>: add minimal l4 bus layout with control module
support"
vsel_reg and enable_reg started to have the absolute address because
of address translation that happens due to pbias node made as the
child node of syscon. This breaks the pbias regulator enable.
This series adds the 'offset' to be populated in vsel_reg and enable_reg
in the pbias driver itself.
Changes from v2:
*) Squashed all the dt patches into a single patch
Changes from v1:
*) Fixed Tony's review comments on adding a 'comment' for adding offset in
the driver and adding a warning for using platform_get_resource.
*) Added Tony's Acked-by.
Tested these patches against mmc -next in omap4 panda, omap3 beagle xm,
dra72 and omap5 uevm
Kishon Vijay Abraham I (2):
regulator: pbias: program pbias register offset in pbias driver
ARM: dts: <omap2/3/4/5/dra7>: use "ti,pbias-<platform>" compatible
string for pbias
.../bindings/regulator/pbias-regulator.txt | 7 ++-
arch/arm/boot/dts/dra7.dtsi | 2 +-
arch/arm/boot/dts/omap2430.dtsi | 2 +-
arch/arm/boot/dts/omap3.dtsi | 2 +-
arch/arm/boot/dts/omap4.dtsi | 2 +-
arch/arm/boot/dts/omap5.dtsi | 2 +-
drivers/regulator/pbias-regulator.c | 56 +++++++++++++++++---
7 files changed, 61 insertions(+), 12 deletions(-)
--
1.7.9.5
--
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
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v3 1/2] regulator: pbias: program pbias register offset in pbias driver
[not found] ` <1441368025-21182-1-git-send-email-kishon-l0cyMroinI0@public.gmane.org>
@ 2015-09-04 12:00 ` Kishon Vijay Abraham I
2015-09-04 15:17 ` Mark Brown
2015-09-04 12:44 ` [PATCH v3 0/2] regulator: Fix pbias regulator enable Ulf Hansson
1 sibling, 1 reply; 7+ messages in thread
From: Kishon Vijay Abraham I @ 2015-09-04 12:00 UTC (permalink / raw)
To: tony-4v6yS6AI5VpBDgjK7y7TUQ, broonie-DgEjT+Ai2ygdnm+yROfE0A,
devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-mmc-u79uwXL29TY76Z2rM5mHXA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA
Cc: ulf.hansson-QSEj5FYQhm4dnm+yROfE0A,
robh+dt-DgEjT+Ai2ygdnm+yROfE0A, pawel.moll-5wv7dgnIgG8,
mark.rutland-5wv7dgnIgG8, ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg,
galak-sgV2jX0FEOL9JmXXK+q4OQ, bcousson-rdvid1DuHRBWk0Htik3J/w,
linux-lFZ/pmaqli7XmaaqVzeoHQ, lgirdwood-Re5JQEeQqe8AvxtiuMwx3w,
linux-omap-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
nsekhar-l0cyMroinI0, kishon-l0cyMroinI0
Add separate compatible strings for every platform and populate the
pbias register offset in the driver data.
This helps avoid depending on the dt for pbias register offset.
Also update the dt binding documentation with the new compatible
strings.
Suggested-by: Tony Lindgren <tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
Signed-off-by: Kishon Vijay Abraham I <kishon-l0cyMroinI0@public.gmane.org>
Acked-by: Tony Lindgren <tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
---
.../bindings/regulator/pbias-regulator.txt | 7 ++-
drivers/regulator/pbias-regulator.c | 56 +++++++++++++++++---
2 files changed, 56 insertions(+), 7 deletions(-)
diff --git a/Documentation/devicetree/bindings/regulator/pbias-regulator.txt b/Documentation/devicetree/bindings/regulator/pbias-regulator.txt
index 32aa26f..acbcb45 100644
--- a/Documentation/devicetree/bindings/regulator/pbias-regulator.txt
+++ b/Documentation/devicetree/bindings/regulator/pbias-regulator.txt
@@ -2,7 +2,12 @@ PBIAS internal regulator for SD card dual voltage i/o pads on OMAP SoCs.
Required properties:
- compatible:
- - "ti,pbias-omap" for OMAP2, OMAP3, OMAP4, OMAP5, DRA7.
+ - should be "ti,pbias-dra7" for DRA7
+ - should be "ti,pbias-omap2" for OMAP2
+ - should be "ti,pbias-omap3" for OMAP3
+ - should be "ti,pbias-omap4" for OMAP4
+ - should be "ti,pbias-omap5" for OMAP5
+ - "ti,pbias-omap" is deprecated
- reg: pbias register offset from syscon base and size of pbias register.
- syscon : phandle of the system control module
- regulator-name : should be
diff --git a/drivers/regulator/pbias-regulator.c b/drivers/regulator/pbias-regulator.c
index bd2b75c..c21cedb 100644
--- a/drivers/regulator/pbias-regulator.c
+++ b/drivers/regulator/pbias-regulator.c
@@ -44,6 +44,10 @@ struct pbias_regulator_data {
int voltage;
};
+struct pbias_of_data {
+ unsigned int offset;
+};
+
static const unsigned int pbias_volt_table[] = {
1800000,
3000000
@@ -98,8 +102,35 @@ static struct of_regulator_match pbias_matches[] = {
};
#define PBIAS_NUM_REGS ARRAY_SIZE(pbias_matches)
+/* Offset from SCM general area (and syscon) base */
+
+static const struct pbias_of_data pbias_of_data_omap2 = {
+ .offset = 0x230,
+};
+
+static const struct pbias_of_data pbias_of_data_omap3 = {
+ .offset = 0x2b0,
+};
+
+static const struct pbias_of_data pbias_of_data_omap4 = {
+ .offset = 0x60,
+};
+
+static const struct pbias_of_data pbias_of_data_omap5 = {
+ .offset = 0x60,
+};
+
+static const struct pbias_of_data pbias_of_data_dra7 = {
+ .offset = 0xe00,
+};
+
static const struct of_device_id pbias_of_match[] = {
{ .compatible = "ti,pbias-omap", },
+ { .compatible = "ti,pbias-omap2", .data = &pbias_of_data_omap2, },
+ { .compatible = "ti,pbias-omap3", .data = &pbias_of_data_omap3, },
+ { .compatible = "ti,pbias-omap4", .data = &pbias_of_data_omap4, },
+ { .compatible = "ti,pbias-omap5", .data = &pbias_of_data_omap5, },
+ { .compatible = "ti,pbias-dra7", .data = &pbias_of_data_dra7, },
{},
};
MODULE_DEVICE_TABLE(of, pbias_of_match);
@@ -114,6 +145,9 @@ static int pbias_regulator_probe(struct platform_device *pdev)
const struct pbias_reg_info *info;
int ret = 0;
int count, idx, data_idx = 0;
+ const struct of_device_id *match;
+ const struct pbias_of_data *data;
+ unsigned int offset;
count = of_regulator_match(&pdev->dev, np, pbias_matches,
PBIAS_NUM_REGS);
@@ -129,6 +163,20 @@ static int pbias_regulator_probe(struct platform_device *pdev)
if (IS_ERR(syscon))
return PTR_ERR(syscon);
+ match = of_match_device(of_match_ptr(pbias_of_match), &pdev->dev);
+ if (match && match->data) {
+ data = match->data;
+ offset = data->offset;
+ } else {
+ res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
+ if (!res)
+ return -EINVAL;
+
+ offset = res->start;
+ dev_WARN(&pdev->dev,
+ "using legacy dt data for pbias offset\n");
+ }
+
cfg.regmap = syscon;
cfg.dev = &pdev->dev;
@@ -141,10 +189,6 @@ static int pbias_regulator_probe(struct platform_device *pdev)
if (!info)
return -ENODEV;
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- if (!res)
- return -EINVAL;
-
drvdata[data_idx].syscon = syscon;
drvdata[data_idx].info = info;
drvdata[data_idx].desc.name = info->name;
@@ -154,9 +198,9 @@ static int pbias_regulator_probe(struct platform_device *pdev)
drvdata[data_idx].desc.volt_table = pbias_volt_table;
drvdata[data_idx].desc.n_voltages = 2;
drvdata[data_idx].desc.enable_time = info->enable_time;
- drvdata[data_idx].desc.vsel_reg = res->start;
+ drvdata[data_idx].desc.vsel_reg = offset;
drvdata[data_idx].desc.vsel_mask = info->vmode;
- drvdata[data_idx].desc.enable_reg = res->start;
+ drvdata[data_idx].desc.enable_reg = offset;
drvdata[data_idx].desc.enable_mask = info->enable_mask;
drvdata[data_idx].desc.enable_val = info->enable;
--
1.7.9.5
--
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
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v3 2/2] ARM: dts: <omap2/3/4/5/dra7>: use "ti,pbias-<platform>" compatible string for pbias
2015-09-04 12:00 [PATCH v3 0/2] regulator: Fix pbias regulator enable Kishon Vijay Abraham I
@ 2015-09-04 12:00 ` Kishon Vijay Abraham I
[not found] ` <1441368025-21182-1-git-send-email-kishon-l0cyMroinI0@public.gmane.org>
1 sibling, 0 replies; 7+ messages in thread
From: Kishon Vijay Abraham I @ 2015-09-04 12:00 UTC (permalink / raw)
To: tony, broonie, devicetree, linux-mmc, linux-kernel
Cc: ulf.hansson, robh+dt, pawel.moll, mark.rutland, ijc+devicetree,
galak, bcousson, linux, lgirdwood, linux-omap, linux-arm-kernel,
nsekhar, kishon
Use platform specific compatible strings instead of the common
"ti,pbias-omap" compatible string.
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/boot/dts/dra7.dtsi | 2 +-
arch/arm/boot/dts/omap2430.dtsi | 2 +-
arch/arm/boot/dts/omap3.dtsi | 2 +-
arch/arm/boot/dts/omap4.dtsi | 2 +-
arch/arm/boot/dts/omap5.dtsi | 2 +-
5 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/arch/arm/boot/dts/dra7.dtsi b/arch/arm/boot/dts/dra7.dtsi
index 1e29ccf..d6bc6db 100644
--- a/arch/arm/boot/dts/dra7.dtsi
+++ b/arch/arm/boot/dts/dra7.dtsi
@@ -122,7 +122,7 @@
#size-cells = <1>;
pbias_regulator: pbias_regulator {
- compatible = "ti,pbias-omap";
+ compatible = "ti,pbias-dra7", "ti,pbias-omap";
reg = <0xe00 0x4>;
syscon = <&scm_conf>;
pbias_mmc_reg: pbias_mmc_omap5 {
diff --git a/arch/arm/boot/dts/omap2430.dtsi b/arch/arm/boot/dts/omap2430.dtsi
index 2390f38..3961a6f 100644
--- a/arch/arm/boot/dts/omap2430.dtsi
+++ b/arch/arm/boot/dts/omap2430.dtsi
@@ -63,7 +63,7 @@
};
pbias_regulator: pbias_regulator {
- compatible = "ti,pbias-omap";
+ compatible = "ti,pbias-omap2", "ti,pbias-omap";
reg = <0x230 0x4>;
syscon = <&scm_conf>;
pbias_mmc_reg: pbias_mmc_omap2430 {
diff --git a/arch/arm/boot/dts/omap3.dtsi b/arch/arm/boot/dts/omap3.dtsi
index 69a40cf..9af9ae1 100644
--- a/arch/arm/boot/dts/omap3.dtsi
+++ b/arch/arm/boot/dts/omap3.dtsi
@@ -203,7 +203,7 @@
};
pbias_regulator: pbias_regulator {
- compatible = "ti,pbias-omap";
+ compatible = "ti,pbias-omap3", "ti,pbias-omap";
reg = <0x2b0 0x4>;
syscon = <&scm_conf>;
pbias_mmc_reg: pbias_mmc_omap2430 {
diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
index abc4473..5aad7f3 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -198,7 +198,7 @@
#size-cells = <1>;
pbias_regulator: pbias_regulator {
- compatible = "ti,pbias-omap";
+ compatible = "ti,pbias-omap4", "ti,pbias-omap";
reg = <0x60 0x4>;
syscon = <&omap4_padconf_global>;
pbias_mmc_reg: pbias_mmc_omap4 {
diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index b1a1263..76ef595 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -187,7 +187,7 @@
#size-cells = <1>;
pbias_regulator: pbias_regulator {
- compatible = "ti,pbias-omap";
+ compatible = "ti,pbias-omap5", "ti,pbias-omap";
reg = <0x60 0x4>;
syscon = <&omap5_padconf_global>;
pbias_mmc_reg: pbias_mmc_omap5 {
--
1.7.9.5
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v3 0/2] regulator: Fix pbias regulator enable
[not found] ` <1441368025-21182-1-git-send-email-kishon-l0cyMroinI0@public.gmane.org>
2015-09-04 12:00 ` [PATCH v3 1/2] regulator: pbias: program pbias register offset in pbias driver Kishon Vijay Abraham I
@ 2015-09-04 12:44 ` Ulf Hansson
[not found] ` <CAPDyKFqCYx0JfXGq0T-44034UcR=v8nvKp7Fww=Zxa7N-z_vFg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
1 sibling, 1 reply; 7+ messages in thread
From: Ulf Hansson @ 2015-09-04 12:44 UTC (permalink / raw)
To: Kishon Vijay Abraham I
Cc: Tony Lindgren, Mark Brown,
devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-mmc,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Rob Herring,
Paweł Moll, Mark Rutland, Ian Campbell, Kumar Gala,
Benoit Cousson, Russell King - ARM Linux, Liam Girdwood,
linux-omap,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
Sekhar Nori
On 4 September 2015 at 14:00, Kishon Vijay Abraham I <kishon-l0cyMroinI0@public.gmane.org> wrote:
> vsel_reg and enable_reg of the pbias regulator descriptor should actually
> have the offset from syscon.
>
> However after
> "ARM: dts: <platform>: add minimal l4 bus layout with control module
> support"
> vsel_reg and enable_reg started to have the absolute address because
> of address translation that happens due to pbias node made as the
> child node of syscon. This breaks the pbias regulator enable.
>
> This series adds the 'offset' to be populated in vsel_reg and enable_reg
> in the pbias driver itself.
>
> Changes from v2:
> *) Squashed all the dt patches into a single patch
>
> Changes from v1:
> *) Fixed Tony's review comments on adding a 'comment' for adding offset in
> the driver and adding a warning for using platform_get_resource.
> *) Added Tony's Acked-by.
>
> Tested these patches against mmc -next in omap4 panda, omap3 beagle xm,
> dra72 and omap5 uevm
>
> Kishon Vijay Abraham I (2):
> regulator: pbias: program pbias register offset in pbias driver
> ARM: dts: <omap2/3/4/5/dra7>: use "ti,pbias-<platform>" compatible
> string for pbias
>
> .../bindings/regulator/pbias-regulator.txt | 7 ++-
> arch/arm/boot/dts/dra7.dtsi | 2 +-
> arch/arm/boot/dts/omap2430.dtsi | 2 +-
> arch/arm/boot/dts/omap3.dtsi | 2 +-
> arch/arm/boot/dts/omap4.dtsi | 2 +-
> arch/arm/boot/dts/omap5.dtsi | 2 +-
> drivers/regulator/pbias-regulator.c | 56 +++++++++++++++++---
> 7 files changed, 61 insertions(+), 12 deletions(-)
>
> --
> 1.7.9.5
>
Okay, just to be clear on the way forward. I spoked with Mark Brown
offlist, and he will/has picked up the regulator patch and will send
it as fix for the 4.3 rc[n].
Regarding the ARM patch here, I guess Tony might as well handle it and
send through arm-soc, especially since the regression won't be fixed
within my mmc tree anyway.
So, I am going to leave my next branch as is - and thus relying on
that the regression for OMAP will be fixed in some the 4.3 rc[n].
Kind regards
Uffe
--
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
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v3 1/2] regulator: pbias: program pbias register offset in pbias driver
2015-09-04 12:00 ` [PATCH v3 1/2] regulator: pbias: program pbias register offset in pbias driver Kishon Vijay Abraham I
@ 2015-09-04 15:17 ` Mark Brown
0 siblings, 0 replies; 7+ messages in thread
From: Mark Brown @ 2015-09-04 15:17 UTC (permalink / raw)
To: Kishon Vijay Abraham I
Cc: mark.rutland, devicetree, ulf.hansson, linux, pawel.moll,
ijc+devicetree, tony, nsekhar, linux-mmc, linux-kernel, lgirdwood,
robh+dt, bcousson, galak, linux-omap, linux-arm-kernel
[-- Attachment #1.1: Type: text/plain, Size: 398 bytes --]
On Fri, Sep 04, 2015 at 05:30:24PM +0530, Kishon Vijay Abraham I wrote:
> Add separate compatible strings for every platform and populate the
> pbias register offset in the driver data.
> This helps avoid depending on the dt for pbias register offset.
If there are any changes from the already applied patch for this please
send an incremental patch. Please don't resend already applied patches.
[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
[-- Attachment #2: Type: text/plain, Size: 176 bytes --]
_______________________________________________
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] 7+ messages in thread
* Re: [PATCH v3 0/2] regulator: Fix pbias regulator enable
[not found] ` <CAPDyKFqCYx0JfXGq0T-44034UcR=v8nvKp7Fww=Zxa7N-z_vFg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2015-09-14 20:22 ` Tony Lindgren
2015-09-15 5:50 ` Kishon Vijay Abraham I
0 siblings, 1 reply; 7+ messages in thread
From: Tony Lindgren @ 2015-09-14 20:22 UTC (permalink / raw)
To: Ulf Hansson
Cc: Kishon Vijay Abraham I, Mark Brown,
devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-mmc,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Rob Herring,
Paweł Moll, Mark Rutland, Ian Campbell, Kumar Gala,
Benoit Cousson, Russell King - ARM Linux, Liam Girdwood,
linux-omap,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
Sekhar Nori
Hi,
* Ulf Hansson <ulf.hansson-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org> [150904 05:48]:
>
> Okay, just to be clear on the way forward. I spoked with Mark Brown
> offlist, and he will/has picked up the regulator patch and will send
> it as fix for the 4.3 rc[n].
>
> Regarding the ARM patch here, I guess Tony might as well handle it and
> send through arm-soc, especially since the regression won't be fixed
> within my mmc tree anyway.
>
> So, I am going to leave my next branch as is - and thus relying on
> teet the regression for OMAP will be fixed in some the 4.3 rc[n].
I'm picking up the .dts changes from this series into
omap-for-v4.3/fixes as those are safe to apply while waiting
for the pbias-regulator.c fix to hit mainline.
I'm not yet applying the related dts change "fix address translation
for pbias" as that depends on the pbias-regulator.c change.
Howver, when testing all the patches applied, I'm still getting
the following splat at least on duovero (with MMC working):
WARNING: CPU: 0 PID: 6 at drivers/regulator/core.c:2105 _regulator_disable+0x13c/0x1d4()
unbalanced disables for pbias_mmc_omap4
Modules linked in:
CPU: 0 PID: 6 Comm: kworker/u4:0 Not tainted 4.3.0-rc1-00015-gf5c4173-dirty #1295
Hardware name: Generic OMAP4 (Flattened Device Tree)
Workqueue: deferwq deferred_probe_work_func
[<c001770c>] (unwind_backtrace) from [<c0013a58>] (show_stack+0x10/0x14)
[<c0013a58>] (show_stack) from [<c0346628>] (dump_stack+0x84/0x9c)
[<c0346628>] (dump_stack) from [<c003e958>] (warn_slowpath_common+0x78/0xb4)
[<c003e958>] (warn_slowpath_common) from [<c003e9c4>] (warn_slowpath_fmt+0x30/0x40)
[<c003e9c4>] (warn_slowpath_fmt) from [<c03a4e74>] (_regulator_disable+0x13c/0x1d4)
[<c03a4e74>] (_regulator_disable) from [<c03a4f3c>] (regulator_disable+0x30/0x6c)
[<c03a4f3c>] (regulator_disable) from [<c04c55a8>] (omap_hsmmc_set_power+0x158/0x1e8)
[<c04c55a8>] (omap_hsmmc_set_power) from [<c04c57d0>] (omap_hsmmc_set_ios+0x198/0x318)
[<c04c57d0>] (omap_hsmmc_set_ios) from [<c04af404>] (mmc_power_up.part.10+0x30/0xf8)
[<c04af404>] (mmc_power_up.part.10) from [<c04b0310>] (mmc_start_host+0x40/0x7c)
[<c04b0310>] (mmc_start_host) from [<c04b1424>] (mmc_add_host+0x5c/0x84)
[<c04b1424>] (mmc_add_host) from [<c04c5010>] (omap_hsmmc_probe+0x5b0/0x9f0)
[<c04c5010>] (omap_hsmmc_probe) from [<c03e0e9c>] (platform_drv_probe+0x44/0xac)
[<c03e0e9c>] (platform_drv_probe) from [<c03df550>] (driver_probe_device+0x1f4/0x2f0)
[<c03df550>] (driver_probe_device) from [<c03dda5c>] (bus_for_each_drv+0x64/0x98)
[<c03dda5c>] (bus_for_each_drv) from [<c03df2d0>] (__device_attach+0xb0/0x118)
[<c03df2d0>] (__device_attach) from [<c03de878>] (bus_probe_device+0x88/0x90)
[<c03de878>] (bus_probe_device) from [<c03deca0>] (deferred_probe_work_func+0x60/0x90)
[<c03deca0>] (deferred_probe_work_func) from [<c005899c>] (process_one_work+0x1a4/0x558)
[<c005899c>] (process_one_work) from [<c0058d8c>] (worker_thread+0x3c/0x514)
[<c0058d8c>] (worker_thread) from [<c005eb1c>] (kthread+0xd4/0xf0)
[<c005eb1c>] (kthread) from [<c000f710>] (ret_from_fork+0x14/0x24)
Kishon, can you please take a look?
Regards,
Tony
--
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
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v3 0/2] regulator: Fix pbias regulator enable
2015-09-14 20:22 ` Tony Lindgren
@ 2015-09-15 5:50 ` Kishon Vijay Abraham I
0 siblings, 0 replies; 7+ messages in thread
From: Kishon Vijay Abraham I @ 2015-09-15 5:50 UTC (permalink / raw)
To: Tony Lindgren, Ulf Hansson
Cc: Mark Brown, devicetree@vger.kernel.org, linux-mmc,
linux-kernel@vger.kernel.org, Rob Herring, Paweł Moll,
Mark Rutland, Ian Campbell, Kumar Gala, Benoit Cousson,
Russell King - ARM Linux, Liam Girdwood, linux-omap,
linux-arm-kernel@lists.infradead.org, Sekhar Nori
Hi,
On Tuesday 15 September 2015 01:52 AM, Tony Lindgren wrote:
> Hi,
>
> * Ulf Hansson <ulf.hansson@linaro.org> [150904 05:48]:
>>
>> Okay, just to be clear on the way forward. I spoked with Mark Brown
>> offlist, and he will/has picked up the regulator patch and will send
>> it as fix for the 4.3 rc[n].
>>
>> Regarding the ARM patch here, I guess Tony might as well handle it and
>> send through arm-soc, especially since the regression won't be fixed
>> within my mmc tree anyway.
>>
>> So, I am going to leave my next branch as is - and thus relying on
>> teet the regression for OMAP will be fixed in some the 4.3 rc[n].
>
> I'm picking up the .dts changes from this series into
> omap-for-v4.3/fixes as those are safe to apply while waiting
> for the pbias-regulator.c fix to hit mainline.
>
> I'm not yet applying the related dts change "fix address translation
> for pbias" as that depends on the pbias-regulator.c change.
>
> Howver, when testing all the patches applied, I'm still getting
> the following splat at least on duovero (with MMC working):
>
> WARNING: CPU: 0 PID: 6 at drivers/regulator/core.c:2105 _regulator_disable+0x13c/0x1d4()
> unbalanced disables for pbias_mmc_omap4
> Modules linked in:
> CPU: 0 PID: 6 Comm: kworker/u4:0 Not tainted 4.3.0-rc1-00015-gf5c4173-dirty #1295
> Hardware name: Generic OMAP4 (Flattened Device Tree)
> Workqueue: deferwq deferred_probe_work_func
> [<c001770c>] (unwind_backtrace) from [<c0013a58>] (show_stack+0x10/0x14)
> [<c0013a58>] (show_stack) from [<c0346628>] (dump_stack+0x84/0x9c)
> [<c0346628>] (dump_stack) from [<c003e958>] (warn_slowpath_common+0x78/0xb4)
> [<c003e958>] (warn_slowpath_common) from [<c003e9c4>] (warn_slowpath_fmt+0x30/0x40)
> [<c003e9c4>] (warn_slowpath_fmt) from [<c03a4e74>] (_regulator_disable+0x13c/0x1d4)
> [<c03a4e74>] (_regulator_disable) from [<c03a4f3c>] (regulator_disable+0x30/0x6c)
> [<c03a4f3c>] (regulator_disable) from [<c04c55a8>] (omap_hsmmc_set_power+0x158/0x1e8)
> [<c04c55a8>] (omap_hsmmc_set_power) from [<c04c57d0>] (omap_hsmmc_set_ios+0x198/0x318)
> [<c04c57d0>] (omap_hsmmc_set_ios) from [<c04af404>] (mmc_power_up.part.10+0x30/0xf8)
> [<c04af404>] (mmc_power_up.part.10) from [<c04b0310>] (mmc_start_host+0x40/0x7c)
> [<c04b0310>] (mmc_start_host) from [<c04b1424>] (mmc_add_host+0x5c/0x84)
> [<c04b1424>] (mmc_add_host) from [<c04c5010>] (omap_hsmmc_probe+0x5b0/0x9f0)
> [<c04c5010>] (omap_hsmmc_probe) from [<c03e0e9c>] (platform_drv_probe+0x44/0xac)
> [<c03e0e9c>] (platform_drv_probe) from [<c03df550>] (driver_probe_device+0x1f4/0x2f0)
> [<c03df550>] (driver_probe_device) from [<c03dda5c>] (bus_for_each_drv+0x64/0x98)
> [<c03dda5c>] (bus_for_each_drv) from [<c03df2d0>] (__device_attach+0xb0/0x118)
> [<c03df2d0>] (__device_attach) from [<c03de878>] (bus_probe_device+0x88/0x90)
> [<c03de878>] (bus_probe_device) from [<c03deca0>] (deferred_probe_work_func+0x60/0x90)
> [<c03deca0>] (deferred_probe_work_func) from [<c005899c>] (process_one_work+0x1a4/0x558)
> [<c005899c>] (process_one_work) from [<c0058d8c>] (worker_thread+0x3c/0x514)
> [<c0058d8c>] (worker_thread) from [<c005eb1c>] (kthread+0xd4/0xf0)
> [<c005eb1c>] (kthread) from [<c000f710>] (ret_from_fork+0x14/0x24)
>
> Kishon, can you please take a look?
really weird, since I didn't see any issues with my OMAP4 PANDA. Most
likely it's because the PBIAS register is not showing the correct state
of PBIAS. So we might have to remove using regulator_is_enabled and use
our own bookkeeping pbias_enabled variable. Anyway I'll check this.
Thanks
Kishon
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2015-09-15 5:50 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-04 12:00 [PATCH v3 0/2] regulator: Fix pbias regulator enable Kishon Vijay Abraham I
2015-09-04 12:00 ` [PATCH v3 2/2] ARM: dts: <omap2/3/4/5/dra7>: use "ti,pbias-<platform>" compatible string for pbias Kishon Vijay Abraham I
[not found] ` <1441368025-21182-1-git-send-email-kishon-l0cyMroinI0@public.gmane.org>
2015-09-04 12:00 ` [PATCH v3 1/2] regulator: pbias: program pbias register offset in pbias driver Kishon Vijay Abraham I
2015-09-04 15:17 ` Mark Brown
2015-09-04 12:44 ` [PATCH v3 0/2] regulator: Fix pbias regulator enable Ulf Hansson
[not found] ` <CAPDyKFqCYx0JfXGq0T-44034UcR=v8nvKp7Fww=Zxa7N-z_vFg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-09-14 20:22 ` Tony Lindgren
2015-09-15 5:50 ` Kishon Vijay Abraham I
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).