# ATI IGP XFree/Kernel 3D Support [beta]

## steveforse

It looks like laptop owners of ATI IGP based motherboards may soon have hope for getting 3D support under XFree. I accidentally found this while searching on Google the other day: http://bugs.xfree86.org/show_bug.cgi?id=314. 

The page includes patches for 2.4.21, 2.6.0-test2 (to get agpgart working and there may have been some stuff for IDE), and some others. The ac-sources in portage have this patch already applied. The XFree patch available is for 4.3.99cvs. The most recent update was only a few days ago, so there may be instability. 

I haven't actually tried recompiling XFree to test it out, but I tested the ac-sources and it seemed to have detected the AGP for my chipset fine. (I'm running a Compaq Presario 2105us laptop.) It'd be nice if other owners could give feedback to the developers. It's better than paying $99 to license the drivers from xig, anyway. I'll write here again if I get anything interesting to happen. Maybe I'm just misinterpretting the page. It seems almost too good to believe. I thought the chipset would never have 3D support under Linux.

----------

## DenisTheMenace

Hello!

Is there a way in gentoo, that I can compile xfree cvs with this patch through emerge?

Thanks in advance

DenisTheMenace

----------

## pens

I've done this and yes, I can get DRI working with my IGP 340. Granted it's no powerhouse of a card, but it works.

----------

## DenisTheMenace

Hello pens!

And how did you do it?

DenisTheMenace

----------

## ry00

Yo Gentoist!! Good news!! Finally i can make my IGP 340 DRI-enabled  :Very Happy:   :Very Happy: .

i dunt know if its already in the thread, well, what de fish...i will still share it with ya.

this is what i did, use it at your own rick!!

i hold no responsibility, it works for me  :Smile: 

1. Installed vanila-source-2.4.21

2. Downloaded and applied ck patch for 2.4.21 kernel, since i want the preepmt and low latency , i dunt think its necessary for the agp-dri

3. Downloaded and applied kernel-2.4.21 agpgart patch for radeon IGP chips. 

http://bugs.xfree86.org/show_bug.cgi?id=314

4. make menuconfig

CONFIG_AGP=m

CONFIG_AGP_INTEL=y

CONFIG_AGP_I810=y

# CONFIG_AGP_VIA is not set

# CONFIG_AGP_AMD is not set

# CONFIG_AGP_AMD_8151 is not set

# CONFIG_AGP_SIS is not set

# CONFIG_AGP_ALI is not set

# CONFIG_AGP_SWORKS is not set

# CONFIG_AGP_NV is not set

CONFIG_AGP_ATI=y

# CONFIG_DRM is not set

5. before you proceed with make bzImage, you need to edit one of the kernel source, to   solve  mmu_cr4_features unresolved symbol.

	vim /usr/src/linux/arch/i368/kernel/i368_ksyms.c

add the line in italic ONLY!!

-------------------------------------------------

#endif

EXPORT_SYMBOL(empty_zero_page);

EXPORT_SYMBOL_NOVERS(mmu_cr4_features); 

#ifdef CONFIG_DEBUG_IOVIRT

EXPORT_SYMBOL(__io_virt_debug);

--------------------------------------------------

6. make clean bzImage modules && modules_install

7. cd /usr/portage

8. ebuild x11-base/xfree-4.3.99.9.ebuild unpack

9. then patched with radeon DRI patch for xfree cvs 4.3.99.9

http://bugs.xfree86.org/show_bug.cgi?id=314

10. ebuild x11-base/xfree-4.3.99.9.ebuild compile

11. ebuild x11-base/xfree-4.3.99.9.ebuild install

12. ebuild x11-base/xfree-4.3.99.9.ebuild qmerge

this is the crucial part, we going to use the radeon.o ( radeon.ko for kernel 2.6.) from our patched-xfree NOT from anywhere else (kernel/xfree-drm).

so go to where xfree-4.3.99.9 was unpacked, for my case

13. cd /var/tmp/portage/xfree-4.3.99.9/work/xc/programs/Xserver/hw/xfr

ee86/os-support/linux/drm/kernel/

then spell this cast

14. make -f Makefile.linux LINUXDIR=/usr/src/linux

there will be radeon.o created, copy/move it to

/lib/modules/2.4.21/kernel/drivers/char/

ok, done !.... reboot with the new kernel

makesure agpgart is loaded before radeon

15. modprobe agpgart

      modprobe radeon

Gd luck !  :Very Happy: 

 *Quote:*   

> 
> 
> -----------------------------
> 
> these are the magic lines 
> ...

 

----------

## dberkholz

 *ry00 wrote:*   

> 5. before you proceed with make bzImage, you need to edit one of the kernel source, to   solve  mmu_cr4_features unresolved symbol.
> 
> 	vim /usr/src/linux/arch/i368/kernel/i368_ksyms.c
> 
> add the line in italic ONLY!!
> ...

 

This could also be solved by using ac-sources .21-r4 or higher.

 *ry00 wrote:*   

> 
> 
> 6. make clean bzImage modules && modules_install
> 
> 7. cd /usr/portage
> ...

 

Try instead this, so you don't make a bunch of useless modules.

```
make -f Makefile.linux LINUXDIR=/usr/src/linux radeon.o
```

 *ry00 wrote:*   

> there will be radeon.o created, copy/move it to
> 
> /lib/modules/2.4.21/kernel/drivers/char/
> 
> ok, done !.... reboot with the new kernel
> ...

 

XFree should autoload these modules. No need to load them manually unless you have issues.

Also, I initially posted about the IGP here:

https://forums.gentoo.org/viewtopic.php?t=54793&postdays=0&postorder=asc&start=186

----------

## Xeristian/null

I'm using a Vaio PCG-FRV27, and I'm feeling like I'm the only one. It, of course, uses some kind of extremely unsupported integrated graphics board that I'm having tons of fun trying to get to work.

I installed Gentoo, the normal way as far as I know...

# export VIDEO_CARDS='radeon'

# emerge xfree-drm

It managed to compile, and I have the Radeon module loaded. I use the driver "radeon" in my XFree86Config.

Leaving quite a bit to what is normally autodetected with the VESA driver, and even after several tweaks, I still can't get my display to appear beyond 8 bit colour. In fact, if I remark the line in my screen section pertaining to 8 bit depth, it gives me the fatal "no screens found" error.

I expect... as always.. I didn't compile my kernel right or something classic like that... I'm using the XFS Sources 2.4.20-R3.

And, I'm foolish that I only mess with this whenever I get off work and can barely even believe that my fingers are still playing across the keyboard and that I am, in fact, awake.

For those who don't want to find out the specs otherwise...

IGP 345M

Pentium 4

Your everyday 1024X768 laptop LCD.

And, I'm tired... and can't remember the rest.

Thank you! Good night Gentoo forums!

(How do you pronounce 'Gentoo', by the way?)

----------

## jere890

Im on a sony vaio FRV-25 and am having same problem...

----------

## pakman

Got it working here with kernel 2.6 using the -love2 patch from:

http://www.public.iastate.edu/~jpcox/linux/patches/2.6/2.6.1_rc1/2.6.1_rc1-love2/

That gets kernel AGP support for radeon IGP then using the xfree86 patch and replacing the kernel radeon module with xfree's as mentioned by other posters above. Seems to need both patches, xfree86 alone doesn't provide the ati-agp module (only needed with 2.6).

Some textures are a bit dodgy though.

----------

## jere890

how do i go about installing the patch...will it do it automatically...

sorry, noob here

----------

## dberkholz

BTW, the IGP stuff was recently committed to DRI CVS. See the CVS section of www.gentoo.org/doc/en/dri-howto.xml or dri.sourceforge.net for more info. Note that the guide is a little out of date -- the CVS moved to freedesktop.org, and you'll need to point to an external Mesa CVS tree in host.def of the DRI tree.

----------

## pakman

 *jere890 wrote:*   

> how do i go about installing the patch...will it do it automatically...
> 
> 

 

Download the source code for linux-2.6.0 kernel and decompress it into /usr/src.

cd to that dir.

bzcat /path/to/2.6.1-rc1-love2.bz2 | patch -p2

I'm not 100% sure its needed, the radeon module from there doesn't work as well as the one from xfree mentioned in above posts. So I'm only using the ati-agp module from it, but I'm not sure that its any different from the vanilla 2.6 one.

----------

## gnarlin

Why couldn't the xfree maintainers add this patch to the ebuild so that newbies (or even us lazy folks ...) don't have to compile xfree for yourselves

.. isn't that what portage is all about, ease of installing stuff ?

Since the 3d patch is now in the dri cvs tree when will it tricle down into an official release (even a semi official one would do) of xfree ?

----------

## dberkholz

 *gnarlin wrote:*   

> Why couldn't the xfree maintainers add this patch to the ebuild so that newbies (or even us lazy folks ...) don't have to compile xfree for yourselves
> 
> .. isn't that what portage is all about, ease of installing stuff ?
> 
> Since the 3d patch is now in the dri cvs tree when will it tricle down into an official release (even a semi official one would do) of xfree ?

 

Because it's alpha, and things are still broken/in development. Once it hits XFree86 CVS, there's a much better chance it'll show up as a patch in our releases.

----------

