Skip to contentSkip to conversation

video: mxsfb: Adapt to new videomode API

PATCH New Fabio Estevam 4 participants 10 messages Apr 9, 2013 – Apr 12, 2013

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

commit 6cd2c7db4 (videomode: videomode_from_timing work) changed the name of the function from videomode_from_timing() to videomode_from_timings().

commit 32ed6ef1 (videomode: create enum for videomode's display flags) changed the 'data_flags' field in videomode structure to 'flags'

Adapt to these changes in order to fix the following errors:

drivers/video/mxsfb.c:761:3: error: too many arguments to function 'videomode_from_timing' drivers/video/mxsfb.c:761:7: error: void value not ignored as it ought to be drivers/video/mxsfb.c:768:9: error: 'struct videomode' has no member named 'data_flags' drivers/video/mxsfb.c:770:9: error: 'struct videomode' has no member named 'data_flags'

Also select VIDEOMODE_HELPER in Kconfig to avoid linker errors.

---
 drivers/video/Kconfig |    1 +
 drivers/video/mxsfb.c |    7 ++++---
 2 files changed, 5 insertions(+), 3 deletions(-)
drivers/video/Kconfig +1 -0
index d90e3f5..240f863 100644
@@ -2428,6 +2428,7 @@ config FB_MXS
 	select FB_CFB_IMAGEBLIT
 	select FB_MODE_HELPERS
 	select OF_VIDEOMODE
+	select VIDEOMODE_HELPERS
 	help
 	  Framebuffer support for the MXS SoC.
 
drivers/video/mxsfb.c +4 -3
index eac7c1a..fb559f3 100644
@@ -43,6 +43,7 @@
 #include <linux/kernel.h>
 #include <linux/of_device.h>
 #include <linux/of_gpio.h>
+#include <video/display_timing.h>
 #include <video/of_display_timing.h>
 #include <linux/platform_device.h>
 #include <linux/clk.h>
@@ -758,16 +759,16 @@ static int mxsfb_init_fbinfo_dt(struct mxsfb_info *host)
 		struct videomode vm;
 		struct fb_videomode fb_vm;
 
-		ret = videomode_from_timing(timings, &vm, i);
+		ret = videomode_from_timings(timings, &vm, i);
 		if (ret < 0)
 			goto put_timings_node;
 		ret = fb_videomode_from_videomode(&vm, &fb_vm);
 		if (ret < 0)
 			goto put_timings_node;
 
-		if (vm.data_flags & DISPLAY_FLAGS_DE_HIGH)
+		if (vm.flags & DISPLAY_FLAGS_DE_HIGH)
 			host->sync |= MXSFB_SYNC_DATA_ENABLE_HIGH_ACT;
-		if (vm.data_flags & DISPLAY_FLAGS_PIXDATA_NEGEDGE)
+		if (vm.flags & DISPLAY_FLAGS_PIXDATA_NEGEDGE)
 			host->sync |= MXSFB_SYNC_DOTCLK_FALLING_ACT;
 		fb_add_videomode(&fb_vm, &fb_info->modelist);
 	}
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

Quoted 8 lines · Fabio Estevam

commit 6cd2c7db4 (videomode: videomode_from_timing work) changed the name of the function from videomode_from_timing() to videomode_from_timings().

commit 32ed6ef1 (videomode: create enum for videomode's display flags) changed the 'data_flags' field in videomode structure to 'flags'

Adapt to these changes in order to fix the following errors:

Quoted 8 lines

drivers/video/mxsfb.c:761:3: error: too many arguments to function 'videomode_from_timing' drivers/video/mxsfb.c:761:7: error: void value not ignored as it ought to be drivers/video/mxsfb.c:768:9: error: 'struct videomode' has no member named 'data_flags' drivers/video/mxsfb.c:770:9: error: 'struct videomode' has no member named 'data_flags'

Also select VIDEOMODE_HELPER in Kconfig to avoid linker errors.

The mxsfb.c driver in my tree does not contain such code. Where is this patch meant to be applied?

Tomi

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 899 bytes
Desc: OpenPGP digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20130410/3fb26f04/attachment.sig>

reviewer
#2 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

Quoted 2 lines · Tomi Valkeinen

The mxsfb.c driver in my tree does not contain such code. Where is this patch meant to be applied?

linux-next 20130408 is broken for mxs without this fix. Maybe Shawn can take it?

#3 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

Quoted 6 lines · Fabio Estevam
Quoted 2 lines · Tomi Valkeinen

The mxsfb.c driver in my tree does not contain such code. Where is this patch meant to be applied?

linux-next 20130408 is broken for mxs without this fix. Maybe Shawn can take it?

I will take it and send it during -rc when Tomi's patches hit mainline. But I have a couple trivial comments on the patch. I'm replying to the patch.

Shawn

#4 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

Quoted 11 lines · Shawn Guo
Quoted 6 lines · Fabio Estevam
Quoted 2 lines · Tomi Valkeinen

The mxsfb.c driver in my tree does not contain such code. Where is this patch meant to be applied?

linux-next 20130408 is broken for mxs without this fix. Maybe Shawn can take it?

I will take it and send it during -rc when Tomi's patches hit mainline. But I have a couple trivial comments on the patch. I'm replying to the patch.

Fine by me, but wouldn't it be easier to get the mxsfb driver changes along with other fbdev changes via my tree? Or do you have dependencies to arch changes or such in the mxsfb changes?

Tomi

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 899 bytes
Desc: OpenPGP digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20130412/1a249917/attachment.sig>

#5 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

Quoted 3 lines · Tomi Valkeinen

Fine by me, but wouldn't it be easier to get the mxsfb driver changes along with other fbdev changes via my tree? Or do you have dependencies to arch changes or such in the mxsfb changes?

I have mach-mxs patches removing auxdata depending on the mxsfb changes.

Shawn

#6 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

Quoted 6 lines · Shawn Guo
Quoted 3 lines · Tomi Valkeinen

Fine by me, but wouldn't it be easier to get the mxsfb driver changes along with other fbdev changes via my tree? Or do you have dependencies to arch changes or such in the mxsfb changes?

I have mach-mxs patches removing auxdata depending on the mxsfb changes.

Ok.

Tomi

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 899 bytes
Desc: OpenPGP digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20130412/5157dbf5/attachment-0001.sig>

#7 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

In reply to Fabio Estevam
Quoted 26 lines · Fabio Estevam

commit 6cd2c7db4 (videomode: videomode_from_timing work) changed the name of the function from videomode_from_timing() to videomode_from_timings().

commit 32ed6ef1 (videomode: create enum for videomode's display flags) changed the 'data_flags' field in videomode structure to 'flags'

Adapt to these changes in order to fix the following errors:

drivers/video/mxsfb.c:761:3: error: too many arguments to function 'videomode_from_timing' drivers/video/mxsfb.c:761:7: error: void value not ignored as it ought to be drivers/video/mxsfb.c:768:9: error: 'struct videomode' has no member named 'data_flags' drivers/video/mxsfb.c:770:9: error: 'struct videomode' has no member named 'data_flags'

Also select VIDEOMODE_HELPER in Kconfig to avoid linker errors.

---
 drivers/video/Kconfig |    1 +
 drivers/video/mxsfb.c |    7 ++++---
 2 files changed, 5 insertions(+), 3 deletions(-)
drivers/video/Kconfig +0 -0
index d90e3f5..240f863 100644

drivers/video/Kconfig config FB_MXS · line 2430

Quoted 3 lines
drivers/video/Kconfig +0 -0
@@ -2428,6 +2428,7 @@ config FB_MXS
 	select FB_CFB_IMAGEBLIT
 	select FB_MODE_HELPERS
 	select OF_VIDEOMODE

OF_VIDEOMODE is dead now, and should be removed.

Quoted 9 lines
drivers/video/Kconfig +1 -0
+	select VIDEOMODE_HELPERS
 	help
 	  Framebuffer support for the MXS SoC.
 
drivers/video/mxsfb.c +0 -0
index eac7c1a..fb559f3 100644

drivers/video/mxsfb.c line 47

Quoted 5 lines
drivers/video/mxsfb.c +1 -0
@@ -43,6 +43,7 @@
 #include <linux/kernel.h>
 #include <linux/of_device.h>
 #include <linux/of_gpio.h>
+#include <video/display_timing.h>
 #include <video/of_display_timing.h>

I messed it up from the beginning. All these <video/*> should be sorted after <linux/*>.

Shawn

Quoted 26 lines
drivers/video/mxsfb.c +3 -3
 #include <linux/platform_device.h>
 #include <linux/clk.h>
@@ -758,16 +759,16 @@ static int mxsfb_init_fbinfo_dt(struct mxsfb_info *host)
 		struct videomode vm;
 		struct fb_videomode fb_vm;
 
-		ret = videomode_from_timing(timings, &vm, i);
+		ret = videomode_from_timings(timings, &vm, i);
 		if (ret < 0)
 			goto put_timings_node;
 		ret = fb_videomode_from_videomode(&vm, &fb_vm);
 		if (ret < 0)
 			goto put_timings_node;
 
-		if (vm.data_flags & DISPLAY_FLAGS_DE_HIGH)
+		if (vm.flags & DISPLAY_FLAGS_DE_HIGH)
 			host->sync |= MXSFB_SYNC_DATA_ENABLE_HIGH_ACT;
-		if (vm.data_flags & DISPLAY_FLAGS_PIXDATA_NEGEDGE)
+		if (vm.flags & DISPLAY_FLAGS_PIXDATA_NEGEDGE)
 			host->sync |= MXSFB_SYNC_DOTCLK_FALLING_ACT;
 		fb_add_videomode(&fb_vm, &fb_info->modelist);
 	}
Signature · 1 line
1.7.9.5
reviewer
#8 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

Quoted 10 lines · Shawn Guo

drivers/video/Kconfig config FB_MXS · line 2430

Quoted 8 lines
drivers/video/Kconfig +0 -0
index d90e3f5..240f863 100644
@@ -2428,6 +2428,7 @@ config FB_MXS
      select FB_CFB_IMAGEBLIT
      select FB_MODE_HELPERS
      select OF_VIDEOMODE

OF_VIDEOMODE is dead now, and should be removed.

Ok, but should I remove this on a separate patch?

#9 lore raw

PATCH 1/1 video: mxsfb: Adapt to new videomode API

Quoted 13 lines · Fabio Estevam
Quoted 10 lines · Shawn Guo

drivers/video/Kconfig config FB_MXS · line 2430

Quoted 8 lines
drivers/video/Kconfig +0 -0
index d90e3f5..240f863 100644
@@ -2428,6 +2428,7 @@ config FB_MXS
      select FB_CFB_IMAGEBLIT
      select FB_MODE_HELPERS
      select OF_VIDEOMODE

OF_VIDEOMODE is dead now, and should be removed.

Quoted 1 line

Ok, but should I remove this on a separate patch?

I do not think so, as VIDEOMODE_HELPER is introduced to just replace OF_VIDEOMODE and a couple of other symbols.

Shawn