From owner-freebsd-x11@FreeBSD.ORG Tue Feb 19 08:23:04 2013 Return-Path: Delivered-To: freebsd-x11@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id BC06B441 for ; Tue, 19 Feb 2013 08:23:04 +0000 (UTC) (envelope-from mexas@bristol.ac.uk) Received: from dirj.bris.ac.uk (dirj.bris.ac.uk [137.222.10.78]) by mx1.freebsd.org (Postfix) with ESMTP id 82E21664 for ; Tue, 19 Feb 2013 08:23:04 +0000 (UTC) Received: from irix.bris.ac.uk ([137.222.10.39] helo=ncs.bris.ac.uk) by dirj.bris.ac.uk with esmtp (Exim 4.72) (envelope-from ) id 1U7iTL-0001Lu-SL for freebsd-x11@freebsd.org; Tue, 19 Feb 2013 08:23:03 +0000 Received: from mech-cluster241.men.bris.ac.uk ([137.222.187.241]) by ncs.bris.ac.uk with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.72) (envelope-from ) id 1U7iTL-0007Cs-Kx for freebsd-x11@freebsd.org; Tue, 19 Feb 2013 08:22:43 +0000 Received: from mech-cluster241.men.bris.ac.uk (localhost [127.0.0.1]) by mech-cluster241.men.bris.ac.uk (8.14.6/8.14.6) with ESMTP id r1J8MhPF019528 for ; Tue, 19 Feb 2013 08:22:43 GMT (envelope-from mexas@mech-cluster241.men.bris.ac.uk) Received: (from mexas@localhost) by mech-cluster241.men.bris.ac.uk (8.14.6/8.14.6/Submit) id r1J8MhbN019527 for freebsd-x11@freebsd.org; Tue, 19 Feb 2013 08:22:43 GMT (envelope-from mexas) Date: Tue, 19 Feb 2013 08:22:43 GMT From: Anton Shterenlikht Message-Id: <201302190822.r1J8MhbN019527@mech-cluster241.men.bris.ac.uk> To: freebsd-x11@freebsd.org Subject: why drm? X-Spam-Score: -1.6 X-Spam-Level: - X-BeenThere: freebsd-x11@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: mexas@bristol.ac.uk List-Id: X11 on FreeBSD -- maintaining and support List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Feb 2013 08:23:04 -0000 I'm confused about DRM/DRI. I've done some brief reading but still not clear what these do, or even if DRM and DRI do the same thing? I've a laptop with # pciconf -lv |grep Rade device = 'RS690M [Radeon X1200 Series]' # which seems to be driven by x11-drivers/xf86-video-ati And that seems to work ok. If I build a kernel with drm: # grep drm /root/kernels/BUZI device drm # DRM core module required by DRM drivers device i915drm # Intel i830 through i915 device r128drm # ATI Rage 128 device radeondrm # ATI Radeon device viadrm # VIA # (I probably don't need all these drm options) then I get these messages: [drm:pid1077:drm_open] open_count = 0 [drm:pid1077:drm_open_helper] pid = 1077, device = dri/card0 [drm:pid1077:radeon_driver_open] [drm:pid1077:drm_addmap] offset = 0x00000000, size = 0x00002000, type = 2 [drm:pid1077:drm_addmap] 8192 13 0xffffff800281b000 [drm:pid1077:drm_addmap] Added map 2 0xffffff800281b000/0x2000 [drm:pid1077:drm_addmap] offset = 0xc0100000, size = 0x08000000, type = 0 [drm:pid1077:drm_addmap] Added map 0 0xc0100000/0x8000000 [drm:pid1077:drm_firstopen] [drm:pid1077:drm_ioctl] pid=1077, cmd=0xc0406400, nr=0x00, dev 0xfffffe00028e3200, auth=1 [drm:pid1077:drm_ioctl] pid=1077, cmd=0xc0406400, nr=0x00, dev 0xfffffe00028e3200, auth=1 [drm:pid1077:drm_close] open_count = 1 [drm:pid1077:drm_close] pid = 1077, device = 0xfffffe00028e3200, open_count = 1 [drm:pid1077:drm_lastclose] [drm:pid1077:radeon_do_cleanup_cp] Do these indicate that all is fine? If I then start X (via xdm): I see these lines in /var/log/Xorg.0.log: drmOpenDevice: node name is /dev/dri/card0 drmOpenDevice: open result is 10, (OK) drmOpenByBusid: Searching for BusID pci:0000:01:05.0 drmOpenDevice: node name is /dev/dri/card0 drmOpenDevice: open result is 10, (OK) drmOpenByBusid: drmOpenMinor returns 10 drmOpenByBusid: drmGetBusid reports pci:0000:01:05.0 These also seem allright. However, I just get a black screen from which I cannot recover and have to reboot. So my questions: 1. Do I need DRM/DRI. My understanding is that X will do just as well without it, perhaps a bit slower. Is that correct? 2. In my using of DRM did I miss any steps? I'd be grateful for any advice or a link to a relevant existing document. Many thanks Anton