Skip to contentSkip to conversation

A few mxsfb patches

PATCH Superseded Shawn Guo 5 participants 17 messages Mar 5, 2011 – Apr 5, 2011

Subsystems (4)
lore
Share & tools
lore

Shawn Guo

author
#0 lore raw

The patches came from the work of adding framebuffer for mx28evk and mx23evk boards. They are all minor changes.

[PATCH 1/3] video: mxsfb: smarten the code a little bit
[PATCH 2/3] video: mxsfb: fix the incorrect error checking for alloc_pages_exact [PATCH 3/3] video: mxsfb: add DOTCLK polarity configuration support

 arch/arm/mach-mxs/include/mach/mxsfb.h |    3 ++-
 drivers/video/mxsfb.c                  |   25 ++++++++++++++-----------
 2 files changed, 16 insertions(+), 12 deletions(-)

Regards,
Shawn

author
#1 lore raw

PATCH 1/3 video: mxsfb: smarten the code a little bit

* Fix indentation issue in register definitions
* Remove empty pair of {} in mxsfb_devtype[]
* Add a message for a successful mxsfb_probe, which seems useful to tell that mxsfb driver is built in and probed successfully

---
 drivers/video/mxsfb.c |   15 ++++++++-------
 1 files changed, 8 insertions(+), 7 deletions(-)
drivers/video/mxsfb.c +8 -7
index a3b1179..8a57f8b 100644
@@ -52,11 +52,11 @@
 #define LCDC_CTRL			0x00
 #define LCDC_CTRL1			0x10
 #define LCDC_V4_CTRL2			0x20
-#define LCDC_V3_TRANSFER_COUNT	0x20
-#define LCDC_V4_TRANSFER_COUNT	0x30
-#define LCDC_V4_CUR_BUF		0x40
+#define LCDC_V3_TRANSFER_COUNT		0x20
+#define LCDC_V4_TRANSFER_COUNT		0x30
+#define LCDC_V4_CUR_BUF			0x40
 #define LCDC_V4_NEXT_BUF		0x50
-#define LCDC_V3_CUR_BUF		0x30
+#define LCDC_V3_CUR_BUF			0x30
 #define LCDC_V3_NEXT_BUF		0x40
 #define LCDC_TIMING			0x60
 #define LCDC_VDCTRL0			0x70
@@ -71,8 +71,8 @@
 #define LCDC_DVICTRL4			0x100
 #define LCDC_V4_DATA			0x180
 #define LCDC_V3_DATA			0x1b0
-#define LCDC_V4_DEBUG0		0x1d0
-#define LCDC_V3_DEBUG0		0x1f0
+#define LCDC_V4_DEBUG0			0x1d0
+#define LCDC_V3_DEBUG0			0x1f0
 
 #define CTRL_SFTRST			(1 << 31)
 #define CTRL_CLKGATE			(1 << 30)
@@ -832,6 +832,8 @@ static int __devinit mxsfb_probe(struct platform_device *pdev)
 		mxsfb_enable_controller(fb_info);
 	}
 
+	dev_info(&pdev->dev, "initialized\n");
+
 	return 0;
 
 error_register:
@@ -882,7 +884,6 @@ static struct platform_device_id mxsfb_devtype[] = {
 	}, {
 		.name = "imx28-fb",
 		.driver_data = MXSFB_V4,
-	}, {
 	},
 };
 MODULE_DEVICE_TABLE(platform, mxsfb_devtype);
Signature · 1 line
1.7.1
#2 lore raw

PATCH 1/3 video: mxsfb: smarten the code a little bit

drivers/video/mxsfb.c static struct platform_device_id mxsfb_devtype[] = { · line 888

Quoted 7 lines · On Saturday 05 March 2011 17:18:49 Shawn Guo wrote:
drivers/video/mxsfb.c +0 -1
@@ -882,7 +884,6 @@ static struct platform_device_id mxsfb_devtype[] = {
        }, {
                .name = "imx28-fb",
                .driver_data = MXSFB_V4,
-       }, {
        },
 };

This is broken, you need to have an empty entry as the end marker, otherwise, the match function will interpret whatever comes in memory after the last entry as input data, until it hits zeroes.

Arnd

author
#3 lore raw

PATCH 1/3 video: mxsfb: smarten the code a little bit

Hi Arnd,

Quoted 13 lines · Arnd Bergmann

drivers/video/mxsfb.c static struct platform_device_id mxsfb_devtype[] = { · line 888

Quoted 7 lines · On Saturday 05 March 2011 17:18:49 Shawn Guo wrote:
drivers/video/mxsfb.c +0 -1
@@ -882,7 +884,6 @@ static struct platform_device_id mxsfb_devtype[] = {
        }, {
                .name = "imx28-fb",
                .driver_data = MXSFB_V4,
-       }, {
        },
 };

This is broken, you need to have an empty entry as the end marker, otherwise, the match function will interpret whatever comes in memory after the last entry as input data, until it hits zeroes.

Ah, my dumb. Thanks for pointing this out. I will recover it with a marker, and also prepare a patch to fix the exactly same issue I created in fec.c :)

Signature · 2 lines
Regards,
Shawn
author
#4 lore raw

PATCH 1/3 video: mxsfb: smarten the code a little bit

Quoted 16 lines · Shawn Guo

Hi Arnd,

Quoted 13 lines · Arnd Bergmann

drivers/video/mxsfb.c static struct platform_device_id mxsfb_devtype[] = { · line 888

Quoted 7 lines · On Saturday 05 March 2011 17:18:49 Shawn Guo wrote:
drivers/video/mxsfb.c +0 -1
@@ -882,7 +884,6 @@ static struct platform_device_id mxsfb_devtype[] = {
        }, {
                .name = "imx28-fb",
                .driver_data = MXSFB_V4,
-       }, {
        },
 };

This is broken, you need to have an empty entry as the end marker, otherwise, the match function will interpret whatever comes in memory after the last entry as input data, until it hits zeroes.

Quoted 4 lines

Ah, my dumb. Thanks for pointing this out. I will recover it with a marker, and also prepare a patch to fix the exactly same issue I created in fec.c :)

Just found that fec has been fixed by the following commit on David's tree.

commit 9eb0e6f26e48ef22cc56a2b81b1572ace999f70f

Author: Axel Lin <[email protected]>
Date:   Tue Feb 22 23:28:46 2011 +0000

net/fec: fix unterminated platform_device_id table

The platform_device_id table is supposed to be zero-terminated.

Signature · 2 lines
Regards,
Shawn
author
#5 lore raw

PATCH RESEND 1/3 video: mxsfb: smarten the code a little bit

In reply to Shawn Guo

* Fix indentation issue in register definitions
* Add a message for a successful mxsfb_probe, which seems useful to tell that mxsfb driver is built in and probed successfully

---
 drivers/video/mxsfb.c |   17 ++++++++++-------
 1 files changed, 10 insertions(+), 7 deletions(-)
drivers/video/mxsfb.c +10 -7
index a3b1179..9591cb6 100644
@@ -52,11 +52,11 @@
 #define LCDC_CTRL			0x00
 #define LCDC_CTRL1			0x10
 #define LCDC_V4_CTRL2			0x20
-#define LCDC_V3_TRANSFER_COUNT	0x20
-#define LCDC_V4_TRANSFER_COUNT	0x30
-#define LCDC_V4_CUR_BUF		0x40
+#define LCDC_V3_TRANSFER_COUNT		0x20
+#define LCDC_V4_TRANSFER_COUNT		0x30
+#define LCDC_V4_CUR_BUF			0x40
 #define LCDC_V4_NEXT_BUF		0x50
-#define LCDC_V3_CUR_BUF		0x30
+#define LCDC_V3_CUR_BUF			0x30
 #define LCDC_V3_NEXT_BUF		0x40
 #define LCDC_TIMING			0x60
 #define LCDC_VDCTRL0			0x70
@@ -71,8 +71,8 @@
 #define LCDC_DVICTRL4			0x100
 #define LCDC_V4_DATA			0x180
 #define LCDC_V3_DATA			0x1b0
-#define LCDC_V4_DEBUG0		0x1d0
-#define LCDC_V3_DEBUG0		0x1f0
+#define LCDC_V4_DEBUG0			0x1d0
+#define LCDC_V3_DEBUG0			0x1f0
 
 #define CTRL_SFTRST			(1 << 31)
 #define CTRL_CLKGATE			(1 << 30)
@@ -832,6 +832,8 @@ static int __devinit mxsfb_probe(struct platform_device *pdev)
 		mxsfb_enable_controller(fb_info);
 	}
 
+	dev_info(&pdev->dev, "initialized\n");
+
 	return 0;
 
 error_register:
@@ -883,7 +885,8 @@ static struct platform_device_id mxsfb_devtype[] = {
 		.name = "imx28-fb",
 		.driver_data = MXSFB_V4,
 	}, {
-	},
+		/* sentinel */
+	}
 };
 MODULE_DEVICE_TABLE(platform, mxsfb_devtype);
 
Signature · 1 line
1.7.1
author
#6 lore raw

PATCH 2/3 video: mxsfb: fix the incorrect error checking for alloc_pages_exact

In reply to Shawn Guo

fb_virt than fb_info->screen_base should be checked here, or the path of framebuffer allocation always ends up with 'return -ENOMEM'.

---
 drivers/video/mxsfb.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/video/mxsfb.c +1 -1
index 8a57f8b..927a682 100644
@@ -717,7 +717,7 @@ static int __devinit mxsfb_init_fbinfo(struct mxsfb_info *host)
 		if (!fb_size)
 			fb_size = SZ_2M; /* default */
 		fb_virt = alloc_pages_exact(fb_size, GFP_DMA);
-		if (!fb_info->screen_base)
+		if (!fb_virt)
 			return -ENOMEM;
 
 		fb_phys = virt_to_phys(fb_virt);
Signature · 1 line
1.7.1
author
#7 lore raw

PATCH 3/3 video: mxsfb: add DOTCLK polarity configuration support

In reply to Shawn Guo

The current implementation provides configuration for HSYNC_POL, VSYNC_POL and ENABLE_POL via 'sync' of fb_videomode, but DOTCLK_POL is missing there. It's assuming that data sampling at rising/positive edge is always the case. However, it's not true. For example, the panel on mx28evk board (Seiko 43WVF1G) samples data at failing/negative edge. The patch is to add this configuration.

Also, to unify the naming schema of all these polarity configurations and match them with the bits name in Reference Manual, a couple of definitions are renamed.

Lastly, to reduce the chance of defining customized 'FB_SYNC_' flag by incrementing the preceeding value, the definitions are changed to bit shifting way.

---
 arch/arm/mach-mxs/include/mach/mxsfb.h |    3 ++-
 drivers/video/mxsfb.c                  |    8 +++++---
 2 files changed, 7 insertions(+), 4 deletions(-)
arch/arm/mach-mxs/include/mach/mxsfb.h +2 -1
index 923f397..e4d7979 100644
@@ -24,7 +24,8 @@
 #define STMLCDIF_18BIT 2 /** pixel data bus to the display is of 18 bit width */
 #define STMLCDIF_24BIT 3 /** pixel data bus to the display is of 24 bit width */
 
-#define FB_SYNC_DATA_ENABLE_HIGH_ACT	64
+#define FB_SYNC_DATA_ENABLE_HIGH_ACT	(1 << 6)
+#define FB_SYNC_DOTCLK_FAILING_ACT	(1 << 7) /* failing/negtive edge sampling */
 
 struct mxsfb_platform_data {
 	struct fb_videomode *mode_list;
drivers/video/mxsfb.c +5 -3
index 927a682..0555671 100644
@@ -103,8 +103,8 @@
 #define VDCTRL0_ENABLE_PRESENT		(1 << 28)
 #define VDCTRL0_VSYNC_ACT_HIGH		(1 << 27)
 #define VDCTRL0_HSYNC_ACT_HIGH		(1 << 26)
-#define VDCTRL0_DOTCLK_ACTIVE_HIGH	(1 << 25)
-#define VDCTRL0_POL_ACTIVE_HIGH		(1 << 24)
+#define VDCTRL0_DOTCLK_ACT_FAILING	(1 << 25)
+#define VDCTRL0_ENABLE_ACT_HIGH		(1 << 24)
 #define VDCTRL0_VSYNC_PERIOD_UNIT	(1 << 21)
 #define VDCTRL0_VSYNC_PULSE_WIDTH_UNIT	(1 << 20)
 #define VDCTRL0_HALF_LINE		(1 << 19)
@@ -452,7 +452,9 @@ static int mxsfb_set_par(struct fb_info *fb_info)
 	if (fb_info->var.sync & FB_SYNC_VERT_HIGH_ACT)
 		vdctrl0 |= VDCTRL0_VSYNC_ACT_HIGH;
 	if (fb_info->var.sync & FB_SYNC_DATA_ENABLE_HIGH_ACT)
-		vdctrl0 |= VDCTRL0_POL_ACTIVE_HIGH;
+		vdctrl0 |= VDCTRL0_ENABLE_ACT_HIGH;
+	if (fb_info->var.sync & FB_SYNC_DOTCLK_FAILING_ACT)
+		vdctrl0 |= VDCTRL0_DOTCLK_ACT_FAILING;
 
 	writel(vdctrl0, host->base + LCDC_VDCTRL0);
 
Signature · 1 line
1.7.1
#8 lore raw

PATCH 3/3 video: mxsfb: add DOTCLK polarity configuration support

Hello,

Quoted 6 lines · Shawn Guo

The current implementation provides configuration for HSYNC_POL, VSYNC_POL and ENABLE_POL via 'sync' of fb_videomode, but DOTCLK_POL is missing there. It's assuming that data sampling at rising/positive edge is always the case. However, it's not true. For example, the panel on mx28evk board (Seiko 43WVF1G) samples data at failing/negative edge. The patch is to add this configuration.

s/failing/falling?

Quoted 20 lines

Also, to unify the naming schema of all these polarity configurations and match them with the bits name in Reference Manual, a couple of definitions are renamed.

Lastly, to reduce the chance of defining customized 'FB_SYNC_' flag by incrementing the preceeding value, the definitions are changed to bit shifting way.

---
 arch/arm/mach-mxs/include/mach/mxsfb.h |    3 ++-
 drivers/video/mxsfb.c                  |    8 +++++---
 2 files changed, 7 insertions(+), 4 deletions(-)
arch/arm/mach-mxs/include/mach/mxsfb.h +0 -0
index 923f397..e4d7979 100644

arch/arm/mach-mxs/include/mach/mxsfb.h line 28

Quoted 6 lines
arch/arm/mach-mxs/include/mach/mxsfb.h +2 -1
@@ -24,7 +24,8 @@
 #define STMLCDIF_18BIT 2 /** pixel data bus to the display is of 18 bit width */
 #define STMLCDIF_24BIT 3 /** pixel data bus to the display is of 24 bit width */
 
-#define FB_SYNC_DATA_ENABLE_HIGH_ACT	64
+#define FB_SYNC_DATA_ENABLE_HIGH_ACT	(1 << 6)
+#define FB_SYNC_DOTCLK_FAILING_ACT	(1 << 7) /* failing/negtive edge sampling */

ditto + s/negtive/negative/

As your patch is already in mainline, do you care to send a followup?

Best regards
Uwe

Signature · 2 lines
Pengutronix e.K.                           | Uwe Kleine-K?nig            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
author
#9 lore raw

PATCH 3/3 video: mxsfb: add DOTCLK polarity configuration support

Quoted 34 lines · Uwe Kleine-K?nig

Hello,

Quoted 6 lines · Shawn Guo

The current implementation provides configuration for HSYNC_POL, VSYNC_POL and ENABLE_POL via 'sync' of fb_videomode, but DOTCLK_POL is missing there. It's assuming that data sampling at rising/positive edge is always the case. However, it's not true. For example, the panel on mx28evk board (Seiko 43WVF1G) samples data at failing/negative edge. The patch is to add this configuration.

s/failing/falling?

Quoted 23 lines

Also, to unify the naming schema of all these polarity configurations and match them with the bits name in Reference Manual, a couple of definitions are renamed.

Lastly, to reduce the chance of defining customized 'FB_SYNC_' flag by incrementing the preceeding value, the definitions are changed to bit shifting way.

---
 arch/arm/mach-mxs/include/mach/mxsfb.h |    3 ++-
 drivers/video/mxsfb.c                  |    8 +++++---
 2 files changed, 7 insertions(+), 4 deletions(-)
arch/arm/mach-mxs/include/mach/mxsfb.h +0 -0
index 923f397..e4d7979 100644
@@ -24,7 +24,8 @@
 #define STMLCDIF_18BIT 2 /** pixel data bus to the display is of 18 bit width */
 #define STMLCDIF_24BIT 3 /** pixel data bus to the display is of 24 bit width */
 
Quoted 7 lines

arch/arm/mach-mxs/include/mach/mxsfb.h line 28

Quoted 3 lines
arch/arm/mach-mxs/include/mach/mxsfb.h +2 -1
-#define FB_SYNC_DATA_ENABLE_HIGH_ACT	64
+#define FB_SYNC_DATA_ENABLE_HIGH_ACT	(1 << 6)
+#define FB_SYNC_DOTCLK_FAILING_ACT	(1 << 7) /* failing/negtive edge sampling */

ditto + s/negtive/negative/

As your patch is already in mainline, do you care to send a followup?

It depends on if Sascha would pick up this follow-up. I feel that he may not care too much about such cosmetic patch.

Signature · 2 lines
Regards,
Shawn
#10 lore raw

PATCH 3/3 video: mxsfb: add DOTCLK polarity configuration support

Hi,

Quoted 35 lines · Shawn Guo
Quoted 34 lines · Uwe Kleine-K?nig

Hello,

Quoted 6 lines · Shawn Guo

The current implementation provides configuration for HSYNC_POL, VSYNC_POL and ENABLE_POL via 'sync' of fb_videomode, but DOTCLK_POL is missing there. It's assuming that data sampling at rising/positive edge is always the case. However, it's not true. For example, the panel on mx28evk board (Seiko 43WVF1G) samples data at failing/negative edge. The patch is to add this configuration.

s/failing/falling?

Quoted 23 lines

Also, to unify the naming schema of all these polarity configurations and match them with the bits name in Reference Manual, a couple of definitions are renamed.

Lastly, to reduce the chance of defining customized 'FB_SYNC_' flag by incrementing the preceeding value, the definitions are changed to bit shifting way.

---
 arch/arm/mach-mxs/include/mach/mxsfb.h |    3 ++-
 drivers/video/mxsfb.c                  |    8 +++++---
 2 files changed, 7 insertions(+), 4 deletions(-)
arch/arm/mach-mxs/include/mach/mxsfb.h +0 -0
index 923f397..e4d7979 100644
@@ -24,7 +24,8 @@
 #define STMLCDIF_18BIT 2 /** pixel data bus to the display is of 18 bit width */
 #define STMLCDIF_24BIT 3 /** pixel data bus to the display is of 24 bit width */
 
Quoted 4 lines
Quoted 3 lines

arch/arm/mach-mxs/include/mach/mxsfb.h line 28

Quoted 3 lines
arch/arm/mach-mxs/include/mach/mxsfb.h +2 -1
-#define FB_SYNC_DATA_ENABLE_HIGH_ACT	64
+#define FB_SYNC_DATA_ENABLE_HIGH_ACT	(1 << 6)
+#define FB_SYNC_DOTCLK_FAILING_ACT	(1 << 7) /* failing/negtive edge sampling */

s/FAILING/FALLING/

Lothar Wa?mann

Signature · 9 lines
___________________________________________________________

Ka-Ro electronics GmbH | Pascalstra?e 22 | D - 52076 Aachen
Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
Gesch?ftsf?hrer: Matthias Kaussen
Handelsregistereintrag: Amtsgericht Aachen, HRB 4996

www.karo-electronics.de | info at karo-electronics.de
___________________________________________________________
author
#11 lore raw

PATCH 3/3 video: mxsfb: add DOTCLK polarity configuration support

Quoted 38 lines · Lothar Wa?mann

Hi,

Quoted 35 lines · Shawn Guo
Quoted 34 lines · Uwe Kleine-K?nig

Hello,

Quoted 6 lines · Shawn Guo

The current implementation provides configuration for HSYNC_POL, VSYNC_POL and ENABLE_POL via 'sync' of fb_videomode, but DOTCLK_POL is missing there. It's assuming that data sampling at rising/positive edge is always the case. However, it's not true. For example, the panel on mx28evk board (Seiko 43WVF1G) samples data at failing/negative edge. The patch is to add this configuration.

s/failing/falling?

Quoted 23 lines

Also, to unify the naming schema of all these polarity configurations and match them with the bits name in Reference Manual, a couple of definitions are renamed.

Lastly, to reduce the chance of defining customized 'FB_SYNC_' flag by incrementing the preceeding value, the definitions are changed to bit shifting way.

---
 arch/arm/mach-mxs/include/mach/mxsfb.h |    3 ++-
 drivers/video/mxsfb.c                  |    8 +++++---
 2 files changed, 7 insertions(+), 4 deletions(-)
arch/arm/mach-mxs/include/mach/mxsfb.h +0 -0
index 923f397..e4d7979 100644
@@ -24,7 +24,8 @@
 #define STMLCDIF_18BIT 2 /** pixel data bus to the display is of 18 bit width */
 #define STMLCDIF_24BIT 3 /** pixel data bus to the display is of 24 bit width */
 
Quoted 6 lines
Quoted 4 lines
Quoted 3 lines

arch/arm/mach-mxs/include/mach/mxsfb.h line 28

Quoted 3 lines
arch/arm/mach-mxs/include/mach/mxsfb.h +2 -1
-#define FB_SYNC_DATA_ENABLE_HIGH_ACT	64
+#define FB_SYNC_DATA_ENABLE_HIGH_ACT	(1 << 6)
+#define FB_SYNC_DOTCLK_FAILING_ACT	(1 << 7) /* failing/negtive edge sampling */

s/FAILING/FALLING/

OK, since so many people care, let me send a patch to test Sascha.

Signature · 2 lines
Regards,
Shawn
#12 lore raw

PATCH 3/3 video: mxsfb: add DOTCLK polarity configuration support

In reply to Lothar Waßmann
Quoted 38 lines · Lothar Wa?mann

Hi,

Quoted 35 lines · Shawn Guo
Quoted 34 lines · Uwe Kleine-K?nig

Hello,

Quoted 6 lines · Shawn Guo

The current implementation provides configuration for HSYNC_POL, VSYNC_POL and ENABLE_POL via 'sync' of fb_videomode, but DOTCLK_POL is missing there. It's assuming that data sampling at rising/positive edge is always the case. However, it's not true. For example, the panel on mx28evk board (Seiko 43WVF1G) samples data at failing/negative edge. The patch is to add this configuration.

s/failing/falling?

Quoted 23 lines

Also, to unify the naming schema of all these polarity configurations and match them with the bits name in Reference Manual, a couple of definitions are renamed.

Lastly, to reduce the chance of defining customized 'FB_SYNC_' flag by incrementing the preceeding value, the definitions are changed to bit shifting way.

---
 arch/arm/mach-mxs/include/mach/mxsfb.h |    3 ++-
 drivers/video/mxsfb.c                  |    8 +++++---
 2 files changed, 7 insertions(+), 4 deletions(-)
arch/arm/mach-mxs/include/mach/mxsfb.h +0 -0
index 923f397..e4d7979 100644
@@ -24,7 +24,8 @@
 #define STMLCDIF_18BIT 2 /** pixel data bus to the display is of 18 bit width */
 #define STMLCDIF_24BIT 3 /** pixel data bus to the display is of 24 bit width */
 
Quoted 5 lines
Quoted 4 lines
Quoted 3 lines

arch/arm/mach-mxs/include/mach/mxsfb.h line 28

Quoted 3 lines
arch/arm/mach-mxs/include/mach/mxsfb.h +2 -1
-#define FB_SYNC_DATA_ENABLE_HIGH_ACT	64
+#define FB_SYNC_DATA_ENABLE_HIGH_ACT	(1 << 6)
+#define FB_SYNC_DOTCLK_FAILING_ACT	(1 << 7) /* failing/negtive edge sampling */

s/FAILING/FALLING/

I implicitly wanted that and tried to express that with my ditto. IMHO the macro name is the main reason for me to fix it.

Best regards
Uwe

Signature · 2 lines
Pengutronix e.K.                           | Uwe Kleine-K?nig            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
author
#13 lore raw

PATCH 1/1 video: mxsfb: correct typo 'FAILING' to 'FALLING'

In reply to Uwe Kleine-König

---
The patch should probably be split into two to separate machine code changes from driver ones, but that will result in build failure, which could be a problem for bisect, so I keep them as one patch.

 arch/arm/mach-mxs/include/mach/mxsfb.h |    2 +-
 arch/arm/mach-mxs/mach-mx23evk.c       |    2 +-
 arch/arm/mach-mxs/mach-mx28evk.c       |    2 +-
 drivers/video/mxsfb.c                  |    6 +++---
 4 files changed, 6 insertions(+), 6 deletions(-)
arch/arm/mach-mxs/include/mach/mxsfb.h +1 -1
index e4d7979..491787e 100644
@@ -25,7 +25,7 @@
 #define STMLCDIF_24BIT 3 /** pixel data bus to the display is of 24 bit width */
 
 #define FB_SYNC_DATA_ENABLE_HIGH_ACT	(1 << 6)
-#define FB_SYNC_DOTCLK_FAILING_ACT	(1 << 7) /* failing/negtive edge sampling */
+#define FB_SYNC_DOTCLK_FALLING_ACT	(1 << 7) /* falling/negtive edge sampling */
 
 struct mxsfb_platform_data {
 	struct fb_videomode *mode_list;
arch/arm/mach-mxs/mach-mx23evk.c +1 -1
index 214e5b6..bcf24c1 100644
@@ -122,7 +122,7 @@ static struct fb_videomode mx23evk_video_modes[] = {
 		.hsync_len	= 1,
 		.vsync_len	= 1,
 		.sync		= FB_SYNC_DATA_ENABLE_HIGH_ACT |
-				  FB_SYNC_DOTCLK_FAILING_ACT,
+				  FB_SYNC_DOTCLK_FALLING_ACT,
 	},
 };
 
arch/arm/mach-mxs/mach-mx28evk.c +1 -1
index bb329b9..9753e85 100644
@@ -311,7 +311,7 @@ static struct fb_videomode mx28evk_video_modes[] = {
 		.hsync_len	= 10,
 		.vsync_len	= 10,
 		.sync		= FB_SYNC_DATA_ENABLE_HIGH_ACT |
-				  FB_SYNC_DOTCLK_FAILING_ACT,
+				  FB_SYNC_DOTCLK_FALLING_ACT,
 	},
 };
 
drivers/video/mxsfb.c +3 -3
index 7d02848..aa27231 100644
@@ -103,7 +103,7 @@
 #define VDCTRL0_ENABLE_PRESENT		(1 << 28)
 #define VDCTRL0_VSYNC_ACT_HIGH		(1 << 27)
 #define VDCTRL0_HSYNC_ACT_HIGH		(1 << 26)
-#define VDCTRL0_DOTCLK_ACT_FAILING	(1 << 25)
+#define VDCTRL0_DOTCLK_ACT_FALLING	(1 << 25)
 #define VDCTRL0_ENABLE_ACT_HIGH		(1 << 24)
 #define VDCTRL0_VSYNC_PERIOD_UNIT	(1 << 21)
 #define VDCTRL0_VSYNC_PULSE_WIDTH_UNIT	(1 << 20)
@@ -453,8 +453,8 @@ static int mxsfb_set_par(struct fb_info *fb_info)
 		vdctrl0 |= VDCTRL0_VSYNC_ACT_HIGH;
 	if (fb_info->var.sync & FB_SYNC_DATA_ENABLE_HIGH_ACT)
 		vdctrl0 |= VDCTRL0_ENABLE_ACT_HIGH;
-	if (fb_info->var.sync & FB_SYNC_DOTCLK_FAILING_ACT)
-		vdctrl0 |= VDCTRL0_DOTCLK_ACT_FAILING;
+	if (fb_info->var.sync & FB_SYNC_DOTCLK_FALLING_ACT)
+		vdctrl0 |= VDCTRL0_DOTCLK_ACT_FALLING;
 
 	writel(vdctrl0, host->base + LCDC_VDCTRL0);
 
Signature · 1 line
1.7.1
#14 lore raw

PATCH 1/1 video: mxsfb: correct typo 'FAILING' to 'FALLING'

Quoted 5 lines · Shawn Guo

---
The patch should probably be split into two to separate machine code changes from driver ones, but that will result in build failure, which could be a problem for bisect, so I keep them as one patch.

to prevent that (and if you really care) you need to add a

#define FB_SYNC_DOTCLK_FAILING_ACT FB_SYNC_DOTCLK_FALLING_ACT

in the first patch, then fix all users and then remove the #define again. But IMHO it's totally OK to do it in one step since all files touched are in a single maintainer's responsibility.
(At least drivers/video/mxsfb.c went in via Sascha's tree, too.)

Best regards
Uwe

Quoted 5 lines
 arch/arm/mach-mxs/include/mach/mxsfb.h |    2 +-
 arch/arm/mach-mxs/mach-mx23evk.c       |    2 +-
 arch/arm/mach-mxs/mach-mx28evk.c       |    2 +-
 drivers/video/mxsfb.c                  |    6 +++---
 4 files changed, 6 insertions(+), 6 deletions(-)
Signature · 2 lines
Pengutronix e.K.                           | Uwe Kleine-K?nig            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
maintainer
#15 lore raw
In reply to Shawn Guo

Hi Shawn,

Quoted 6 lines · Shawn Guo

The patches came from the work of adding framebuffer for mx28evk and mx23evk boards. They are all minor changes.

[PATCH 1/3] video: mxsfb: smarten the code a little bit
[PATCH 2/3] video: mxsfb: fix the incorrect error checking for alloc_pages_exact [PATCH 3/3] video: mxsfb: add DOTCLK polarity configuration support

As this driver is new, we can squash these patches into the original patch and add your ack to this one, if that's ok for you.

Sascha

Signature · 4 lines
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |
author
#16 lore raw
Quoted 2 lines · Sascha Hauer

Hi Shawn,

Hi Sascha,

Quoted 11 lines · Shawn Guo
Quoted 6 lines

The patches came from the work of adding framebuffer for mx28evk and mx23evk boards. They are all minor changes.

[PATCH 1/3] video: mxsfb: smarten the code a little bit
[PATCH 2/3] video: mxsfb: fix the incorrect error checking for alloc_pages_exact [PATCH 3/3] video: mxsfb: add DOTCLK polarity configuration support

As this driver is new, we can squash these patches into the original patch and add your ack to this one, if that's ok for you.

No problem, as they are really some simple changes.

Signature · 2 lines
Regards,
Shawn