stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] ARM: imx: cpuidle-imx6sx: Restrict the SW2ISO increase to i.MX6SX
@ 2019-05-13  3:15 Fabio Estevam
  2019-05-20  6:32 ` Shawn Guo
  0 siblings, 1 reply; 2+ messages in thread
From: Fabio Estevam @ 2019-05-13  3:15 UTC (permalink / raw)
  To: shawnguo
  Cc: linux-arm-kernel, anson.huang, kernel, linux-imx, cniedermaier,
	sebastien.szymanski, Fabio Estevam, stable

Since commit 1e434b703248 ("ARM: imx: update the cpu power up timing
setting on i.mx6sx") some characters loss is noticed on i.MX6ULL UART
as reported by Christoph Niedermaier.

The intention of such commit was to increase the SW2ISO field for i.MX6SX
only, but since cpuidle-imx6sx is also used on i.MX6UL/i.MX6ULL this caused
unintended side effects on other SoCs.

Fix this problem by keeping the original SW2ISO value for i.MX6UL/i.MX6ULL
and only increase SW2ISO in the i.MX6SX case.

Cc: stable@vger.kernel.org
Fixes: 1e434b703248 ("ARM: imx: update the cpu power up timing setting on i.mx6sx")
Reported-by: Christoph Niedermaier <cniedermaier@dh-electronics.com>
Signed-off-by: Fabio Estevam <festevam@gmail.com>
Tested-by: Sébastien Szymanski <sebastien.szymanski@armadeus.com>
Tested-by: Christoph Niedermaier <cniedermaier@dh-electronics.com>
---
Changes since v1:
- Simplify the code by using the C ternary operator so that the
patch can be backported all the way to kernel 4.4

 arch/arm/mach-imx/cpuidle-imx6sx.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm/mach-imx/cpuidle-imx6sx.c b/arch/arm/mach-imx/cpuidle-imx6sx.c
index fd0053e47a15..4016b717da1b 100644
--- a/arch/arm/mach-imx/cpuidle-imx6sx.c
+++ b/arch/arm/mach-imx/cpuidle-imx6sx.c
@@ -15,6 +15,7 @@
 
 #include "common.h"
 #include "cpuidle.h"
+#include "hardware.h"
 
 static int imx6sx_idle_finish(unsigned long val)
 {
@@ -110,7 +111,7 @@ int __init imx6sx_cpuidle_init(void)
 	 * except for power up sw2iso which need to be
 	 * larger than LDO ramp up time.
 	 */
-	imx_gpc_set_arm_power_up_timing(0xf, 1);
+	imx_gpc_set_arm_power_up_timing(cpu_is_imx6sx() ? 0xf : 0x2, 1);
 	imx_gpc_set_arm_power_down_timing(1, 1);
 
 	return cpuidle_register(&imx6sx_cpuidle_driver, NULL);
-- 
2.17.1


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

* Re: [PATCH v2] ARM: imx: cpuidle-imx6sx: Restrict the SW2ISO increase to i.MX6SX
  2019-05-13  3:15 [PATCH v2] ARM: imx: cpuidle-imx6sx: Restrict the SW2ISO increase to i.MX6SX Fabio Estevam
@ 2019-05-20  6:32 ` Shawn Guo
  0 siblings, 0 replies; 2+ messages in thread
From: Shawn Guo @ 2019-05-20  6:32 UTC (permalink / raw)
  To: Fabio Estevam
  Cc: linux-arm-kernel, anson.huang, kernel, linux-imx, cniedermaier,
	sebastien.szymanski, stable

On Mon, May 13, 2019 at 12:15:31AM -0300, Fabio Estevam wrote:
> Since commit 1e434b703248 ("ARM: imx: update the cpu power up timing
> setting on i.mx6sx") some characters loss is noticed on i.MX6ULL UART
> as reported by Christoph Niedermaier.
> 
> The intention of such commit was to increase the SW2ISO field for i.MX6SX
> only, but since cpuidle-imx6sx is also used on i.MX6UL/i.MX6ULL this caused
> unintended side effects on other SoCs.
> 
> Fix this problem by keeping the original SW2ISO value for i.MX6UL/i.MX6ULL
> and only increase SW2ISO in the i.MX6SX case.
> 
> Cc: stable@vger.kernel.org
> Fixes: 1e434b703248 ("ARM: imx: update the cpu power up timing setting on i.mx6sx")
> Reported-by: Christoph Niedermaier <cniedermaier@dh-electronics.com>
> Signed-off-by: Fabio Estevam <festevam@gmail.com>
> Tested-by: Sébastien Szymanski <sebastien.szymanski@armadeus.com>
> Tested-by: Christoph Niedermaier <cniedermaier@dh-electronics.com>

Applied, thanks.

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

end of thread, other threads:[~2019-05-20  6:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-13  3:15 [PATCH v2] ARM: imx: cpuidle-imx6sx: Restrict the SW2ISO increase to i.MX6SX Fabio Estevam
2019-05-20  6:32 ` Shawn Guo

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).