stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/7 RESEND] video: ARM CLCD: runtime check for Versatile
       [not found] <1456221704-5792-1-git-send-email-linus.walleij@linaro.org>
@ 2016-02-23 10:01 ` Linus Walleij
  2016-04-15 11:47   ` Linus Walleij
  0 siblings, 1 reply; 3+ messages in thread
From: Linus Walleij @ 2016-02-23 10:01 UTC (permalink / raw)
  To: linux-fbdev, Tomi Valkeinen, Jean-Christophe Plagniol-Villard,
	Pawel Moll, Rob Herring, Russell King
  Cc: linux-arm-kernel, Arnd Bergmann, Ray Jui, Linus Walleij, stable

The current compile-time check for inversed IENB/CNTL does not
work in multiplatform boots: as soon as versatile is included
in the build, the IENB/CNTL is switched and breaks graphics.
Convert this to a runtime switch.

Cc: stable@vger.kernel.org
Cc: Rob Herring <robh@kernel.org>
Cc: Russell King <linux@arm.linux.org.uk>
Fixes: a29da136de34 ("ARM: versatile: convert to multi-platform")
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 drivers/video/fbdev/amba-clcd.c | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

diff --git a/drivers/video/fbdev/amba-clcd.c b/drivers/video/fbdev/amba-clcd.c
index 9362424c2340..f9ef06d0cd48 100644
--- a/drivers/video/fbdev/amba-clcd.c
+++ b/drivers/video/fbdev/amba-clcd.c
@@ -440,13 +440,14 @@ static int clcdfb_register(struct clcd_fb *fb)
 		fb->off_ienb = CLCD_PL111_IENB;
 		fb->off_cntl = CLCD_PL111_CNTL;
 	} else {
-#ifdef CONFIG_ARCH_VERSATILE
-		fb->off_ienb = CLCD_PL111_IENB;
-		fb->off_cntl = CLCD_PL111_CNTL;
-#else
-		fb->off_ienb = CLCD_PL110_IENB;
-		fb->off_cntl = CLCD_PL110_CNTL;
-#endif
+		if (of_machine_is_compatible("arm,versatile-ab") ||
+		    of_machine_is_compatible("arm,versatile-pb")) {
+			fb->off_ienb = CLCD_PL111_IENB;
+			fb->off_cntl = CLCD_PL111_CNTL;
+		} else {
+			fb->off_ienb = CLCD_PL110_IENB;
+			fb->off_cntl = CLCD_PL110_CNTL;
+		}
 	}
 
 	fb->clk = clk_get(&fb->dev->dev, NULL);
-- 
2.4.3


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

* Re: [PATCH 1/7 RESEND] video: ARM CLCD: runtime check for Versatile
  2016-02-23 10:01 ` [PATCH 1/7 RESEND] video: ARM CLCD: runtime check for Versatile Linus Walleij
@ 2016-04-15 11:47   ` Linus Walleij
  2016-04-18  9:10     ` Tomi Valkeinen
  0 siblings, 1 reply; 3+ messages in thread
From: Linus Walleij @ 2016-04-15 11:47 UTC (permalink / raw)
  To: linux-fbdev@vger.kernel.org, Tomi Valkeinen,
	Jean-Christophe Plagniol-Villard, Pawel Moll, Rob Herring,
	Russell King
  Cc: linux-arm-kernel@lists.infradead.org, Arnd Bergmann, Ray Jui,
	Linus Walleij, stable

On Tue, Feb 23, 2016 at 11:01 AM, Linus Walleij
<linus.walleij@linaro.org> wrote:

> The current compile-time check for inversed IENB/CNTL does not
> work in multiplatform boots: as soon as versatile is included
> in the build, the IENB/CNTL is switched and breaks graphics.
> Convert this to a runtime switch.
>
> Cc: stable@vger.kernel.org
> Cc: Rob Herring <robh@kernel.org>
> Cc: Russell King <linux@arm.linux.org.uk>
> Fixes: a29da136de34 ("ARM: versatile: convert to multi-platform")
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>

Tomi can you PLEASE merge this patch which is regressing all
the Versatile hardware since commit a29da136de34?

It is not dependent on the rest of the series.

I am coming back to revising the rest of the patches, but
this one need to go in.

Yours,
Linus Walleij

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

* Re: [PATCH 1/7 RESEND] video: ARM CLCD: runtime check for Versatile
  2016-04-15 11:47   ` Linus Walleij
@ 2016-04-18  9:10     ` Tomi Valkeinen
  0 siblings, 0 replies; 3+ messages in thread
From: Tomi Valkeinen @ 2016-04-18  9:10 UTC (permalink / raw)
  To: Linus Walleij, linux-fbdev@vger.kernel.org,
	Jean-Christophe Plagniol-Villard, Pawel Moll, Rob Herring,
	Russell King
  Cc: linux-arm-kernel@lists.infradead.org, Arnd Bergmann, Ray Jui,
	stable


[-- Attachment #1.1: Type: text/plain, Size: 929 bytes --]


On 15/04/16 14:47, Linus Walleij wrote:
> On Tue, Feb 23, 2016 at 11:01 AM, Linus Walleij
> <linus.walleij@linaro.org> wrote:
> 
>> The current compile-time check for inversed IENB/CNTL does not
>> work in multiplatform boots: as soon as versatile is included
>> in the build, the IENB/CNTL is switched and breaks graphics.
>> Convert this to a runtime switch.
>>
>> Cc: stable@vger.kernel.org
>> Cc: Rob Herring <robh@kernel.org>
>> Cc: Russell King <linux@arm.linux.org.uk>
>> Fixes: a29da136de34 ("ARM: versatile: convert to multi-platform")
>> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> 
> Tomi can you PLEASE merge this patch which is regressing all
> the Versatile hardware since commit a29da136de34?
> 
> It is not dependent on the rest of the series.
> 
> I am coming back to revising the rest of the patches, but
> this one need to go in.

Sure, queued for 4.6 fixes.

 Tomi


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

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

end of thread, other threads:[~2016-04-18  9:11 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <1456221704-5792-1-git-send-email-linus.walleij@linaro.org>
2016-02-23 10:01 ` [PATCH 1/7 RESEND] video: ARM CLCD: runtime check for Versatile Linus Walleij
2016-04-15 11:47   ` Linus Walleij
2016-04-18  9:10     ` Tomi Valkeinen

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