X on UEFI systems.

Vasily Levchenko vasily.v.levchenko at gmail.com
Thu Dec 10 07:31:51 UTC 2009


On Dec 10, 2009, at 8:06 AM, Dave Airlie wrote:

> On Thu, 2009-12-10 at 07:32 +0300, Vasily Levchenko wrote:
>> Hi, folks.
>> 
>> 
>> Currently at Virtualbox has introduced UEFI support in 3.1 release.
>> But there is one issue with X server. When trying configure X with
>> -configure. Resulted xorg.conf.new looks right except missed Modes.
>> Observing code I've supposed that missed information should be somehow
>> fetched from screen info (prepared by EFIFB)
>> via ioctl(..,FBIOGET_FSCREENINFO,...), but for some reasons it isn't
>> called and doing strace of X -configure the /dev/fb0 is open and than
>> immediately closed ([pastebin.org]). So the question is what should be
>> added in VirtualBox/UEFI firmware to get full xorg.conf? 
>> 
> 
> Does it not work without an xorg.conf, that would be the first goal.
> 
Right, ability to work with built-in config would be excellent  :).
I've debugged X and X -configure and noticed in both cases 

#0  fbdev_open (scrnIndex=<value optimized out>, dev=0x1501fc "/dev/fb0", namep=0x0) at fbdevhw.c:412
#1  0x0014fc80 in fbdevHWProbe (pPci=0x0, device=0x0, namep=0x0) at fbdevhw.c:442
#2  0x00c5e4b5 in FBDevProbe (drv=0x8236b00, flags=<value optimized out>) at fbdev.c:394
#3  0x080a7c4e in xf86CallDriverProbe (drv=0x8236b00, detect_only=0) at xf86Init.c:663
#4  0x080a92fe in InitOutput (pScreenInfo=0x8212500, argc=1, argv=0xbfd96fc4) at xf86Init.c:939
#5  0x0806ba2b in main (argc=1, argv=0xbfd96fc4, envp=0xbfd96fcc) at main.c:315


fbdev_open called with namep = 0, that blocks fetch information from efifb 

if (namep) {
            if (-1 == ioctl(fd,FBIOGET_FSCREENINFO,(void*)(&fix))) {
                *namep = NULL;
                xf86DrvMsg(scrnIndex, X_ERROR,
                           "FBIOGET_FSCREENINFO: %s\n", strerror(errno));
                return -1;
            } else {
                *namep = xnfalloc(16);
                strncpy(*namep,fix.id,16);
            }
        }

calling right ioctl from gdb:
(gdb) call ioctl(fd,0x4602,(void*)(&fix))
$2 = 0
(gdb) p fix
$3 = {id = "EFI VGA\0\0\0\0\0\0\0\0", smem_start = 0x80000000 <Address 0x80000000 out of bounds>, smem_len = 6291456, type = 0, 
  type_aux = 0, visual = 2, xpanstep = 0, ypanstep = 0, ywrapstep = 0, line_length = 4096, mmio_start = 0x0, mmio_len = 0, accel = 0, 
  reserved = {0, 0, 0}}
shows that efifb prepared right information for frame buffer clients.

the difference between X and X -configure, is vesa driver (it seems)  tries to occur  information via libint10, assuming existence of VGA BIOS, which ofc is absent in our case.

(II) Loading sub module "vbe"
(II) LoadModule: "vbe"
(II) Loading /usr/lib/xorg/modules//libvbe.so
(II) Module vbe: vendor="X.Org Foundation"
        compiled for 1.6.3.901, module version = 1.1.0
        ABI class: X.Org Video Driver, version 5.0
(II) Loading sub module "int10"
(II) LoadModule: "int10"
(II) Loading /usr/lib/xorg/modules//libint10.so
(II) Module int10: vendor="X.Org Foundation"
        compiled for 1.6.3.901, module version = 1.0.0
        ABI class: X.Org Video Driver, version 5.0
(II) VESA(0): initializing int10
(EE) VESA(0): V_BIOS address 0x0 out of range
(II) UnloadModule: "vesa"
(II) UnloadModule: "int10"
(II) Unloading /usr/lib/xorg/modules//libint10.so
(II) UnloadModule: "vbe"
(II) Unloading /usr/lib/xorg/modules//libvbe.so
(EE) Screen(s) found, but none have a usable configuration.

> Dave.
> 
> 
> 
> -- 
> fedora-devel-list mailing list
> fedora-devel-list at redhat.com
> https://www.redhat.com/mailman/listinfo/fedora-devel-list

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/fedora-devel-list/attachments/20091210/cbd583c0/attachment.htm>


More information about the fedora-devel-list mailing list