On Sat, May 17, 2008 at 02:26:50PM +0200, Wojciech Puchar wrote:
>> (EE) intel(0): Couldn't allocate video memory
>> 
>> According to intel(4) allocating memory is usually done with the agp(4)
>> driver. This motherboard doesn't have agp, though. I've tried loading
> 
> it may have - internally.

It turns out that it's not necessary to have an agp bus to use the
agp(4) driver! It is mostly used to create the graphics aperture a.k.a
GART. The device is even named /dev/agpgart. 

I am guessing that on graphics cards with dedicated memory it is used to
map that into the address space. With built-in graphics it seems to be
used to "steal" RAM for use by the built-in chip.

>> the agp, i915 and drm kernel modules, but that doesn't help.
> 
> is agp compiled in kernel and loaded when booting. it doesn't work right 
> when started after boot - at least didn't for me.

It turned out that the PCI identifier for the G33 was commented out in
/usr/src/sys/pci/agp_i810.c due to lack of testing. I've re-activated
it, and /dev/agpgart is now created normally.
 
I also added the identifier for this chip to /usr/src/sys/dev/drm/drm_pciids.h

With these changes, /dev/dri/card0 is also created, and I see the
following in dmesg output:

dmesg | grep drm
drm0: <Intel 82G33/G31> on vgapci0
info: [drm] AGP at 0xe0000000 256MB
info: [drm] Initialized i915 1.5.0 20060119

But starting X with the intel driver still produces errors (excerpt from
Xorg.0.log):

drmOpenDevice: node name is /dev/dri/card0
drmOpenDevice: open result is 9, (OK)
drmOpenDevice: node name is /dev/dri/card0
drmOpenDevice: open result is 9, (OK)
drmOpenByBusid: Searching for BusID pci:0000:00:02.0
drmOpenDevice: node name is /dev/dri/card0
drmOpenDevice: open result is 9, (OK)
drmOpenByBusid: drmOpenMinor returns 9
drmOpenByBusid: drmGetBusid reports pci:0000:00:02.0
(II) [drm] DRM interface version 1.2
(II) [drm] DRM open master succeeded.
(II) intel(0): [drm] Using the DRM lock SAREA also for drawables.
(II) intel(0): [drm] framebuffer mapped by ddx driver
(II) intel(0): [drm] added 1 reserved context for kernel
(II) intel(0): X context handle = 0x1
(II) intel(0): [drm] installed DRM signal handler
(==) intel(0): VideoRam: 262144 KB
(**) intel(0): Framebuffer compression disabled
(**) intel(0): Tiling enabled
(==) intel(0): Write-combining range (0xfe900000,0x80000) was already clear
(==) intel(0): Write-combining range (0xfe800000,0x40000) was already clear
(II) intel(0): Attempting memory allocation with tiled buffers.
(II) intel(0): Success.
(II) intel(0): [drm] Registers = 0xfe900000
(II) intel(0): [drm] ring buffer = 0xe0000000
(II) intel(0): [drm] mapped front buffer at 0xe0400000, handle = 0xe0400000
(II) intel(0): [drm] mapped back buffer at 0xe1400000, handle = 0xe1400000
(II) intel(0): [drm] mapped depth buffer at 0xe1800000, handle = 0xe1800000
(II) intel(0): [drm] mapped classic textures at 0xe1c00000, handle = 0xe1c00000
(II) intel(0): [drm] Initialized kernel agp heap manager, 33554432
(II) intel(0): [dri] visual configs initialized
(II) intel(0): Page Flipping disabled
(==) intel(0): Write-combining range (0xfe900000,0x80000) was already clear
(==) intel(0): Write-combining range (0xfe800000,0x40000) was already clear
(WW) intel(0): Failed to set write-combining range (0xe0000000,0x10000000)

Hmm. 0xe0000000 is the base address, and 0x10000000 is 256 MB.

Anybody care to guess why this fails? I guess this is the cause of the
failure further on.

(II) intel(0): vgaHWGetIOBase: hwp->IOBase is 0x03d0, hwp->PIOOffset is 0x0000
(==) intel(0): Write-combining range (0xa0000,0x10000) was already clear
(II) EXA(0): Offscreen pixmap area of 12582912 bytes
(II) EXA(0): Driver registered support for the following operations:
(II)         Solid
(II)         Copy
(II)         Composite (RENDER acceleration)
(==) intel(0): Backing store disabled
(==) intel(0): Silken mouse enabled
(II) intel(0): Initializing HW Cursor
(II) intel(0): [DRI] installation complete
(II) intel(0): xf86BindGARTMemory: bind key 1 at 0x006ff000 (pgoffset 1791)
(WW) intel(0): xf86BindGARTMemory: binding of gart memory with key 1
        at offset 0x6ff000 failed (Invalid argument)
Fatal server error:
Couldn't bind memory for front buffer

If there are any X gurus out there I would appreciate any
assistance. I've been grepping through the xf86-video-intel-2.2.1
source, but it is hard to follow.

Roland
-- 
R.F.Smith                                   http://www.xs4all.nl/~rsmith/
[plain text _non-HTML_ PGP/GnuPG encrypted/signed email much appreciated]
pgp: 1A2B 477F 9970 BA3C 2914  B7CE 1277 EFB0 C321 A725 (KeyID: C321A725)

Attachment: pgpbfyF0MSwRt.pgp
Description: PGP signature

Reply via email to