Framebuffer throuble under xserver

Francesco Piraneo G.
NOTE: Tried to post the log as an attachment but the server returned this
error: "Attachment to large or wrong type. (max 11 MB)" the log is about
5kb...

Hi gentleman!

I'm still trying to build the x11-gpe-image recipe under openembedded;
recipe itself build successfully but the throuble is about the framebuffer
configuration... I suppose.

I obviously applied all the patches suggested on the other threads but with
no result at all. So I'm lost.

Actually here is what my Xorg.log say:

------------------------------------
Current version of pixman: 0.18.2
        Before reporting problems, check http://wiki.x.org
        to make sure that you have the latest version.
Markers: (--) probed, (**) from config file, (==) default setting,
        (++) from command line, (!!) notice, (II) informational,
        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Mon Aug  9 16:59:04 2010
(==) Using config file: "/etc/X11/xorg.conf"
(==) No Layout section.  Using the first Screen section.
(==) No screen section available. Using defaults.
(**) |-->Screen "Default Screen Section" (0)
(**) |   |-->Monitor "<default monitor>"
(==) No monitor specified for screen "Default Screen Section".
        Using a default monitor configuration.
(==) Automatically adding devices
(==) Automatically enabling devices
(WW) The directory "/usr/share/fonts/X11/misc" does not exist.
        Entry deleted from font path.
(==) FontPath set to:

(==) ModulePath set to "/usr/lib/xorg/modules"
(II) Cannot locate a core pointer device.
(II) Cannot locate a core keyboard device.
(II) The server relies on HAL to provide the list of input devices.
        If no devices become available, reconfigure HAL or disable
AutoAddDevices.
(II) Loader magic: 0x1965e8
(II) Module ABI versions:
        X.Org ANSI C Emulation: 0.4
        X.Org Video Driver: 6.0
        X.Org XInput driver : 7.0
        X.Org Server Extension : 2.0
(--) using VT number 3

(II) LoadModule: "extmod"
(II) Loading /usr/lib/xorg/modules/extensions/libextmod.so
(II) Module extmod: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 1.0.0
        Module class: X.Org Server Extension
        ABI class: X.Org Server Extension, version 2.0
(II) Loading extension MIT-SCREEN-SAVER
(II) Loading extension XFree86-VidModeExtension
(II) Loading extension XFree86-DGA
(II) Loading extension DPMS
(II) Loading extension XVideo
(II) Loading extension XVideo-MotionCompensation
(II) Loading extension X-Resource
(II) LoadModule: "dbe"
(II) Loading /usr/lib/xorg/modules/extensions/libdbe.so
(II) Module dbe: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 1.0.0
        Module class: X.Org Server Extension
        ABI class: X.Org Server Extension, version 2.0
(II) Loading extension DOUBLE-BUFFER
(II) LoadModule: "glx"
(II) Loading /usr/lib/xorg/modules/extensions/libglx.so
(II) Module glx: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 1.0.0
        ABI class: X.Org Server Extension, version 2.0
(==) AIGLX enabled
(II) Loading extension GLX
(II) LoadModule: "dri"
(II) Loading /usr/lib/xorg/modules/extensions/libdri.so
(II) Module dri: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 1.0.0
        ABI class: X.Org Server Extension, version 2.0
(II) Loading extension XFree86-DRI
(II) LoadModule: "dri2"
(II) Loading /usr/lib/xorg/modules/extensions/libdri2.so
(II) Module dri2: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 1.1.0
        ABI class: X.Org Server Extension, version 2.0
(II) Loading extension DRI2
Primary device is not PCI
(==) Matched fbdev for the autoconfigured driver
(==) Assigned the driver to the xf86ConfigLayout
(II) LoadModule: "fbdev"
(II) Loading /usr/lib/xorg/modules/drivers/fbdev_drv.so
(II) Module fbdev: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 0.4.2
        ABI class: X.Org Video Driver, version 6.0
(II) FBDEV: driver for framebuffer: fbdev
(WW) Falling back to old probe method for fbdev
(II) Loading sub module "fbdevhw"
(II) LoadModule: "fbdevhw"
(II) Loading /usr/lib/xorg/modules/linux/libfbdevhw.so
(II) Module fbdevhw: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 0.0.2
        ABI class: X.Org Video Driver, version 6.0
(II) FBDEV(0): using default device
(WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
(II) Running in FRAMEBUFFER Mode
(II) FBDEV(0): Creating default Display subsection in Screen section
        "Default Screen Section" for depth/fbbpp 16/16
(==) FBDEV(0): Depth 16, (==) framebuffer bpp 16
(==) FBDEV(0): RGB weight 565
(==) FBDEV(0): Default visual is TrueColor
(==) FBDEV(0): Using gamma correction (1.0, 1.0, 1.0)
(II) FBDEV(0): hardware: s3c2410fb (video memory: 150kB)
(II) FBDEV(0): checking modes against framebuffer device...
(II) FBDEV(0): checking modes against monitor...
(--) FBDEV(0): Virtual size is 240x320 (pitch 240)
(**) FBDEV(0):  Built-in mode "current": 5.5 MHz, 18.7 kHz, 57.1 Hz
(II) FBDEV(0): Modeline "current"x0.0    5.47  240 265 271 292  320 324 326
328 -hsync -vsync -csync (18.7 kHz)
(++) FBDEV(0): DPI set to (100, 100)
(II) Loading sub module "fb"
(II) LoadModule: "fb"
(II) Loading /usr/lib/xorg/modules/libfb.so
(II) Module fb: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 1.0.0
        ABI class: X.Org ANSI C Emulation, version 0.4
(**) FBDEV(0): using shadow framebuffer
(II) Loading sub module "shadow"
(II) LoadModule: "shadow"
(II) Loading /usr/lib/xorg/modules/libshadow.so
(II) Module shadow: vendor="X.Org Foundation"
        compiled for 1.7.4, module version = 1.1.0
        ABI class: X.Org ANSI C Emulation, version 0.4
(EE) FBDEV(0): FBIOPUT_VSCREENINFO: Invalid argument
(EE) FBDEV(0): mode initialization failed

Fatal server error:
AddScreen/ScreenInit failed for driver 0
---------------------------------

Because launching the 'fbset -i' command the reported data are as follows:

---------------------------------
mode "240x320-57"
        # D: 5.473 MHz, H: 18.743 kHz, V: 57.143 Hz
        geometry 240 320 240 320 16
        timings 182718 21 25 2 4 6 2
        accel false
        rgba 5/11,6/5,5/0,0/0
endmode
---------------------------------

I modified the patches as follows:

---------------------------------
--- xorg-server-1.7.4/hw/kdrive/src/kmode.c  2010-01-07 23:44:56.000000000
+0100
+++ xorg-server-1.7.4/hw/kdrive/src/kmode.c.mini2440  2010-08-09
12:04:21.461851526 +0200
@@ -30,6 +30,14 @@
     /*  H  V  Hz  KHz */
     /*  FP      BP      BLANK   POLARITY */
 
+    /*
+     * Mini2440 modeline "240x320"
+     */
+    {   240,    320,    57,     0,
+            0,      0,      0,     KdSyncNegative,
+            0,      0,      0,     KdSyncNegative,
+    },
+
     /* IPAQ modeline:
      *
      * Modeline "320x240"      5.7222 320 337 340 352   240 241 244 254"
@@ -89,7 +97,13 @@
         1,      21,      25,      KdSyncPositive, /* 75.000 */
     },
     /* DEFAULT */
-#define MONITOR_TIMING_DEFAULT  9
+
+/* Eliminated due to patch for Mini2440
+ * #define MONITOR_TIMING_DEFAULT  9
+ * The line below was inserted
+ */
+    #define MONITOR_TIMING_DEFAULT 0
+
     {  800,  600,  72,  50000,          /* VESA */
         56,      64,      240,    KdSyncPositive, /* 48.077 */
         37,      23,      66,      KdSyncPositive, /* 72.188 */
----------------------------

--- xserver/hw/kdrive/fbdev/fbdev.c.old  2010-08-07 15:57:12.777996265
+0200
+++ xserver/hw/kdrive/fbdev/fbdev.c  2010-08-07 15:54:45.499294508 +0200
@@ -665,12 +665,14 @@
     priv->var.activate = FB_ACTIVATE_NOW|FB_CHANGE_CMAP_VBL;
     
     /* display it on the LCD */
+/* Mini2440 patch 
     k = ioctl (priv->fd, FBIOPUT_VSCREENINFO, &priv->var);
     if (k < 0)
     {
   perror ("FBIOPUT_VSCREENINFO");
   return FALSE;
     }
+END mini2440 patch */
     
     if (priv->fix.visual == FB_VISUAL_DIRECTCOLOR)
     {
----------------------------

May be some expert people has more ideas about?

Thank a lot!
Francesco

Robbie
I've got the excast same error..
Have you ever find it out?

GWell
You must to repair the fbmem.c archive