LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-22-2003, 06:38 AM   #1
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Rep: Reputation: 15
New ATI drivers + Kernel 2.6: is it possible?


Hi all,
someone of you know if I can install the new ATI drivers for XFree 4.3, with the new kernel 2.6 test 5?

I tried to do that but I have some errors while I'm compiling the modules... someone of you was able to make the drivers work with the new kernel? Maybe I have to download with apt-get som daemons? Maybe I have to compile the kernel with some specific modules?

thanx in advance!
Bye!
 
Old 09-22-2003, 08:32 AM   #2
UnTamed
Member
 
Registered: Dec 2002
Location: Qc, Canada
Distribution: CRUX
Posts: 317

Rep: Reputation: 30
Patch the firegl_public.c file included in the driver, with this
fglrx-2.6-test5.patch
Code:
--- ../firegl_public.c  2003-09-09 12:55:08.207301800 +0000
+++ firegl_public.c     2003-09-09 12:55:38.991621872 +0000
@@ -420,7 +420,7 @@ static int firegl_proc_cleanup( int mino
 static int firegl_stub_open(struct inode *inode, struct file *filp)
 {
 #if LINUX_VERSION_CODE > 0x020500
-       int                    minor = minor(inode->i_rdev);
+       int                    minor = MINOR(inode->i_rdev);
 #else
        int                    minor = MINOR(inode->i_rdev);
 #endif
@@ -846,7 +846,7 @@ const char* __ke_module_parm(void)
 int __ke_inode_rdev_minor(struct inode* inode)
 {
 #if LINUX_VERSION_CODE > 0x020500
-    return minor(inode->i_rdev);
+    return MINOR(inode->i_rdev);
 #else
     return MINOR(inode->i_rdev);
 #endif
...works here.

>uname -r
2.6.0-test5-bk1

>fglrxinfo
display: :0.0 screen: 0
OpenGL vendor string: ATI Technologies Inc.
OpenGL renderer string: Radeon 8500 DDR Pentium 4 (SSE2)
OpenGL version string: 1.3 (X4.3.0-3.2.5).
 
Old 09-22-2003, 08:56 AM   #3
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by UnTamed
Patch the firegl_public.c file included in the driver, with this
fglrx-2.6-test5.patch
Code:
--- ../firegl_public.c  2003-09-09 12:55:08.207301800 +0000
+++ firegl_public.c     2003-09-09 12:55:38.991621872 +0000
@@ -420,7 +420,7 @@ static int firegl_proc_cleanup( int mino
 static int firegl_stub_open(struct inode *inode, struct file *filp)
 {
 #if LINUX_VERSION_CODE > 0x020500
-       int                    minor = minor(inode->i_rdev);
+       int                    minor = MINOR(inode->i_rdev);
 #else
        int                    minor = MINOR(inode->i_rdev);
 #endif
@@ -846,7 +846,7 @@ const char* __ke_module_parm(void)
 int __ke_inode_rdev_minor(struct inode* inode)
 {
 #if LINUX_VERSION_CODE > 0x020500
-    return minor(inode->i_rdev);
+    return MINOR(inode->i_rdev);
 #else
     return MINOR(inode->i_rdev);
 #endif
...works here.

>uname -r
2.6.0-test5-bk1

>fglrxinfo
display: :0.0 screen: 0
OpenGL vendor string: ATI Technologies Inc.
OpenGL renderer string: Radeon 8500 DDR Pentium 4 (SSE2)
OpenGL version string: 1.3 (X4.3.0-3.2.5).
hi and thanks for the answer!

sorry but I'm a :

in which directory can I find the firegl_public.c file? and the patch you mentioned?

I have the rpm packet of the driver, then I use alien to convert it to a .deb package (I use Debian Sid...) and I install it with dpkg -i



bye!
 
Old 09-22-2003, 10:40 AM   #4
UnTamed
Member
 
Registered: Dec 2002
Location: Qc, Canada
Distribution: CRUX
Posts: 317

Rep: Reputation: 30
Well then, see if dpkg -i installed the files properly,
The file that needs to be patched should have been installed to /lib/modules/fglrx/buil_mod/firegl_public.c .

The patch is the code I posted, copy/paste it to a text file [...in your /home/<user> for example], call it fglrx-2.6-test5.patch, then to apply,
#patch <original file> <patch file>
(ex.: patch /lib/modules/fglrx/buil_mod/firegl_public.c /home/<user>/fglrx-2.6-test5.patch)

Then cd /lib/modules/fglrx/buil_mod/ and run the make script to build the module,
sh make.sh
and install the module,
cd ..
sh make_install.sh

Run fglrxconfig and startx...
 
Old 09-22-2003, 11:42 AM   #5
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by UnTamed
Well then, see if dpkg -i installed the files properly,
The file that needs to be patched should have been installed to /lib/modules/fglrx/buil_mod/firegl_public.c .

The patch is the code I posted, copy/paste it to a text file [...in your /home/<user> for example], call it fglrx-2.6-test5.patch, then to apply,
#patch <original file> <patch file>
(ex.: patch /lib/modules/fglrx/buil_mod/firegl_public.c /home/<user>/fglrx-2.6-test5.patch)

Then cd /lib/modules/fglrx/buil_mod/ and run the make script to build the module,
sh make.sh
and install the module,
cd ..
sh make_install.sh

Run fglrxconfig and startx...

thank you very much for your detailed answer! I had never patched anything till now, for this reason I was a little confused about your previous answer!

I'll let you know the result of the operation, thank you again!

moly82
 
Old 09-22-2003, 12:59 PM   #6
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
hello again! I tried to apply the patch and compile the modules but...
When I appply the patch the message is this one (I don't know if it is correct or not )

Code:
Debian-Puff:/lib/modules/fglrx/build_mod# patch firegl_public.c /home/roby/fglrx-2.6-test5.patch
patch: **** Only garbage was found in the patch input.
Debian-Puff:/lib/modules/fglrx/build_mod#
...then when I try to compile the module...

Code:
Debian-Puff:/lib/modules/fglrx/build_mod# sh make.sh
ATI module generator V 2.0
==========================
probing for VMA API version...
cleaning...
patching 'highmem.h'...
skipping patch for 'drmP.h', not needed
skipping patch for 'drm_os_linux.h', not needed
doing Makefile based build for kernel 2.6.x and higher
make -C /lib/modules/2.6.0-test5/build SUBDIRS=/lib/modules/fglrx/build_mod/2.6.x modules
make[1]: Entering directory `/usr/src/linux-2.6.0-test5'
make[2]: `arch/i386/kernel/asm-offsets.s' is up to date.
  CHK     include/asm-i386/asm_offsets.h
*** Warning: Overriding SUBDIRS on the command line can cause
***          inconsistencies
  CC [M]  /lib/modules/fglrx/build_mod/2.6.x/agp3.o
  CC [M]  /lib/modules/fglrx/build_mod/2.6.x/nvidia-agp.o
  CC [M]  /lib/modules/fglrx/build_mod/2.6.x/agpgart_be.o
  CC [M]  /lib/modules/fglrx/build_mod/2.6.x/i7505-agp.o
  CC [M]  /lib/modules/fglrx/build_mod/2.6.x/firegl_public.o
/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function `firegl_stub_open':
/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:421: error: called object is not a function
/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function `__ke_inode_rdev_minor':
/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:847: warning: implicit declaration of function `minor'
make[2]: *** [/lib/modules/fglrx/build_mod/2.6.x/firegl_public.o] Error 1
make[1]: *** [/lib/modules/fglrx/build_mod/2.6.x] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.0-test5'
make: *** [kmod_build] Error 2
build succeeded with return value 0
ln: `./fglrx.ko': File exists
duplicating results into driver repository...
cp: cannot stat `fglrx.ko': No such file or directory
done.
==============================
You must change your working directory to /lib/modules/fglrx
and then call ./make_install.sh in order to install the built module.
....

Code:
Debian-Puff:/lib/modules/fglrx# sh make_install.sh
*** WARNING ***
Tailored kernel module for fglrx not present in your system.
You must go to /lib/modules/fglrx/build_mod subdir
and execute './make.sh' to build a fully customed kernel module.
Afterwards go to /lib/modules/fglrx and run './make_install.sh'
in order to install the module into your kernel's module repository.
(see readme.txt for more details.)
 
As of now you can still run your XServer in 2D, but hardware acclerated
OpenGL will not work and 2D graphics will lack performance.
 
failed.
Debian-Puff:/lib/modules/fglrx#
Do you know what went wrong?

thanx bye!
 
Old 09-23-2003, 07:45 AM   #7
UnTamed
Member
 
Registered: Dec 2002
Location: Qc, Canada
Distribution: CRUX
Posts: 317

Rep: Reputation: 30
>patch: **** Only garbage was found in the patch input.

That's definitely not good.

I uploaded the patch to my web space, here,
get it and see if it can apply cleanly.
...it did for me [...???]
 
Old 09-23-2003, 07:55 AM   #8
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
thank you very much! I'll try with it!
(but it seems to be the same than before! )

byeeee!
 
Old 09-27-2003, 10:02 AM   #9
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
hello UnTamed!

with your file the patch process give me no errors, and also when I build the fglrx module I have no errors, but after I configure fglrx with fglrxconfig (I chose the "internal" agpgart"...) and I reboot the system, whemn I run startx, the monitor is black! do you know why?

if I presso ctrl+alt+f2, and then I write
lsmod|grep fglrx

...I can see that the fglrx module is loaded and used, but the monitor remain black...

please help thanx!
 
Old 09-27-2003, 07:54 PM   #10
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
up!
 
Old 09-28-2003, 07:04 AM   #11
UnTamed
Member
 
Registered: Dec 2002
Location: Qc, Canada
Distribution: CRUX
Posts: 317

Rep: Reputation: 30
If you installed kernel-2.6 to benefit from the better support for agp v3.0 compliant boards, you need to pick "external agpgart" from "fglrxconfig".
This way you'll use the kernel's agpgart instead of the driver's [...internal].

If not [...and anyhow] everytime your X server starts [...or tries to], it writes to a log file, /var/log/XFree86.0.log.
Lines starting with <EE> are errors and those starting with <WW> are warnings, so the following commands, in your console, should return only those lines,
cat /var/log/XFree86.0.log | grep EE
cat /var/log/XFree86.0.log | grep WW
...see what they bring up.
 
Old 09-29-2003, 03:51 PM   #12
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
Unhappy More details...

Using the INTERNAL agpgart:

nano /etc/modules

#video and 3D:

#agpgart
#radeon
fglrx

When I try to run startx the screen is black and the only thing I can do is open another x server with ctrl+alt+f2

Attached you can find the errors and warning that I found inside XFree86.0.log:

[EE]
(II) Loading extension MIT-SCREEN-SAVER

[WW]
(WW) Open APM failed (/dev/apm_bios) (No such file or directory)
(WW) fglrx(0): Bad V_BIOS checksum
(WW) fglrx(0): board is an unknown third party board, chipset is supported


Please help me!


One question: I compiled the 2.6test6 kernel using the default istructions:

make bzImage
make modules
make modules_install
make install


...then I compiled the fglrx module with the two scripts (sh make.sh and sh make_install.sh).

After these operations I didn't do anything else... maybe the problem is that after I compile the fglrx module I have to compile again the kernel?

Last edited by moly82; 09-29-2003 at 03:53 PM.
 
Old 09-29-2003, 03:55 PM   #13
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
Using the EXTERNAL agpgart:

nano /etc/modules

#video and 3D:

agpgart
#radeon
fglrx

The X server starts correctly...but...



roby@Debian-Puff:~$ cat /var/log/XFree86.0.log|grep EE
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(II) Loading extension MIT-SCREEN-SAVER
(EE) fglrx(0): [agp] unable to acquire AGP, error "xf86_ENODEV"
(EE) fglrx(0): cannot init AGP



roby@Debian-Puff:~$ cat /var/log/XFree86.0.log|grep WW
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(WW) Open APM failed (/dev/apm_bios) (No such file or directory)
(WW) fglrx(0): Bad V_BIOS checksum
(WW) fglrx(0): board is an unknown third party board, chipset is supported
(WW) fglrx(0): ***********************************************
(WW) fglrx(0): * DRI initialization failed! *
(WW) fglrx(0): * (maybe driver kernel module missing or bad) *
(WW) fglrx(0): * 2D acceleraton available (MMIO) *
(WW) fglrx(0): * no 3D acceleration available *
(WW) fglrx(0): ********************************************* *
roby@Debian-Puff:~$




FOR THIS REASONS, (I don't know how to solve them )


roby@Debian-Puff:~$ glxinfo |grep direct
direct rendering: No
OpenGL renderer string: Mesa GLX Indirect



roby@Debian-Puff:~$ fglrxinfo
display: :0.0 screen: 0
OpenGL vendor string: Mesa project: www.mesa3d.org
OpenGL renderer string: Mesa GLX Indirect
OpenGL version string: 1.3 Mesa 4.0.4

roby@Debian-Puff:~$




Last edited by moly82; 09-29-2003 at 03:58 PM.
 
Old 09-29-2003, 03:59 PM   #14
moly82
Member
 
Registered: May 2003
Location: Genoa - ITALY
Distribution: Debian SID
Posts: 84

Original Poster
Rep: Reputation: 15
I think the problem is that after I compile the fglrx module probably I have to compile again the kernel, or maybe I have to compile just the modules, but I don't know which operations I should do...

 
Old 09-29-2003, 05:44 PM   #15
UnTamed
Member
 
Registered: Dec 2002
Location: Qc, Canada
Distribution: CRUX
Posts: 317

Rep: Reputation: 30
Hmmm... what motherboard chipset do you have?

Recompiling your kernel after you install the fglrx driver won't accomplish anything, I'm afraid.

You could try, with your agpgart set to external, to load the agp module with the agp_try_unsupported=1 variable, ...but it's a long shot
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
ATI drivers and kernel 2.6.11 and later Metallic Linux - Hardware 8 03-31-2005 05:56 PM
ati drivers with kernel 2.6? shanenin Linux - Software 15 07-01-2004 08:46 PM
ATI Drivers with Kernel 2.6 redneon Linux - Hardware 3 02-29-2004 01:53 PM
2.6.2 kernel, with ati drivers. caffeinebot Linux - Software 2 02-22-2004 05:20 PM
ATi drivers and kernel 2.6.2 objorkum Linux - Hardware 0 02-08-2004 05:41 AM


All times are GMT -5. The time now is 09:02 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration