디바이스 드라이버 예제 실행시 다음과 같은 에러가....
debian:~# make
gcc -O2 -Wall -DMODULE -D__KERNEL__ -DLINUX -I/usr/src/linux-headers-2.6.18-6-486/include -c organ.c
~~~~~~
/usr/src/linux-headers-2.6.18-6-486/include/asm/processor.h:80: error: ‘CONFIG_X86_L1_CACHE_SHIFT’ undeclared here (not in a function)
/usr/src/linux-headers-2.6.18-6-486/include/asm/processor.h:80: error: requested alignment is not a constant
~~~~~
/usr/src/linux-headers-2.6.18-6-486/include/asm/rwsem.h: In function ‘__down_read’:
/usr/src/linux-headers-2.6.18-6-486/include/asm/rwsem.h:104: error: expected ‘:’ or ‘)’ before ‘KBUILD_BASENAME’
/usr/src/linux-headers-2.6.18-6-486/include/asm/rwsem.h: In
~~~~~~
organ.c:72: error: ‘MOD_IN_USE’ undeclared (first use in this function)
organ.c:72: error: (Each undeclared identifier is reported only once
organ.c:72: error: for each function it appears in.)
organ.c:73: error: ‘MOD_INC_USE_COUNT’ undeclared (first use in this function)
~~~
이런 에러들이 ....
데비안 etch4.0 r3 설치하니 소스는 없어서
apt-get으로 linux-headers-2.6.18-6-486 설치했습니다.
댓글 달기