Re: weston 0.95 on 945GME using i915 drm
SOLVED here: http://lists.freedesktop.org/archives/wayland-devel/2012-August/004854.html ___ wayland-devel mailing list wayland-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/wayland-devel
weston 0.95 on 945GME using i915 drm
Please point me in the right direction to get weston up from the virtual terminal. I have 0.95 currently working under X, but not DRM or wayland from a virtual tty. ( I am new, how do you refer to the vtty wayland EGL platform? ) ( I have mesa master currently running mesa egl demos from the tty ) I have installed and tested the following configuration: ENVIRONMENT export WLD=/home/bcpl/install # change this to another location if you prefer export LD_LIBRARY_PATH=$WLD/lib export PKG_CONFIG_PATH=$WLD/lib/pkgconfig/:$WLD/share/pkgconfig/:/usr/lib/pkgconfig/:/usr/share/pkgconfig/ export ACLOCAL=aclocal -I $WLD/share/aclocal export MESA_DEBUG=1 export EGL_LOG_LEVEL=debug export EGL_DRIVERS_PATH=$WLD/lib #export EGL_PLATFORM=drm #export EGL_PLATFORM=fbdev #export EGL_PLATFORM=wayland export LIBGL_DEBUG=verbose export WAYLAND_DEBUG=1 export XDG_RUNTIME_DIR=/home/bcpl/wayland/xdg #export XDG_RUNTIME_DIR=/tmp/ #export CFLAGS=-g -I${WLD}/include -DEBUG -DHAVE_PIPE_LOADER_DRM #export CXXFLAGS=-g -I${WLD}/include -DEBUG -DHAVE_PIPE_LOADER_DRM export CFLAGS=-g -I${WLD}/include -DEBUG export CXXFLAGS=-g -I${WLD}/include -DEBUG export LDLAGS=-g -ldl #sudo groupadd weston-launch #sudo usermod -a -G weston-launch $USER ## Log all the way out (of X, etc.) #sudo chown root weston-launch #sudo chmod +s weston-launch MESA $ ./configure --prefix=/home/bcpl/install --enable-egl --enable-gles1 --enable-gles2 --with-egl-platforms=drm,wayland,x11,fbdev --enable-shared-glapi --with-dri-drivers=i915,i965,r200,swrast --enable-gbm --with-gallium-drivers=i915,swrast,nouveau --enable-gallium-egl Note: I could not get eglgears_screen working without the gallium drivers AND I could not get gallium drm to compile without the HAVE_PIPE_LOADER_DRM symbol AND I could not get that symbol configured without enabling the nouveau driver. here is the EGL debug info: Note: it selects gallium for the best driver: bcpl@localhost ~]$ source ~/wayland/wld.rc [bcpl@localhost ~]$ ./mesa-demos-8.0.1/src/egl/opengles1/torus_screen libEGL debug: Native platform type: drm (build-time configuration) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added /home/bcpl/install/lib/egl/egl_gallium.so to module array libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: dlopen(/home/bcpl/install/lib/egl/egl_gallium.so) libEGL info: use DRM for display (nil) libEGL debug: the best driver is Gallium EGL_VERSION = 1.4 (Gallium) Mesa warning: couldn't open libtxc_dxtn.so, software DXTn compression/decompression unavailable Found 1 modes: 0: 1024 x 768 Will use screen size: 1024 x 768 979 frames in 5.0 seconds = 195.761 FPS (FBDEV also works as root) WAYLAND/WESTON I could only get wayland/weston 0.95 to compile against the mesa master branch. I could not get 0.85 to compile against Mesa-8.0.(0,1,2,3,4) Running weston with an X server up and DISPLAY set works! When I switch to the terminal and run ~/install/bin/weston the machine hangs until I ssh in and kill weston. this time DRI2 is selected before respawning and setting EGL_PLATFORM to wayland. I will be focusing here unless directed otherwise: [11:45:07.736] libwayland: disconnect from client 0x856c1d0 wl_drm@11: error 2: invalid name Here is the entire weston output: [bcpl@localhost bin]$ cat weston.log Date: 2012-08-10 UTC [11:45:05.191] weston 0.95.0 http://wayland.freedesktop.org/ Bug reports to: https://bugs.freedesktop.org/enter_bug.cgi?product=weston Build: 0.95.0-76-g3d89049-dirty config-parser: Handle lines that don't end in (2012-08-03 21:56:41 -0400) [11:45:05.192] OS: Linux, 2.6.32-220.el6.i686, #1 SMP Wed Nov 9 08:02:18 EST 2011, i686 [11:45:05.192] Loading module '/home/bcpl/install/lib/weston/drm-backend.so' [11:45:05.193] initializing drm backend [11:45:05.194] using /dev/dri/card0 libGL: Can't open configuration file /etc/drirc: No such file or directory. libEGL debug: Native platform type: drm (autodetected) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added /home/bcpl/install/lib/egl/egl_gallium.so to module array libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: dlopen(/home/bcpl/install/lib/egl/egl_gallium.so) libEGL info: use DRM for display 0x82c1e18 libEGL debug: EGL user error 0x3001 (EGL_NOT_INITIALIZED) in eglInitialize(no usable display) libEGL debug: the best driver is DRI2 libGL: Can't open configuration file /etc/drirc: No such file or directory. Mesa warning: couldn't open libtxc_dxtn.so, software DXTn compression/decompression unavailable [11:45:05.218] EGL version: 1.4 (DRI2) [11:45:05.218] EGL vendor: Mesa Project [11:45:05.218] EGL client APIs: OpenGL OpenGL_ES OpenGL_ES2 [11:45:05.218] EGL extensions: EGL_MESA_drm_image EGL_WL_bind_wayland_display EGL_KHR_image_base
Re: weston 0.95 on 945GME using i915 drm
On Fri, 10 Aug 2012 08:15:01 -0400 jegde jedge bubba...@gmail.com wrote: Please point me in the right direction to get weston up from the virtual terminal. I have 0.95 currently working under X, but not DRM or wayland from a virtual tty. ( I am new, how do you refer to the vtty wayland EGL platform? ) ( I have mesa master currently running mesa egl demos from the tty ) I have installed and tested the following configuration: ENVIRONMENT export WLD=/home/bcpl/install # change this to another location if you prefer export LD_LIBRARY_PATH=$WLD/lib export PKG_CONFIG_PATH=$WLD/lib/pkgconfig/:$WLD/share/pkgconfig/:/usr/lib/pkgconfig/:/usr/share/pkgconfig/ export ACLOCAL=aclocal -I $WLD/share/aclocal export MESA_DEBUG=1 export EGL_LOG_LEVEL=debug export EGL_DRIVERS_PATH=$WLD/lib #export EGL_PLATFORM=drm #export EGL_PLATFORM=fbdev #export EGL_PLATFORM=wayland export LIBGL_DEBUG=verbose export WAYLAND_DEBUG=1 export XDG_RUNTIME_DIR=/home/bcpl/wayland/xdg #export XDG_RUNTIME_DIR=/tmp/ #export CFLAGS=-g -I${WLD}/include -DEBUG -DHAVE_PIPE_LOADER_DRM #export CXXFLAGS=-g -I${WLD}/include -DEBUG -DHAVE_PIPE_LOADER_DRM export CFLAGS=-g -I${WLD}/include -DEBUG export CXXFLAGS=-g -I${WLD}/include -DEBUG export LDLAGS=-g -ldl #sudo groupadd weston-launch #sudo usermod -a -G weston-launch $USER ## Log all the way out (of X, etc.) #sudo chown root weston-launch #sudo chmod +s weston-launch MESA $ ./configure --prefix=/home/bcpl/install --enable-egl --enable-gles1 --enable-gles2 --with-egl-platforms=drm,wayland,x11,fbdev --enable-shared-glapi --with-dri-drivers=i915,i965,r200,swrast --enable-gbm --with-gallium-drivers=i915,swrast,nouveau --enable-gallium-egl For intel, I think you should use the dri driver, not gallium. If EGL chooses egl_gallium as the driver, it can only load the wrong i915 driver, if any. So you could change to --disable-gallium-egl, too. Also make sure you never set EGL_PLATFORM to anything, and use weston-launch to start Weston. Thanks, pq ___ wayland-devel mailing list wayland-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/wayland-devel
Re: weston 0.95 on 945GME using i915 drm
Thank you for your help. It looks like I have a dri/mesa issue to resolve before I can run weston... Is there a resource that shows how to get mesa egl/dri/drm working on i915? I rebuilt (make clean, make, make install) mesa, then pixman, then cairo, then weston. When I recompile mesa with --disable-gallium-egl, I now fail where gallium works: [code]code [bcpl@localhost ~]$ source wayland/wld.rc [bcpl@localhost ~]$ ./mesa-demos-8.0.1/src/egl/opengles1/torus_screen libEGL debug: Native platform type: drm (build-time configuration) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: the best driver is DRI2 EGL_VERSION = 1.4 (DRI2) libEGL debug: attribute 0x3033 has an invalid value 0x8 libEGL debug: EGL user error 0x3004 (EGL_BAD_ATTRIBUTE) in eglChooseConfig EGLUT: failed to choose a config /code[/code] When I run with weston-launch i get: failed to get cairo egl argb device failed to create display: Invalid argument [code]code [bcpl@localhost bin]$ source ~/wayland/wld.rc [bcpl@localhost bin]$ ./weston-launch Date: 2012-08-10 UTC [14:41:13.327] weston 0.95.0 http://wayland.freedesktop.org/ Bug reports to: https://bugs.freedesktop.org/enter_bug.cgi?product=weston Build: 0.95.0-76-g3d89049-dirty config-parser: Handle lines that don't end in (2012-08-03 21:56:41 -0400) [14:41:13.327] OS: Linux, 2.6.32-220.el6.i686, #1 SMP Wed Nov 9 08:02:18 EST 2011, i686 [14:41:13.329] Loading module '/home/bcpl/install/lib/weston/drm-backend.so' [14:41:13.330] initializing drm backend [14:41:13.337] using /dev/dri/card0 libEGL debug: Native platform type: drm (autodetected) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: the best driver is DRI2 Mesa warning: couldn't open libtxc_dxtn.so, software DXTn compression/decompression unavailable [14:41:13.361] EGL version: 1.4 (DRI2) [14:41:13.361] EGL vendor: Mesa Project [14:41:13.361] EGL client APIs: OpenGL OpenGL_ES OpenGL_ES2 [14:41:13.361] EGL extensions: EGL_MESA_drm_image EGL_WL_bind_wayland_display EGL_KHR_image_base EGL_KHR_gl_renderbuffer_image EGL_KHR_surfaceless_context [14:41:13.361] GL version: OpenGL ES 2.0 Mesa 8.1-devel (git-04a11b5) [14:41:13.361] GLSL version: OpenGL ES GLSL ES 1.0.16 [14:41:13.361] GL vendor: VMware, Inc. [14:41:13.361] GL renderer: Gallium 0.4 on i915 (chipset: 945GME) [14:41:13.361] GL extensions: GL_EXT_blend_minmax GL_EXT_multi_draw_arrays GL_EXT_texture_filter_anisotropic GL_EXT_texture_format_BGRA GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_stencil8 GL_OES_texture_3D GL_OES_texture_npot GL_OES_EGL_image GL_OES_depth_texture GL_OES_packed_depth_stencil GL_EXT_texture_type_2_10_10_10_REV GL_EXT_read_format_bgra GL_NV_fbo_color_attachments GL_OES_EGL_image_external GL_EXT_unpack_subimage GL_NV_draw_buffers GL_NV_read_buffer [14:41:13.413] failed to get plane resources: Invalid argument [14:41:13.413] Output LVDS1, (connector 5, crtc 4) mode 1024x768@60.0, preferred, current mode 1024x768@60.0 [14:41:13.833] input device Power Button, /dev/input/event2 is a keyboard [14:41:13.836] input device Sleep Button, /dev/input/event0 is a keyboard [14:41:13.839] input device Power Button, /dev/input/event1 is a keyboard [14:41:13.845] input device Interlink Electronics, Inc. FSR 4ZUSB, /dev/input/event8 is a pointer [14:41:13.848] input device DRS Inc. DRS Inc. Keyboard, /dev/input/event9 is a keyboard [14:41:13.851] input device Hampshire Company TSHARC Analog Resistive, /dev/input/event5 is a pointer [14:41:13.854] input device Dell Dell USB Optical Mouse, /dev/input/event11 is a pointer [14:41:13.862] input device Dell Dell Wired Multimedia Keyboard, /dev/input/event6 is a keyboard [14:41:13.865] input device Dell Dell Wired Multimedia Keyboard, /dev/input/event7 is a pointer [14:41:13.865] input device Dell Dell Wired Multimedia Keyboard, /dev/input/event7 is a keyboard [14:41:13.868] input device AT Translated Set 2 keyboard, /dev/input/event4 is a keyboard [14:41:13.871] input device Macintosh mouse button emulation, /dev/input/event3 is a pointer [14:41:13.871] Loading module '/home/bcpl/install/lib/weston/desktop-shell.so' [14:41:13.879] libwayland: using socket /home/bcpl/wayland/xdg/wayland-0 libEGL debug: Native platform type: wayland (autodetected) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: pci
Re: weston 0.95 on 945GME using i915 drm
On Fri, 10 Aug 2012 11:11:14 -0400 jegde jedge bubba...@gmail.com wrote: I rebuilt (make clean, make, make install) mesa, then pixman, then cairo, then weston. Hi, only Mesa rebuild is needed at this point. When I recompile mesa with --disable-gallium-egl, I now fail where gallium works: [code]code [bcpl@localhost ~]$ source wayland/wld.rc [bcpl@localhost ~]$ ./mesa-demos-8.0.1/src/egl/opengles1/torus_screen libEGL debug: Native platform type: drm (build-time configuration) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: the best driver is DRI2 EGL_VERSION = 1.4 (DRI2) libEGL debug: attribute 0x3033 has an invalid value 0x8 libEGL debug: EGL user error 0x3004 (EGL_BAD_ATTRIBUTE) in eglChooseConfig Yes, it is trying to use the gallium driver still. [bcpl@localhost bin]$ ./weston-launch Date: 2012-08-10 UTC [14:41:13.327] weston 0.95.0 http://wayland.freedesktop.org/ Bug reports to: https://bugs.freedesktop.org/enter_bug.cgi?product=weston Build: 0.95.0-76-g3d89049-dirty config-parser: Handle lines that don't end in (2012-08-03 21:56:41 -0400) [14:41:13.327] OS: Linux, 2.6.32-220.el6.i686, #1 SMP Wed Nov 9 08:02:18 EST 2011, i686 [14:41:13.329] Loading module '/home/bcpl/install/lib/weston/drm-backend.so' [14:41:13.330] initializing drm backend [14:41:13.337] using /dev/dri/card0 libEGL debug: Native platform type: drm (autodetected) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: the best driver is DRI2 Mesa warning: couldn't open libtxc_dxtn.so, software DXTn compression/decompression unavailable [14:41:13.361] EGL version: 1.4 (DRI2) [14:41:13.361] EGL vendor: Mesa Project [14:41:13.361] EGL client APIs: OpenGL OpenGL_ES OpenGL_ES2 [14:41:13.361] EGL extensions: EGL_MESA_drm_image EGL_WL_bind_wayland_display EGL_KHR_image_base EGL_KHR_gl_renderbuffer_image EGL_KHR_surfaceless_context [14:41:13.361] GL version: OpenGL ES 2.0 Mesa 8.1-devel (git-04a11b5) [14:41:13.361] GLSL version: OpenGL ES GLSL ES 1.0.16 [14:41:13.361] GL vendor: VMware, Inc. [14:41:13.361] GL renderer: Gallium 0.4 on i915 (chipset: 945GME) The above line should not say Gallium. Just drop the i915 from the gallium driver list on the Mesa configure line, and keep it in the dri driver list. Also the configure line from http://wayland.freedesktop.org/building.html should work just fine. Intel dri drivers get built by default, when they are not explicitly configured. Make sure to wipe all intel drivers from your install prefix before you install Mesa again, so that the intel gallium driver does not remain there. Actually, simply removing the intel gallium driver should be enough, no need to even rebuild, I guess. -- Pekka Paalanen http://www.iki.fi/pq/ ___ wayland-devel mailing list wayland-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/wayland-devel
Re: weston 0.95 on 945GME using i915 drm
Thanks again. I Really appreciate the help. I wiped everything, started from scratch, and followed the build instructions at http://wayland.freedesktop.org/building.html verbatim. With this mesa build I cannot get any mesa-demo-8.0.1/src/egl/opengl/demo_screen example to run from the tty console. The ~/src/egl/opengl/demo_x11 examples do work linking these specific mesa libs. Here are the results from the weston-launch: [bcpl@localhost bin]$ cat weston.log Date: 2012-08-10 UTC [17:39:58.209] weston 0.95.0 http://wayland.freedesktop.org/ Bug reports to: https://bugs.freedesktop.org/enter_bug.cgi?product=weston Build: [17:39:58.209] OS: Linux, 2.6.32-220.el6.i686, #1 SMP Wed Nov 9 08:02:18 EST 2011, i686 [17:39:58.211] Loading module '/home/bcpl/install/lib/weston/drm-backend.so' [17:39:58.211] initializing drm backend [17:39:58.218] using /dev/dri/card0 libEGL debug: Native platform type: drm (autodetected) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: the best driver is DRI2 Mesa warning: couldn't open libtxc_dxtn.so, software DXTn compression/decompression unavailable [17:39:58.238] EGL version: 1.4 (DRI2) [17:39:58.238] EGL vendor: Mesa Project [17:39:58.238] EGL client APIs: OpenGL OpenGL_ES2 [17:39:58.238] EGL extensions: EGL_MESA_drm_image EGL_WL_bind_wayland_display EGL_KHR_image_base EGL_KHR_gl_renderbuffer_image EGL_KHR_surfaceless_context [17:39:58.238] GL version: OpenGL ES 2.0 Mesa 8.1-devel (git-f7af4be) [17:39:58.238] GLSL version: OpenGL ES GLSL ES 1.0.16 [17:39:58.238] GL vendor: Intel Open Source Technology Center [17:39:58.238] GL renderer: Mesa DRI Intel(R) 945GME x86/MMX/SSE2 [17:39:58.238] GL extensions: GL_EXT_blend_minmax GL_EXT_multi_draw_arrays GL_EXT_texture_filter_anisotropic GL_EXT_texture_format_BGRA GL_OES_compressed_ETC1_RGB8_texture GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_stencil8 GL_OES_texture_3D GL_OES_texture_npot GL_OES_EGL_image GL_OES_depth_texture GL_OES_packed_depth_stencil GL_EXT_texture_type_2_10_10_10_REV GL_EXT_read_format_bgra GL_NV_fbo_color_attachments GL_EXT_unpack_subimage GL_NV_draw_buffers GL_NV_read_buffer [17:39:58.292] failed to get plane resources: Invalid argument [17:39:58.292] kms connector 5, crtc 4 mode 1024x768@60.0, preferred, current mode 1024x768@60.0 [17:39:58.736] Loading module '/home/bcpl/install/lib/weston/desktop-shell.so' [17:39:58.743] libwayland: using socket /home/bcpl/wayland/xdg/wayland-0 libEGL debug: Native platform type: wayland (autodetected) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: pci id for 5: 8086:27ae, driver i915 libEGL debug: DRI2: dlopen(/home/bcpl/install/lib/dri/i915_dri.so) libEGL debug: DRI2: found extension `DRI_Core' libEGL info: DRI2: found extension DRI_Core version 1 libEGL debug: DRI2: found extension `DRI_DRI2' libEGL info: DRI2: found extension DRI_DRI2 version 3 libEGL debug: DRI2: found extension `DRI_TexBuffer' libEGL info: DRI2: found extension DRI_TexBuffer version 2 libEGL debug: DRI2: found extension `DRI2_Flush' libEGL info: DRI2: found extension DRI2_Flush version 3 libEGL debug: DRI2: found extension `DRI_IMAGE' libEGL info: DRI2: found extension DRI_IMAGE version 5 libEGL debug: DRI2: found extension `DRI_CONFIG_QUERY' libEGL debug: the best driver is DRI2 Mesa warning: couldn't open libtxc_dxtn.so, software DXTn compression/decompression unavailable failed to get cairo egl argb device failed to create display: Invalid argument libEGL debug: Display 0x82dee60 is destroyed with resources [17:39:58.798] libwayland: disconnect from client 0x8c946a0 [17:39:58.799] weston-desktop-shell died, respawning... libEGL debug: Native platform type: wayland (autodetected) libEGL debug: EGL search path is /home/bcpl/install/lib:/home/bcpl/install/lib/egl libEGL debug: added egl_dri2 to module array libEGL debug: added egl_glx to module array libEGL debug: pci id for 5: 8086:27ae, driver i915 libEGL debug: DRI2: dlopen(/home/bcpl/install/lib/dri/i915_dri.so) libEGL debug: DRI2: found extension `DRI_Core' libEGL info: DRI2: found extension DRI_Core version 1 libEGL debug: DRI2: found extension `DRI_DRI2' libEGL info: DRI2: found extension DRI_DRI2 version 3 libEGL debug: DRI2: found extension `DRI_TexBuffer' libEGL info: DRI2: found extension DRI_TexBuffer version 2 libEGL debug: DRI2: found extension `DRI2_Flush' libEGL info: DRI2: found extension DRI2_Flush version 3 libEGL debug: DRI2: found extension
Re: weston 0.95 on 945GME using i915 drm
Looks like it is failing in: ~/mesa/egl/main/eglapi.c::eglCreatePBufferSurface() ~/cairo/src/cairo_egl_context.c:: cairo_egl_device_create() ~/weston/clients/window.c::init_egl() ~/weston/clients/window.c::display_create() This means that all the boilerplate egl initialization has completed successfully. I could not yet track what driver/lib has drv-API.CreatePBufferSurface() Don't know what to try next. ___ wayland-devel mailing list wayland-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/wayland-devel