[Mesa-users] linux-fbdev

Jamie Amendolagine jamie.amendolagine at gmail.com
Wed Jun 2 09:58:29 PDT 2010


I'm not too familiar with the code, but it does look like the qemu SVGA
driver is lacking the 3D functionality.

Should this work in software mode?

I'm trying this:
export EGL_DRIVER=/usr/local/lib/egl/egl_kms_swrast.so
cd progs/egl
./eglinfo
eglinfo: eglInitialize failed

I seem to get the same with the other egl programs. Maybe I'll try the patch
from here: http://airlied.livejournal.com/69291.html ...



The following is the config that I used:
----------------------------------------------------------
# -*-makefile-*-
# Configuration for linux-dri: Linux DRI hardware drivers for XFree86 &
others

include $(TOP)/configs/default

CONFIG_NAME = linux-dri

# Compiler and flags
CC = i686-linux-uclibc-gcc
CXX = i686-linux-uclibc-g++



#MKDEP = /usr/X11R6/bin/makedepend
#MKDEP = gcc -M
#MKDEP_OPTIONS = -fdepend
-I/root/oryza/neworyzans/output/staging/usr/include
-I/root/oryza/neworyzans/output/staging/usr/includeX11/extensions/
MKDEP_OPTIONS = -fdepend $(SNAP_MKDEP_OPTIONS)

OPT_FLAGS  = -O2 -g
PIC_FLAGS  = -fPIC

# Add '-DGLX_USE_TLS' to ARCH_FLAGS to enable TLS support.
ARCH_FLAGS ?=

DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
    -D_BSD_SOURCE -D_GNU_SOURCE \
    -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER \
    -DGLX_DIRECT_RENDERING -DGLX_INDIRECT_RENDERING \
    -DHAVE_ALIAS -DHAVE_POSIX_MEMALIGN

X11_INCLUDES = -I/usr/X11R6/include

CFLAGS = -Wall -Wmissing-prototypes -std=c99 -ffast-math \
    $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) $(ASM_FLAGS)

CXXFLAGS = -Wall $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)

GLUT_CFLAGS = -fexceptions

# Work around aliasing bugs - developers should comment this out
CFLAGS += -fno-strict-aliasing
CXXFLAGS += -fno-strict-aliasing

MESA_ASM_SOURCES =

# Library/program dependencies
EXTRA_LIB_PATH=$(SNAP_EXTRA_LIB_PATH)
APP_LIB_DEPS+=$(SNAP_EXTRA_LIB_PATH)

LIBDRM_CFLAGS = $(shell pkg-config --cflags libdrm)
LIBDRM_LIB = $(shell pkg-config --libs libdrm)
DRI_LIB_DEPS  = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB)
GL_LIB_DEPS   = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lXdamage -lXfixes
\
        -lm -lpthread -ldl $(LIBDRM_LIB)


# Directories
SRC_DIRS := glsl mesa/es glx egl $(SRC_DIRS)
PROGRAM_DIRS := egl $(PROGRAM_DIRS) es1/screen es1/xegl es2/xegl

# EGL directories
EGL_DRIVERS_DIRS = glx
EGL_DISPLAYS = x11 kms

DRIVER_DIRS = dri
WINDOW_SYSTEM = dri
GALLIUM_WINSYS_DIRS = drm egl_drm
GALLIUM_WINSYS_DRM_DIRS = egl es vmware swrast
GALLIUM_STATE_TRACKERS_DIRS = egl es vega

DRI_DIRS = i810 i915 i965 mach64 mga r128 r200 r300 radeon \
    savage sis tdfx unichrome swrast

INTEL_LIBS = `pkg-config --libs libdrm_intel`
INTEL_CFLAGS = `pkg-config --cflags libdrm_intel`

RADEON_LIBS = `pkg-config --libs libdrm_radeon`
RADEON_CFLAGS = `pkg-config --cflags libdrm_radeon`






On Tue, Jun 1, 2010 at 9:36 PM, Jamie Amendolagine <
jamie.amendolagine at gmail.com> wrote:

> Ah. I'll try compiling qemu from source to see what options there are etc
> -- it looks like there is a kms option and maybe qemu from the ubuntu repo
> is not enabling it...
> If I can not get that to work, is there a best way to get
> mesa/egl/ogles-1/2/ovg working without X11? Even in software mode?
>
> Jamie
>
>
>
>
>
> On Tue, Jun 1, 2010 at 7:20 PM, Chia-I Wu <olvaffe at gmail.com> wrote:
>
>> On Wed, Jun 2, 2010 at 1:13 AM, Jamie Amendolagine
>> <jamie.amendolagine at gmail.com> wrote:
>> > So, I can't find any instructions on getting this up and running
>> > (x86-linux-uclibc-mesa-7.8.1 / qemu). I think that I'm pretty close. Any
>> > help is much appreciated, and I promise to submit any patches that are
>> > useful...
>> >
>> > So far I've got the kernel (2.6.34) built with kms, and vmwgfx support.
>> I
>> > boot an x86 image (uclibc) in qemu.
>> >
>> > /usr/bin/qemu -kernel '/home/jamie/neworyzans/bzImage.kms2' -append
>> > 'root=/dev/sda rw video=vmwgfx ' -boot c -m 128 -hda
>> > '/home/jamie/neworyzans/output/images/rootfs.i686.ext2' -net
>> > nic,vlan=0,model=e1000 -net tap,ifname=tap0,script=/etc/qemu-ifup  -vga
>> > vmware
>> >
>> > on boot I modprobe the modules:
>> > modprobe vmwgfx
>> > The gfx resolution changes (corrupting the console), and the following
>> > modules seem to load OK:
>> >
>> > lsmod:
>> > Module                  Size  Used by    Tainted: G
>> > vmwgfx                 62458  0
>> > ttm                    49037  1 vmwgfx
>> > drm                   164569  2 vmwgfx,ttm
>> > agpgart                31292  2 ttm,drm
>> >
>> > qemu complains with the following:
>> > vmsvga_value_write: Bad colour depth: 24 bits
>> > vmsvga_value_write: Bad register 09
>> > vmsvga_value_write: Bad register 0a
>> > vmsvga_value_write: Bad register 0b
>> >
>> >
>> > If I go ahead and try and run an app, I get this:
>> > export EGL_DRIVER=/usr/local/lib/egl/egl_kms_vmwgfx.so
>> > cd progs/egl
>> > ./eglscreen
>> > segfault
>> >
>> > ./strace ./eglscreen
>> > (attached out.txt)
>> >
>> >
>> > on the console running qemu I get this:
>> > vmsvga_value_write: Bad register 22
>> > vmsvga_value_write: Bad register 22
>> > vmsvga_value_write: Bad register 22
>> > vmsvga_value_write: Bad register 22
>> > ...
>> > vmsvga_value_write: Bad register 22
>> > vmsvga_value_write: Bad register 22
>> > vmsvga_value_write: Bad register 22
>> > vmsvga_value_write: Bad register 22
>> >
>> > Am I doing anything obviously wrong?
>> I don't think qemu SVGA emulation implements the 3D interface used by
>> gallium
>> vmwgfx driver.  It might be the problem.
>>
>>
>> --
>> olv at LunarG.com
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-users/attachments/20100602/92d40cba/attachment-0001.htm>


More information about the mesa-users mailing list