# no dri with ati radeon 9600 agp and 6.12.4 [solved]

## Leocifre

Hi everybody,

I am trying to get dri to work with the open source ati driver on a Radeon 9600, but X keeps complaining that agp is not available:

```

(II) RADEON(0): [drm] Using the DRM lock SAREA also for drawables.

(II) RADEON(0): [drm] framebuffer handle = 0xe0000000

(II) RADEON(0): [drm] added 1 reserved context for kernel

(II) RADEON(0): X context handle = 0x1

(II) RADEON(0): [drm] installed DRM signal handler

(WW) RADEON(0): [agp] AGP not available

(EE) RADEON(0): [agp] AGP failed to initialize. Disabling the DRI.

(II) RADEON(0): [agp] You may want to make sure the agpgart kernel module

is loaded before the radeon kernel module.

(II) RADEON(0): [drm] removed 1 reserved context for kernel

(II) RADEON(0): [drm] unmapping 8192 bytes of SAREA 0xf802e000 at 0xb71cd000

(II) RADEON(0): [drm] Closed DRM master.

(II) RADEON(0): RADEONRestoreMemMapRegisters() : 

(II) RADEON(0):   MC_FB_LOCATION   : 0xe7ffe000 0x1fff0000

(II) RADEON(0):   MC_AGP_LOCATION  : 0xffffffc0

(==) RADEON(0): Backing store disabled

(WW) RADEON(0): Direct rendering disabled

```

I have loaded the appropriate modules:

```

lsmod

Module                  Size  Used by

radeon                360736  0 

drm                   136000  1 radeon

intel_agp              25980  0 

agpgart                27884  2 drm,intel_agp

```

I even tried manually loading them in the correct order (first agpgart, then intel-agp, then radeon), to no avail.

I am on gentoo-sources 2.6.31-r6.

Here is my xorg.conf:

```
Section "ServerLayout"

   Identifier     "X.org Configured"

   Screen      0  "Screen0" 0 0

#   InputDevice    "Mouse0" "CorePointer"

#   InputDevice    "Keyboard0" "CoreKeyboard"

EndSection

Section "Files"

   FontPath     "/usr/share/fonts/misc/"

   FontPath     "/usr/share/fonts/TTF/"

   FontPath     "/usr/share/fonts/OTF"

   FontPath     "/usr/share/fonts/Type1/"

   FontPath     "/usr/share/fonts/100dpi/"

   FontPath     "/usr/share/fonts/75dpi/"

EndSection

Section "Module"

   Load  "extmod"

   Load  "xtrap"

   Load  "record"

   Load  "dbe"

   Load  "dri"

EndSection

Section "Monitor"

   #DisplaySize     380   300   # mm

   Identifier   "Monitor0"

   VendorName   "MAX"

   ModelName    "B101910"

   HorizSync    31.0 - 83.0

   VertRefresh  56.0 - 75.0

   Option       "DPMS"

EndSection

Section "Device"

   Option   "MetaModes" "1280x1024-1280x1024"

   Identifier  "Card0"

   Driver      "radeon"

   Option "AccelMethod" "EXA"

   Option "AccelDFS" "True"

   VendorName  "ATI Technologies Inc"

   BoardName   "RV350 AR [Radeon 9600]"

   BusID       "PCI:1:0:0"

EndSection

Section "Screen"

   Identifier "Screen0"

   Device     "Card0"

   Monitor    "Monitor0"

#   DefaultDepth 32

   SubSection "Display"

   Depth   8

   Modes "1280x1024"

   Virtual 2560 1024

   EndSubSection

   SubSection "Display"

      Depth     16

      Modes "1280x1024"

      Virtual 2560 1024

   EndSubSection

   SubSection "Display"

      Depth   24

      Modes "1280x1024"

      Virtual 2560 1024

   EndSubSection

   SubSection "Display"

      Depth     32

      Modes "1280x1024"

      Virtual 2560 1024

   EndSubSection

EndSection

Section "dri"

   Mode 0666

EndSection
```

Please help so I can finally play Quakelive here!Last edited by Leocifre on Mon Dec 28, 2009 9:22 am; edited 1 time in total

----------

## Leocifre

I just found this in dmesg:

```

[   43.463248] [drm] Initialized drm 1.1.0 20060810

[   43.491565] [drm] Initialized radeon 1.31.0 20080528 for 0000:01:00.0 on minor 0

[  141.749001] mtrr: no MTRR for e0000000,8000000 found

[  154.644290] [drm] Module unloaded

[  174.419823] Linux agpgart interface v0.103

[  180.894379] [drm] Initialized drm 1.1.0 20060810

[  180.900059] [drm] Initialized radeon 1.31.0 20080528 for 0000:01:00.0 on minor 0

```

support for MTRR is enabled in the kernel...

----------

## d2_racing

Can you post this :

```

# cd /usr/src/linux && cat .config | grep -i drm

```

----------

## Leocifre

here we go:

```

cd /usr/src/linux && cat .config | grep -i drm

CONFIG_DRM=m

# CONFIG_DRM_TDFX is not set

# CONFIG_DRM_R128 is not set

CONFIG_DRM_RADEON=m

# CONFIG_DRM_I810 is not set

# CONFIG_DRM_I830 is not set

# CONFIG_DRM_I915 is not set

# CONFIG_DRM_MGA is not set

# CONFIG_DRM_SIS is not set

# CONFIG_DRM_VIA is not set

# CONFIG_DRM_SAVAGE is not set

```

----------

## d2_racing

Can you post this :

```

# cd /usr/src/linux && cat .config | grep -i agp

```

----------

## Leocifre

yes:

```
 cd /usr/src/linux && cat .config | grep -i agp

CONFIG_AGP=m

# CONFIG_AGP_ALI is not set

# CONFIG_AGP_ATI is not set

# CONFIG_AGP_AMD is not set

# CONFIG_AGP_AMD64 is not set

CONFIG_AGP_INTEL=m

# CONFIG_AGP_NVIDIA is not set

# CONFIG_AGP_SIS is not set

# CONFIG_AGP_SWORKS is not set

# CONFIG_AGP_VIA is not set

# CONFIG_AGP_EFFICEON is not set

```

----------

## d2_racing

Did you try with builtin instead of module ?

----------

## gami

Which motherboard do you have? In my case I need to use via_agp, not intel_agp, on a motherboard with a via chipset. Can you post the output of lspci -v, please?

----------

## d2_racing

Can you post this :

```

# lspci -n

```

----------

## Leocifre

```
lspci -n

00:00.0 0600: 8086:2578 (rev 02)

00:01.0 0604: 8086:2579 (rev 02)

00:03.0 0604: 8086:257b (rev 02)

00:06.0 0880: 8086:257e (rev 02)

00:1d.0 0c03: 8086:24d2 (rev 02)

00:1d.1 0c03: 8086:24d4 (rev 02)

00:1d.2 0c03: 8086:24d7 (rev 02)

00:1d.3 0c03: 8086:24de (rev 02)

00:1d.7 0c03: 8086:24dd (rev 02)

00:1e.0 0604: 8086:244e (rev c2)

00:1f.0 0601: 8086:24d0 (rev 02)

00:1f.1 0101: 8086:24db (rev 02)

00:1f.2 0101: 8086:24d1 (rev 02)

00:1f.3 0c05: 8086:24d3 (rev 02)

01:00.0 0300: 1002:4152

01:00.1 0380: 1002:4172

02:01.0 0200: 8086:1019

03:03.0 0c00: 1106:3044 (rev 80)

03:04.0 0104: 105a:3373 (rev 02)

03:0d.0 0401: 1102:0004 (rev 03)

03:0d.1 0980: 1102:7003 (rev 03)

03:0d.2 0c00: 1102:4001

```

----------

## Leocifre

here is my /etc/modules.autoload.d/kernel-2.6 edited to ensure correct loading order:

```
 cat /etc/modules.autoload.d/kernel-2.6

# /etc/modules.autoload.d/kernel-2.6:  kernel modules to load when system boots.

#

# Note that this file is for 2.6 kernels.

#

# Add the names of modules that you'd like to load when the system

# starts into this file, one per line.  Comments begin with # and

# are ignored.  Read man modules.autoload for additional details.

# For example:

# aic7xxx

intel-agp

agpgart

drm

radeon

```

----------

## d2_racing

Hi, from your lspci, you have an intel-agp.

So try to built it inside the kernel and reboot your box.

----------

## Leocifre

thank you very much, that worked!!

Can you explain why though? I cannot really figure out why built in works and module does not...

----------

## d2_racing

Because, the kernel really need them when it load the kernel image and if they are module, the kernel load and then it will try to load the selected module but sometimes, it's not possible at that time.

----------

