[PATCH] spi/pl022: Enable clock in probe an use runtime_idle

2011-10-21 Thread Ulf Hansson
: I6cb86f2cad30ecaab16f512daf4674b039b18213 Signed-off-by: Ulf Hansson ulf.hans...@stericsson.com Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/34447 --- drivers/spi/spi-pl022.c | 18 +- 1 files changed, 17 insertions(+), 1 deletions(-) diff --git a/drivers/spi/spi-pl022.c b/drivers/spi/spi-pl022.c index f103e47

Re: [PATCH] spi/pl022: Enable clock in probe an use runtime_idle

2011-10-24 Thread Ulf Hansson
Linus Walleij wrote: On Fri, Oct 21, 2011 at 4:08 PM, Ulf Hansson ulf.hans...@stericsson.com wrote: Since we are always runtime resumed when leaving probe the clock must be enabled. To accomplish that we are able to be runtime suspended after probe in the case when no request is going

Re: [PATCH] spi/pl022: Enable clock in probe an use runtime_idle

2011-11-03 Thread Ulf Hansson
@@ -2342,11 +2350,19 @@ static int pl022_runtime_resume(struct device *dev) return 0; } + +static int pl022_runtime_idle(struct device *dev) +{ +pm_runtime_suspend(dev); +return 0; +} #endif static const struct dev_pm_ops pl022_dev_pm_ops = {

Re: [PATCH] spi/pl022: Enable clock in probe an use runtime_idle

2011-11-03 Thread Ulf Hansson
Russell King - ARM Linux wrote: On Thu, Nov 03, 2011 at 02:59:53PM +0100, Ulf Hansson wrote: @@ -2342,11 +2350,19 @@ static int pl022_runtime_resume(struct device *dev) return 0; } + +static int pl022_runtime_idle(struct device *dev) +{ + pm_runtime_suspend(dev); + return 0

[PATCH V2] spi/pl022: Enable clock in probe

2011-11-03 Thread Ulf Hansson
Make sure we enable the clock before leaving probe. Signed-off-by: Ulf Hansson ulf.hans...@stericsson.com --- Changes in v2: -Remove runtime_idle --- drivers/spi/spi-pl022.c |8 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/drivers/spi/spi-pl022.c b

Re: [PATCH/RFC v2] ARM: amba: Remove AMBA level regulator support

2012-04-13 Thread Ulf Hansson
option? Kind regards Ulf Hansson On 04/01/2012 08:58 PM, Mark Brown wrote: The AMBA bus regulator support is being used to model on/off switches for power domains which isn't terribly idiomatic for modern kernels with the generic power domain code and creates integration problems on platforms

Re: [PATCH/RFC v2] ARM: amba: Remove AMBA level regulator support

2012-04-13 Thread Ulf Hansson
On 04/13/2012 11:18 AM, Mark Brown wrote: On Fri, Apr 13, 2012 at 11:03:56AM +0200, Ulf Hansson wrote: But, how should those amba drivers that implements runtime PM support be able to switch of the vcore regulator during normal suspend? In normal suspend case we can not use A generic AMBA

Re: [PATCH] spi/pl022: get/put resources on suspend/resume

2012-09-26 Thread Ulf Hansson
I can agree with the code as such. One issue remains though. You will have compile warnings when not having CONFIG_SUSPEND and CONFIG_RUNTIME_PM, due to unused code/functions. Otherwise you have my ack. Kind regards Ulf Hansson On 26 September 2012 17:08, Linus Walleij linus.wall

[PATCH] spi/pl022: Simplify use of runtime pm

2012-09-26 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org Signed-off-by: Ulf Hansson ulf.hans...@linaro.org --- drivers/spi/spi-pl022.c |8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/drivers/spi/spi-pl022.c b/drivers/spi/spi-pl022.c index f8568b4..e51a026 100644 --- a/drivers/spi

Re: [PATCH] spi/pl022: get/put resources on suspend/resume

2012-09-26 Thread Ulf Hansson
On 26 September 2012 17:27, Linus Walleij linus.wall...@linaro.org wrote: On Wed, Sep 26, 2012 at 5:23 PM, Ulf Hansson ulf.hans...@linaro.org wrote: You will have compile warnings when not having CONFIG_SUSPEND and CONFIG_RUNTIME_PM, due to unused code/functions. Argh the evil #fidefs

[PATCH V2] spi/pl022: Simplify use of runtime pm

2012-09-27 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org In probe the pm_runtime_resume is not needed since the amba bus has already set the device in resumed state by using pm_runtime_set_active. Additionally more simplifications is done in probe by removing pm_runtime_put_autosuspend

[PATCH 1/3] Revert spi/pl022: fix spi-pl022 pm enable at probe

2012-09-28 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org This reverts commit 6887237cd7da904184dab2750504040c68f3a080. Signed-off-by: Ulf Hansson ulf.hans...@linaro.org --- drivers/spi/spi-pl022.c |1 + 1 file changed, 1 insertion(+) diff --git a/drivers/spi/spi-pl022.c b/drivers/spi/spi-pl022.c index

[PATCH 0/3] Fixup use of runtime pm

2012-09-28 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org Some old runtime pm patches got merged whiched messed up things. These is now reverted. Additionaly one patch do a simplification of the use of runtime pm functions. Ulf Hansson (3): Revert spi/pl022: fix spi-pl022 pm enable at probe Revert spi/pl022

[PATCH 2/3] Revert spi/pl022: enable runtime PM

2012-09-28 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org This reverts commit 2fb30d1147c599f5657e8c62c862f9a0f58d9d99. Signed-off-by: Ulf Hansson ulf.hans...@linaro.org --- drivers/spi/spi-pl022.c |4 1 file changed, 4 deletions(-) diff --git a/drivers/spi/spi-pl022.c b/drivers/spi/spi-pl022.c index

[PATCH 3/3] spi: spi-pl022: Minor simplification for runtime pm

2012-09-28 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org In probe pm_runtime_put_autosuspend has the same effect as doing pm_runtime_put. This due to upper layer in driver core is preventing the device from being runtime suspended by a pm_runtime_get*. Signed-off-by: Ulf Hansson ulf.hans...@linaro.org

Re: [PATCH 1/3] Revert spi/pl022: fix spi-pl022 pm enable at probe

2012-10-03 Thread Ulf Hansson
runtime PM [PATCH 3/3] spi: spi-pl022: Minor simplification for runtime pm Kind regards Ulf Hansson On 28 September 2012 13:21, Ulf Hansson ulf.hans...@stericsson.com wrote: From: Ulf Hansson ulf.hans...@linaro.org This reverts commit 6887237cd7da904184dab2750504040c68f3a080. Signed-off

Re: [PATCH 1/3] Revert spi/pl022: fix spi-pl022 pm enable at probe

2012-10-03 Thread Ulf Hansson
Hi Mark, I will do a resend and include some explanation for the reverts in the cover-letter. Kind regards Ulf Hansson On 3 October 2012 15:55, Mark Brown broo...@opensource.wolfsonmicro.com wrote: On Wed, Oct 03, 2012 at 03:43:16PM +0200, Ulf Hansson wrote: Heard from Linus Walleij that you

[PATCH V2 1/3] Revert spi/pl022: fix spi-pl022 pm enable at probe

2012-10-04 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org This reverts commit 6887237cd7da904184dab2750504040c68f3a080. This reverts is done due to earlier wrong commit, which is also reverted. Revert spi/pl022: enable runtime PM Signed-off-by: Ulf Hansson ulf.hans...@linaro.org Reviewed-by: Linus Walleij

[PATCH V2 3/3] spi: spi-pl022: Minor simplification for runtime pm

2012-10-04 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org In probe pm_runtime_put_autosuspend has the same effect as doing pm_runtime_put. This due to upper layer in driver core is preventing the device from being runtime suspended by a pm_runtime_get*. Signed-off-by: Ulf Hansson ulf.hans...@linaro.org Reviewed

[PATCH V2 0/3] spi: spi-pl022: Fixup use of runtime pm

2012-10-04 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org Some old runtime pm patches got merged whiched messed up things. These are now reverted. Additionaly one patch do a simplification of the use of runtime pm functions. V2: Rebased patches and updated commit messages. Ulf Hansson (3): Revert spi/pl022

[PATCH V2 2/3] Revert spi/pl022: enable runtime PM

2012-10-04 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org This reverts commit 2fb30d1147c599f5657e8c62c862f9a0f58d9d99. This patch is reverted due to wrong runtime PM code. Conflicts: drivers/spi/spi-pl022.c Signed-off-by: Ulf Hansson ulf.hans...@linaro.org Acked-by: Linus Walleij linus.wall

Re: [PATCH V2 3/3] spi: spi-pl022: Minor simplification for runtime pm

2012-10-04 Thread Ulf Hansson
Hansson On 4 October 2012 10:04, Ulf Hansson ulf.hans...@stericsson.com wrote: From: Ulf Hansson ulf.hans...@linaro.org In probe pm_runtime_put_autosuspend has the same effect as doing pm_runtime_put. This due to upper layer in driver core is preventing the device from being runtime suspended

[PATCH] spi/pl022: Activate resourses before deactivate them in suspend

2012-10-05 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org To be able to deactivate resourses in suspend, the resourses must first be surely active. This is done with a pm_runtime_get_sync. Once the resourses are restored to active state again in resume, the runtime pm usage count can be decreased

Re: [PATCH V2 0/3] spi: spi-pl022: Fixup use of runtime pm

2012-10-05 Thread Ulf Hansson
, removing the 3/3 patch and updating the commitmsg accordingly. Kind regards Ulf Hansson -- Don't let slow site performance ruin your business. Deploy New Relic APM Deploy New Relic app performance management and know

[PATCH 2/2] Revert spi/pl022: enable runtime PM

2012-10-05 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org This reverts commit 2fb30d1147c599f5657e8c62c862f9a0f58d9d99. This patch introduced runtime PM issues and is not needed at all. Thus we should revert it. Conflicts: drivers/spi/spi-pl022.c Signed-off-by: Ulf Hansson ulf.hans...@linaro.org Acked

[PATCH 1/2] Revert spi/pl022: fix spi-pl022 pm enable at probe

2012-10-05 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org This reverts commit 6887237cd7da904184dab2750504040c68f3a080. Commit spi/pl022: enable runtime PM introduced runtime PM issues. Due to that commit, spi/pl022: fix spi-pl022 pm enable at probe was merged to fix part of those issues. Instead of adding

Re: [PATCH] spi/pl022: Activate resourses before deactivate them in suspend

2012-10-12 Thread Ulf Hansson
Hi Mark, Just a kind remember on this. Do you see any problem merging this? Kind regards Ulf Hansson On 5 October 2012 09:43, Ulf Hansson ulf.hans...@stericsson.com wrote: From: Ulf Hansson ulf.hans...@linaro.org To be able to deactivate resourses in suspend, the resourses must first

Re: [PATCH 2/4] spi: spi-pl022: Minor simplification for runtime pm

2012-10-17 Thread Ulf Hansson
. Kind regards Ulf Hansson On 17 October 2012 14:27, Linus Walleij linus.wall...@stericsson.com wrote: From: Ulf Hansson ulf.hans...@linaro.org In probe pm_runtime_put_autosuspend has the same effect as doing pm_runtime_put. This due to upper layer in driver core is preventing the device from

Re: [PATCH 2/2] Revert spi/pl022: enable runtime PM

2012-10-23 Thread Ulf Hansson
It seems like this patch did not get applied together with: [PATCH 1/2] Revert spi/pl022: fix spi-pl022 pm enable at probe The problem was likely my fault, since there were a lot of resends. Anyway, it should still be possible to apply. Kind regards Ulf Hansson On 5 October 2012 17:51, Ulf

[PATCH] Revert spi/pl022: enable runtime PM

2012-10-23 Thread Ulf Hansson
From: Ulf Hansson ulf.hans...@linaro.org This reverts commit 2fb30d1147c599f5657e8c62c862f9a0f58d9d99. This patch introduced runtime PM issues and is not needed at all. Thus we should revert it. Conflicts: drivers/spi/spi-pl022.c Signed-off-by: Ulf Hansson ulf.hans...@linaro.org Acked

Re: [PATCH] spi/pl022: Activate resourses before deactivate them in suspend

2012-10-28 Thread Ulf Hansson
On 28 October 2012 20:52, Linus Walleij linus.wall...@linaro.org wrote: On Sat, Oct 27, 2012 at 11:46 PM, Mark Brown broo...@opensource.wolfsonmicro.com wrote: On Fri, Oct 05, 2012 at 09:43:32AM +0200, Ulf Hansson wrote: To be able to deactivate resourses in suspend, the resourses must first

Re: [PATCH] spi/pl022: Activate resourses before deactivate them in suspend

2012-10-30 Thread Ulf Hansson
On 28 October 2012 22:09, Alan Stern st...@rowland.harvard.edu wrote: On Sun, 28 Oct 2012, Ulf Hansson wrote: On 28 October 2012 20:52, Linus Walleij linus.wall...@linaro.org wrote: On Sat, Oct 27, 2012 at 11:46 PM, Mark Brown broo...@opensource.wolfsonmicro.com wrote: On Fri, Oct 05