[suse-sparc] Kernel Module building problem

From: Murray Atkinson (murray.atkinson_at_catapult.com)
Date: Mon Aug 19 2002 - 03:22:08 CEST

  • Next message: Greg Newby: "[suse-sparc] Booting Blade 2000 "not enough memory""
    Message-Id: <200208190122.LAA22193@melbourne.catapult.com>
    From: Murray Atkinson <murray.atkinson@catapult.com>
    Date: Mon, 19 Aug 2002 11:22:08 +1000
    Subject: [suse-sparc] Kernel Module building problem
    

    Hi,

    we are trying to build a kernel module for a PCI card that we use in a Sparc
    Ultra10 under Solaris.

    Is there any documentation or examples about building kernel modules for SuSE
    Sparc 7.3 ?

    We've been using "Linux Device Drivers" from O'Reilly and have been able to
    develop a module under SuSE 7.3 on a PC, and are having problems building
    this module on a Sparc Ultra 10 platform.

    When we compile our source code, we get the following error:

    In file included from /lib/modules/2.4.14/build/include/asm/processor.h:23,
                     from /lib/modules/2.4.14/build/include/linux/prefetch.h:13,
                     from /lib/modules/2.4.14/build/include/linux/list.h:6,
                     from /lib/modules/2.4.14/build/include/linux/module.h:12,
                     from base_drv.c:2:
    /lib/modules/2.4.14/build/include/asm/page.h:101: global register variable
    follows a function definition
    /lib/modules/2.4.14/build/include/asm/page.h:101: warning: call-clobbered
    register used for global register variable
    make: *** [base_drv.o] Error 1

    Does anyone know if we are we missing some sort of configuration option ?

    Any help would be greatly appreciated.

    Regards,

    Murray Atkinson.

    Our Makefile includes this:

    CC = /usr/bin/sparc64-linux-gcc -v

    CFLAGS = -DBASE_DRV_DEBUG -DKERNEL -D__KERNEL__ -DMODULE \
             -I$(KERNELINC) -O -Wall

    KERNELINC = /lib/modules/`uname -r`/build/include

    Our /lib/modules/2.4.14/build points to /usr/src/linux-2.4.14.SuSE/
    Our /lib/modules/2.4.14/build/include/linux/version.h contains
    #define UTS_RELEASE "2.4.14"
    #define LINUX_VERSION_CODE 132110
    #define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c))

    -- 
    To unsubscribe, e-mail: suse-sparc-unsubscribe@suse.com
    For additional commands, e-mail: suse-sparc-help@suse.com
    


    This archive was generated by hypermail 2.1.4 : Mon Aug 19 2002 - 03:22:20 CEST