Regarding compilation problem on kernel verison 2.4.20-8

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,
I had couple of dummy drivers and kernel modules running on RH 7.3 and kernel version 2.4.18-3... laterly i upgraded to RH 9 and the version is 2.4.20-8. When I compile th moudles on the latest verison, I m getting lots and lots of compilation erros. Could somebody let me knw whts the issue.


Attached is the compilation erros:

In file included from /usr/include/linux/fs.h:23,
                 from module.c:5:
/usr/include/linux/string.h:8:2: warning: #warning Using kernel header in userla
nd!
In file included from /usr/include/linux/sched.h:14,
                 from /usr/include/linux/mm.h:4,
                 from module.c:6:
/usr/include/linux/timex.h:173: field `time' has incomplete type
In file included from /usr/include/linux/bitops.h:69,
                 from /usr/include/asm/system.h:7,
                 from /usr/include/linux/sched.h:16,
                 from /usr/include/linux/mm.h:4,
                 from module.c:6:
/usr/include/asm/bitops.h:327:2: warning: #warning This includefile is not avail
able on all architectures.
/usr/include/asm/bitops.h:328:2: warning: #warning Using kernel headers in users
pace: atomicity not guaranteed
In file included from /usr/include/linux/signal.h:4,
                 from /usr/include/linux/sched.h:25,
                 from /usr/include/linux/mm.h:4,
                 from module.c:6:
/usr/include/asm/signal.h:107: parse error before "sigset_t"
/usr/include/asm/signal.h:110: parse error before '}' token
In file included from /usr/include/linux/sched.h:81,
                 from /usr/include/linux/mm.h:4,
                 from module.c:6:
/usr/include/linux/timer.h:45: parse error before "spinlock_t"
/usr/include/linux/timer.h:53: parse error before '}' token
/usr/include/linux/timer.h:67: parse error before "tvec_base_t"
/usr/include/linux/timer.h:101: parse error before "tvec_bases"
/usr/include/linux/timer.h: In function `init_timer':
/usr/include/linux/timer.h:105: dereferencing pointer to incomplete type
/usr/include/linux/timer.h:105: dereferencing pointer to incomplete type
/usr/include/linux/timer.h:106: dereferencing pointer to incomplete type
/usr/include/linux/timer.h: In function `timer_pending':
/usr/include/linux/timer.h:121: dereferencing pointer to incomplete type
module.c:7:25: asm/uaccess.h: No such file or directory
module.c: At top level:
module.c:12: field `sem' has incomplete type
module.c:19: warning: `struct file' declared inside parameter list
module.c:19: warning: its scope is only this definition or declaration, which is
 probably not what you want
module.c:19: warning: `struct inode' declared inside parameter list
module.c: In function `scull_open':
module.c:22: dereferencing pointer to incomplete type
module.c: At top level:
module.c:25: warning: `struct file' declared inside parameter list
module.c:25: warning: `struct inode' declared inside parameter list
module.c:31: warning: `struct file' declared inside parameter list
module.c: In function `scull_read':
module.c:35: dereferencing pointer to incomplete type
module.c:36: warning: implicit declaration of function `down_interruptible'
module.c:37: `ERESTARTSYS' undeclared (first use in this function)
module.c:37: (Each undeclared identifier is reported only once
module.c:37: for each function it appears in.)
module.c:39: warning: implicit declaration of function `up'
module.c:44: warning: implicit declaration of function `printk'
module.c:45: warning: implicit declaration of function `copy_to_user'
module.c: At top level:
module.c:52: warning: `struct file' declared inside parameter list
module.c: In function `scull_write':
module.c:56: dereferencing pointer to incomplete type
module.c:58: `ERESTARTSYS' undeclared (first use in this function)
module.c:64: warning: implicit declaration of function `kfree'
module.c:66: warning: implicit declaration of function `kmalloc'
module.c:66: `GFP_KERNEL' undeclared (first use in this function)
module.c:67: warning: implicit declaration of function `copy_from_user'
module.c:55: warning: unused variable `i'
module.c: In function `init_module':
module.c:78: invalid use of undefined type `struct file_operations'
module.c:79: invalid use of undefined type `struct file_operations'
module.c:80: invalid use of undefined type `struct file_operations'
module.c:81: invalid use of undefined type `struct file_operations'
module.c:82: warning: implicit declaration of function `sema_init'
module.c:83: warning: implicit declaration of function `register_chrdev'
module.c: In function `cleanup_module':
module.c:90: warning: implicit declaration of function `unregister_chrdev'
module.c: At top level:
module.c:9: storage size of `fops' isn't known


Thanks,
Senthil

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux