From owner-freebsd-emulation@FreeBSD.ORG Tue May 19 16:50:57 2009 Return-Path: Delivered-To: freebsd-emulation@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BAD4E1065674 for ; Tue, 19 May 2009 16:50:57 +0000 (UTC) (envelope-from yamagi@yamagi.org) Received: from mail.yamagi.org (yamagi.org [88.198.78.242]) by mx1.freebsd.org (Postfix) with ESMTP id 47E798FC14 for ; Tue, 19 May 2009 16:50:57 +0000 (UTC) (envelope-from yamagi@yamagi.org) Received: from localhost (unknown [10.0.0.3]) by mail.yamagi.org (Postfix) with ESMTP id 328F91083C18; Tue, 19 May 2009 18:50:54 +0200 (CEST) X-Virus-Scanned: amavisd-new at yamagi.org Received: from mail.yamagi.org ([10.0.0.3]) by localhost (mail.yamagi.org [10.0.0.3]) (amavisd-new, port 10024) with LMTP id 8T6uCe9G3fz0; Tue, 19 May 2009 18:50:42 +0200 (CEST) Received: from saya.home.yamagi.org (f054132041.adsl.alicedsl.de [78.54.132.41]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.yamagi.org (Postfix) with ESMTP id 6354C1083C19; Tue, 19 May 2009 18:50:42 +0200 (CEST) Received: from saya.home.yamagi.org (localhost [127.0.0.1]) by saya.home.yamagi.org (8.14.3/8.14.3) with ESMTP id n4JGoe2q027268; Tue, 19 May 2009 18:50:40 +0200 (CEST) (envelope-from yamagi@saya.home.yamagi.org) Received: (from yamagi@localhost) by saya.home.yamagi.org (8.14.3/8.14.3/Submit) id n4JGodZu027267; Tue, 19 May 2009 18:50:39 +0200 (CEST) (envelope-from yamagi) Date: Tue, 19 May 2009 18:50:39 +0200 From: Yamagi Burmeister To: Boris Samorodov Message-ID: <20090519165039.GA12505@yamagi.org> References: <92596693@bb.ipt.ru> <20090510174445.GA75441@yamagi.org> <67576966@bb.ipt.ru> <20090515145252.GA69488@yamagi.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="u3/rZRmxL6MmkK24" Content-Disposition: inline In-Reply-To: <20090515145252.GA69488@yamagi.org> User-Agent: Mutt/1.5.19 (2009-01-05) Cc: freebsd-emulation@freebsd.org Subject: Re: [new port] graphics/linux-dri74 X-BeenThere: freebsd-emulation@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Development of Emulators of other operating systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 May 2009 16:50:58 -0000 --u3/rZRmxL6MmkK24 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Okay, I investigated further. First I tried a FreeBSD/i386 version of ioQuake3 on a FreeBSD/amd64 host. After some minor and unrelated problems it worked. After that I tried to debug the linux-dri74. Reading the source and doing a lot test runs I realized, that there are in fact two problems. Every ten starts or so the userland side of drm crashes: yamagi@saya:ttyp3 ~: /usr/compat/linux/usr/bin/glxinfo name of display: :0.0 libGL: XF86DRIGetClientDriverName: 5.3.0 r300 (screen 0) libGL: OpenDriver: trying /usr/lib/dri/tls/r300_dri.so libGL: OpenDriver: trying /usr/lib/dri/r300_dri.so drmOpenDevice: node name is /dev/dri/card0 drmOpenDevice: open result is 4, (OK) DRM_IOCTL_VERSION: Bad address Segmentation fault (core dumped) The other times the userland side of drm is able to open the drm-device bit is unable to initalize it. The error message is somewhat missleading: yamagi@saya:ttyp3 ~: /usr/compat/linux/usr/bin/glxinfo name of display: :0.0 libGL: XF86DRIGetClientDriverName: 5.3.0 r300 (screen 0) libGL: OpenDriver: trying /usr/lib/dri/tls/r300_dri.so libGL: OpenDriver: trying /usr/lib/dri/r300_dri.so drmOpenDevice: node name is /dev/dri/card0 drmOpenDevice: open result is 4, (OK) drmOpenByBusid: Searching for BusID pci:0000:01:00.0 drmOpenDevice: node name is /dev/dri/card0 drmOpenDevice: open result is 4, (OK) drmOpenByBusid: drmOpenMinor returns 4 drmOpenByBusid: drmGetBusid reports (null) drmOpenDevice: node name is /dev/dri/card1 drmOpenByBusid: drmOpenMinor returns -1 drmOpenDevice: node name is /dev/dri/card2 drmOpenByBusid: drmOpenMinor returns -1 drmOpenDevice: node name is /dev/dri/card3 drmOpenByBusid: drmOpenMinor returns -1 drmOpenDevice: node name is /dev/dri/card4 drmOpenByBusid: drmOpenMinor returns -1 [..] drmOpenDevice: node name is /dev/dri/card14 drmOpenByBusid: drmOpenMinor returns -1 libGL error: drmOpenOnce failed (Operation not permitted) libGL error: reverting to software direct rendering libGL: OpenDriver: trying /usr/lib/dri/tls/swrast_dri.so libGL: OpenDriver: trying /usr/lib/dri/swrast_dri.so display: :0 screen: 0 direct rendering: Yes So I added debug printf() into the code. I stepped through it. After some hours of intesive debugging im 99% sure, that both of the above failures of linux-drm74 are originating at the kernel side. It's most likely NOT a problem of the userland side and therefor not a problem=20 of the port. I'll investigate further at the kernel side, but that'll need some time. So, while it's the fault linux-drm74, what about a little warning message in the install message of the port? Just to be sure, that other users experiencing the same problem know, that it is not a bug of linux-dr74. Ciao, Yamagi --=20 Homepage: www.yamagi.org Jabber: yamagi@yamagi.org GnuPG/GPG: 0xEFBCCBCB --u3/rZRmxL6MmkK24 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.11 (FreeBSD) iEYEARECAAYFAkoS414ACgkQWTjlg++8y8stggCg4hhyiBoKrKzRaCawiH8s74Ux pSIAoMC4vrCd5CxzndlppcntkUs6IMX8 =pi99 -----END PGP SIGNATURE----- --u3/rZRmxL6MmkK24--