[SOLVED] Catalyst 13.12 driver refuses to compile on 3.10.25 kernel
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Catalyst 13.12 driver refuses to compile on 3.10.25 kernel
I hope everyone is having a Merry Christmas!
I have a slight problem I'm hoping someone can help me with. I recently downloaded the latest AMD Catalyst driver (13.12) and the latest 3.10.x kernel from kernel.org (as of this posting it is 3.10.25). When I compiled the -generic version of the kernel, it booted fine, but when I ran the .run script, it refused to compile. The exact error message(s) is as follows:
Code:
AMD kernel module generator version 2.1
doing Makefile based build for kernel 2.6.x and higher
rm -rf *.c *.h *.o *.ko *.a .??* *.symvers
make -C /lib/modules/3.11.0-14-generic/build SUBDIRS=/var/lib/dkms/fglrx/13.251/build/2.6.x modules
make[1]: Entering directory `/usr/src/linux-headers-3.11.0-14-generic'
CC [M] /var/lib/dkms/fglrx/13.251/build/2.6.x/firegl_public.o
CC [M] /var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.o
/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.c: In function ‘KCL_ACPI_ParseTable’:
/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.c:999:5: warning: passing argument 1 of ‘(acpi_status (*)(u32, void *, void *))handler’ makes integer from pointer without a cast [enabled by default]
((acpi_table_handler)handler)(hdr);
^
/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.c:999:5: note: expected ‘u32’ but argument is of type ‘struct acpi_table_header *’
/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.c:999:5: error: too few arguments to function ‘(acpi_status (*)(u32, void *, void *))handler’
make[2]: *** [/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.o] Error 1
make[1]: *** [_module_/var/lib/dkms/fglrx/13.251/build/2.6.x] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.11.0-14-generic'
make: *** [kmod_build] Error 2
build failed with return value 2
I've checked on Phoronix's forums, but I'm unclear on exactly how to patch which file, and from then to install the driver.
AMD kernel module generator version 2.1
doing Makefile based build for kernel 2.6.x and higher
rm -rf *.c *.h *.o *.ko *.a .??* *.symvers
make -C /lib/modules/3.11.0-14-generic/build SUBDIRS=/var/lib/dkms/fglrx/13.251/build/2.6.x modules
make[1]: Entering directory `/usr/src/linux-headers-3.11.0-14-generic'
CC [M] /var/lib/dkms/fglrx/13.251/build/2.6.x/firegl_public.o
CC [M] /var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.o
/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.c: In function ‘KCL_ACPI_ParseTable’:
/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.c:999:5: warning: passing argument 1 of ‘(acpi_status (*)(u32, void *, void *))handler’ makes integer from pointer without a cast [enabled by default]
((acpi_table_handler)handler)(hdr);
^
/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.c:999:5: note: expected ‘u32’ but argument is of type ‘struct acpi_table_header *’
/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.c:999:5: error: too few arguments to function ‘(acpi_status (*)(u32, void *, void *))handler’
make[2]: *** [/var/lib/dkms/fglrx/13.251/build/2.6.x/kcl_acpi.o] Error 1
make[1]: *** [_module_/var/lib/dkms/fglrx/13.251/build/2.6.x] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.11.0-14-generic'
make: *** [kmod_build] Error 2
build failed with return value 2
It actually looks like you are building with kernel 3.11.0-14, which isn't the stock slackware 14.1 kernel of 3.10.17. Anyways, I also got the same error with kernel 3.10.17.
I actually found this forum post and this forum post helpful with the following instructions. Download the driver from amd.com, which you've already done.
Code:
# unzip amd-catalyst-13.12-linux-x86.x86_64.zip
# chmod +x amd-catalyst-13.12-linux-x86.x86_64.run
# vi kernel-3.9.1.patch
# ./amd-catalyst-13.12-linux-x86.x86_64.run --extract NewDirectory
# cd NewDirectory
# patch -p1 < ../kernel-3.9.1.patch
# su -c "./ati-installer.sh 13.251 --buildpkg Slackware/Slackware"
The final package should come out one directory above labeled as fglrx-13.251-x86_64-1.tgz (or the 32bit version, whichever fits your architecture). Install like any other Slackware package (eg. sudo /sbin/installpkg fglrx-13.251-x86_64-1.tgz).
It actually looks like you are building with kernel 3.11.0-14, which isn't the stock slackware 14.1 kernel of 3.10.17. Anyways, I also got the same error with kernel 3.10.17.
I actually found this forum post and this forum post helpful with the following instructions. Download the driver from amd.com, which you've already done.
Code:
# unzip amd-catalyst-13.12-linux-x86.x86_64.zip
# chmod +x amd-catalyst-13.12-linux-x86.x86_64.run
# vi kernel-3.9.1.patch
# ./amd-catalyst-13.12-linux-x86.x86_64.run --extract NewDirectory
# cd NewDirectory
# patch -p1 < ../kernel-3.9.1.patch
# su -c "./ati-installer.sh 13.251 --buildpkg Slackware/Slackware"
The final package should come out one directory above labeled as fglrx-13.251-x86_64-1.tgz (or the 32bit version, whichever fits your architecture). Install like any other Slackware package (eg. sudo /sbin/installpkg fglrx-13.251-x86_64-1.tgz).
I actually posted the error code from one of the posters on Phoronix's forum, since I couldn't find an exact copy of the error message in my log file, and I think the poster was using Ubuntu. However, the rest of your post was spot-on. Thanks a million for your advice. It was most helpful.
Matt
Note: I use the -generic kernel, and after installing the package, it would not load the fglrx.ko module. I found this odd because in the past, when I would install the Catalyst driver, the module would automatically load. However, now I had to explicitly delineate that the fglrx module be loaded in addition to the usual suspects in the 'mkinitrd' command. Other than that, the package worked as intended.
Last edited by 1337_powerslacker; 12-25-2013 at 11:09 PM.
Reason: Added note for later reference
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.