irq_vectors.h not found
Hello
I am rewriting the code of a kernel module which was. The flags of request_irq have changed. Hence I changed request_irq(irq, vme_isr, SA_SHIRQ, MODULE_NAME, &file_ops)) to request_irq(irq, (void*) vme_isr, IRQF_SHARED, MODULE_NAME, &file_ops)). I also need to include linux/interrupt.h now. This results in irq_vectors.h not being found. NR_VECTORS, and NR_IRQS are undeclarded. I am using kernel version 2.6.24 Here my includes: #include "common.h" // this includes /linux/version.h , /linux/autoconf.h and linux/modversions.h #include <linux/types.h> #include <linux/list.h> #include <linux/wait.h> #include <linux/interrupt.h> And here the error message Code:
cc -D__KERNEL__ -DMODULE -DNO_RT -I/usr/src/linux-2.6.24/include/config -I/usr/src/linux-2.6.24/include -O -Wall -c -o vme_pb1650_main.o vme_pb1650_main.c Thanks Tilman |
Should we assume that you have *successfully* installed the kernel-devel package ?
|
I would think so: I have successfully compiled the kernel 2.6.24. It runs fine.
And I have successfully compiled a driver (kernel module for vme bus support) external to kernel. The question of yours is however a very valid one, as I do a cross compilation for an x86 embedded platlform. Maybe some paths are missing from my makefile. I given only /usr/src/linux-2.6.24/include as -I to gcc Tilman |
Here the files.
Makefile: Code:
KERNELREV:=2.6.24 Code:
#include "common.h" Code:
#ifndef __COMMON_H__ |
Try including this:
Code:
#include <asm/irq_vectors.h> http://osdir.com/ml/linux.newbie/2003-02/msg00142.html |
I added an additional include path:
-I/usr/src/linux-2.6.24/include/asm-x86/mach-default/ Now I am getting a warning message. Does it point to a serious issue ? Can I ignote it ? gcc -D__KERNEL__ -DNO_RT -DMODULE -I/usr/src/linux-2.6.24/include -I/usr/src/linux-2.6.24/include/asm-x86/mach-default/ -Wall -O2 -fPIC -c -o test1.o test1.c In file included from /usr/src/linux-2.6.24/include/asm/cmpxchg.h:2, from /usr/src/linux-2.6.24/include/asm/system_32.h:7, from /usr/src/linux-2.6.24/include/asm/system.h:2, from /usr/src/linux-2.6.24/include/asm/processor_32.h:18, from /usr/src/linux-2.6.24/include/asm/processor.h:2, from /usr/src/linux-2.6.24/include/asm/thread_info_32.h:16, from /usr/src/linux-2.6.24/include/asm/thread_info.h:2, from /usr/src/linux-2.6.24/include/linux/thread_info.h:34, from /usr/src/linux-2.6.24/include/linux/preempt.h:9, from /usr/src/linux-2.6.24/include/linux/interrupt.h:8, from test1.c:8: /usr/src/linux-2.6.24/include/asm/cmpxchg_32.h: In function '__set_64bit_var': /usr/src/linux-2.6.24/include/asm/cmpxchg_32.h:57: warning: dereferencing type-punned pointer will break strict-aliasing rules |
Do you mind thanking the person who's trying to help you ? I expected a little courtesy !
May be someone else can help you from here now. |
Dear Anisha
I do appreciate the time you invested to help me. I was just not sure if the issue is closed or if this is just the start of the next round :-) Thank you for your help Tilman |
Quote:
|
It did not work.
I then read a little bit about 2.6 kernel module developement and adapted the Makefile accordingly. That worked. Code:
KERNEL_VER := linux-2.6.24 Code:
//**************************************************************************** |
All times are GMT -5. The time now is 09:48 AM. |