warning: kernel 3.7.1.1 breaks fglrx-12.6-legacy driver

just updated to Kernel: 3.7.1-1-desktop x86_64
from Kernel: 3.6.10-1-desktop x86_64

re-install of the fglrx-12.6-legacy driver failed with the message


********************************************************************************
*   Build date: Wed Dec 19 03:56:47 CET 2012                                   *
********************************************************************************

Used CPUs/Cores for compilation  =>   4 ]

********************************************************************************
*                                                                              *
*   Kernel:    3.7.1-1-desktop                                                 *
*   Source:    /lib/modules/3.7.1-1-desktop/build                              *
*   Include:   /lib/modules/3.7.1-1-desktop/source/include                     *
*                                                                              *
********************************************************************************

file /lib/modules/3.7.1-1-desktop/source/include/../arch/x86/include/asm/compat.h says:COMPAT_ALLOC_USER_SPACE=arch_compat_alloc_user_space
/usr/src/kernel-modules/fglrx/2.6.x /
rm -rf *.c *.h *.o *.ko *.a .??* *.symvers
make: Entering directory `/usr/src/linux-3.7.1-1-obj/x86_64/desktop'
  LD      /usr/src/kernel-modules/fglrx/2.6.x/built-in.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_agp.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_acpi.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_debug.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_ioctl.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_io.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_pci.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_str.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_iommu.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_wait.o
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function 'KCL_GetInitKerPte':
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2402:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2403:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2404:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function 'KCL_GetPageTableByVirtAddr':
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2449:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2452:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2453:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function 'KCL_TestAndClearPageDirtyFlag':
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2627:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function 'KCL_MEM_VM_MapRegion':
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:3715:39: error: 'VM_RESERVED' undeclared (first use in this function)
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:3715:39: note: each undeclared identifier is reported only once for each function it appears in
make[3]: *** [/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[2]: *** [_module_/usr/src/kernel-modules/fglrx/2.6.x] Error 2
make[1]: *** [sub-make] Error 2
make: *** [all] Error 2
make: Leaving directory `/usr/src/linux-3.7.1-1-obj/x86_64/desktop'

******************************
Build of kernel module failed!
******************************

rm -rf *.c *.h *.o *.ko *.a .??* *.symvers
/
Calling 'depmod -a 3.7.1-1-desktop' this may take a while...

Summary report:
================================================================================

   Kernel     => 3.7.1-1-desktop
   Detected   => RPM package
   Build      => e[1;31m FAILURE ]
   Install    => e[1;31m FAILURE ]

Any suggestions appreciated, I’m off for some kip.

On 12/18/2012 09:56 PM, keellambert wrote:
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2402:5: warning: return makes integer from pointer without a cast [enabled by default]
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2403:5: warning: return makes integer from pointer without a cast [enabled by default]
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2404:5: warning: return makes integer from pointer without a cast [enabled by default]
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function ‘KCL_GetPageTableByVirtAddr’:
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2449:5: warning: return makes integer from pointer without a cast [enabled by default]
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2452:5: warning: return makes integer from pointer without a cast [enabled by default]
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2453:5: warning: return makes integer from pointer without a cast [enabled by default]
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function ‘KCL_TestAndClearPageDirtyFlag’:
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2627:5: warning: return makes integer from pointer without a cast [enabled by default]
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function ‘KCL_MEM_VM_MapRegion’:
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:3715:39: error: ‘VM_RESERVED’ undeclared (first use in this function)
> /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:3715:39: note: each undeclared identifier is reported only once for each function it appears in

Somewhere at the beginning of firegl_public.c, add the following 3 lines:

#ifndef VM_RESERVED
#define VM_RESERVED (VM_DONTEXPAND | VM_DONTDUMP)
#endif

The problem is that the symbol VM_RESERVED was removed from kernel 3.7.

Unfortunately I don’t believe it will compile with the version of xorg in factory.

@lwfinger

inserted your patch at line 100 and the
fglrx64_legacy_xpic_SUSE122-8.97.100.3-2.x86_64
driver module installed automatically

many thanks

the install log is as follows


********************************************************************************
*   Build date: Wed Dec 19 06:40:46 CET 2012                                   *
********************************************************************************

Used CPUs/Cores for compilation  =>   4 ]

********************************************************************************
*                                                                              *
*   Kernel:    3.7.1-1-desktop                                                 *
*   Source:    /lib/modules/3.7.1-1-desktop/build                              *
*   Include:   /lib/modules/3.7.1-1-desktop/source/include                     *
*                                                                              *
********************************************************************************

file /lib/modules/3.7.1-1-desktop/source/include/../arch/x86/include/asm/compat.h says:COMPAT_ALLOC_USER_SPACE=arch_compat_alloc_user_space
/usr/src/kernel-modules/fglrx/2.6.x /
rm -rf *.c *.h *.o *.ko *.a .??* *.symvers
make: Entering directory `/usr/src/linux-3.7.1-1-obj/x86_64/desktop'
  LD      /usr/src/kernel-modules/fglrx/2.6.x/built-in.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/firegl_public.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_acpi.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_agp.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_debug.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_ioctl.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_io.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_pci.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_str.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_iommu.o
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function 'KCL_GetInitKerPte':
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2406:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2407:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2408:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function 'KCL_GetPageTableByVirtAddr':
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2453:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2456:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2457:5: warning: return makes integer from pointer without a cast [enabled by default]
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c: In function 'KCL_TestAndClearPageDirtyFlag':
/usr/src/kernel-modules/fglrx/2.6.x/firegl_public.c:2631:5: warning: return makes integer from pointer without a cast [enabled by default]
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl.o
  CC [M]  /usr/src/kernel-modules/fglrx/2.6.x/kcl_wait.o
  LD [M]  /usr/src/kernel-modules/fglrx/2.6.x/fglrx.o
  Building modules, stage 2.
  MODPOST 1 modules
  CC      /usr/src/kernel-modules/fglrx/2.6.x/fglrx.mod.o
  LD [M]  /usr/src/kernel-modules/fglrx/2.6.x/fglrx.ko
make: Leaving directory `/usr/src/linux-3.7.1-1-obj/x86_64/desktop'
make: Entering directory `/usr/src/linux-3.7.1-1-obj/x86_64/desktop'
  INSTALL /usr/src/kernel-modules/fglrx/2.6.x/fglrx.ko
  DEPMOD  3.7.1-1-desktop
make: Leaving directory `/usr/src/linux-3.7.1-1-obj/x86_64/desktop'
rm -rf *.c *.h *.o *.ko *.a .??* *.symvers
/
Calling 'depmod -a 3.7.1-1-desktop' this may take a while...

Summary report:
================================================================================

   Kernel     => 3.7.1-1-desktop
   Detected   => RPM package
   Build      =>  OK ]
   Install    =>  OK ]

@lwfinger

Many thanks!

Work like a charm

kernel 3.7.1-1-desktop
fglrx64_xpic_SUSE121 9.002-1 x86_64

This one should work
http://paste.opensuse.org/view/raw/81285329

I get this error:


Check if system has the tools required for installation.
fglrx installation requires that the system have kernel headers.
/lib/modules/3.7.1-vampird/build/include/linux/version.h cannot be found
on this system.
One or more tools required for installation cannot be found on the
system. Install the required tools before installing the fglrx driver.
Optionally, run the installer with --force option to install without the
tools.
Forcing install will disable AMD hardware acceleration and may make your
system unstable. Not recommended.

and yes, I have the kernel sources, I just finish the compilation

@VampirD

check that you have the following packages installed before installing the driver,
all are needed,

kernel-default-devel
kernel-desktop
kernel-desktop-devel
kernel-devel
kernel-source
kernel-syms
kernel-xen-devel
kernel-firmware

the version should be the same for all except kernel-firmware

Check if system has the tools required for installation. fglrx installation requires that the system have kernel headers. /lib/modules/3.7.1-vampird/build/include/linux/version.h cannot be found

This is some custom kernel you have?

@sumski

this looks to me as though VampirD has installed a new kernel as a user with
root privileges and not as root

I suggest to VampirD he installs Kernel: 3.7.1-1-desktop x86_64 (64 bit)
from Index of /repositories/Kernel:/stable/standard
with yast program manager

as always, I downloaded the latest kernel from kernel.org, compile it,
and installed it. I’ll try with the kernel from repos T_T

Seamless update, thanks!

Sat Dec 29 09:34:21 CET 2012
updated to Kernel: 3.7.1-2-desktop x86_64 (64 bit)
from Kernel: 3.7.1-1-desktop x86_64 (64 bit)

on Desktop KDE 4.9.4 Distro: openSUSE 12.2 (x86_64) VERSION = 12.2,
AMD Phenom II X4 940, ATI RS780 [Radeon HD 3200],
driver: fglrx Resolution: 1920x1080@60.0hz, 1680x1050@60.0hz

1st.reboot took 50 seconds per systemd-analyze plot
2nd.reboot took 18 seconds

@lwfinger

is the 3 line patch still needed with kernel 3.7.1-2-desktop x86_64 (64 bit)?

thx

On 01/04/2013 05:46 AM, keellambert wrote:
>
> @lwfinger
>
> is the 3 line patch still needed with kernel 3.7.1-2-desktop x86_64 (64
> bit)?

I don’t know as I only have nVidia and i915 graphics adapters, but my guess is
“yes”. One advantage of that patch is that if it is not needed, then it does
nothing.