tthtlc / compcache

Automatically exported from code.google.com/p/compcache
0 stars 0 forks source link

error in : xvmalloc.c when launch make in compcache.0.5.1 #25

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. In linux Sles10 SP2 kernel 2.6.16.60-0.21-smp
2. launch make 
3.

What is the expected output? What do you see instead?
This is the error to launch make in this version 0.5.1 . In other versions:
0.5pre3,and 0.5pre4 the error not apper.

linux03:/var/tmp/compcache-0.5.1 # make
make -C /lib/modules/2.6.16.60-0.21-smp/build M=/var/tmp/compcache-0.5.1
modules
make[1]: Entering directory `/usr/src/linux-2.6.16.60-0.21-obj/x86_64/smp'
make -C ../../../linux-2.6.16.60-0.21
O=../linux-2.6.16.60-0.21-obj/x86_64/smp modules
  CC [M] 
/var/tmp/compcache-0.5.1/sub-projects/compression/lzo-kmod/lzo1x_decompress.o
  CC [M] 
/var/tmp/compcache-0.5.1/sub-projects/compression/lzo-kmod/lzo1x_compress.o
  CC [M] 
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.o
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:105:
warning: ‘enum km_type’ declared inside parameter list
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:105:
warning: its scope is only this definition or declaration, which is
probably not what you want
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:105:
error: parameter 3 (‘type’) has incomplete type
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:112:
warning: ‘enum km_type’ declared inside parameter list
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:112:
error: parameter 2 (‘type’) has incomplete type
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:
In function ‘InsertBlock’:
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:202:
error: ‘KM_USER1’ undeclared (first use in this function)
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:202:
error: (Each undeclared identifier is reported only once
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:202:
error: for each function it appears in.)
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:203:
error: type of formal parameter 3 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:206:
error: type of formal parameter 2 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:
In function ‘RemoveBlockHead’:
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:233:
error: ‘KM_USER1’ undeclared (first use in this function)
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:234:
error: type of formal parameter 3 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:237:
error: type of formal parameter 2 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:
In function ‘RemoveBlock’:
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:258:
error: ‘KM_USER1’ undeclared (first use in this function)
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:259:
error: type of formal parameter 3 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:262:
error: type of formal parameter 2 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:269:
error: type of formal parameter 3 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:272:
error: type of formal parameter 2 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:
In function ‘GrowPool’:
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:290:
error: ‘KM_USER0’ undeclared (first use in this function)
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:290:
error: type of formal parameter 3 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:299:
error: type of formal parameter 2 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:
In function ‘xvMalloc’:
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:375:
error: ‘KM_USER0’ undeclared (first use in this function)
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:375:
error: type of formal parameter 3 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:409:
error: type of formal parameter 2 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:
In function ‘xvFree’:
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:427:
error: ‘KM_USER0’ undeclared (first use in this function)
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:427:
error: type of formal parameter 3 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:465:
error: type of formal parameter 2 is incomplete
/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.c:483:
error: type of formal parameter 2 is incomplete
make[4]: ***
[/var/tmp/compcache-0.5.1/sub-projects/allocators/xvmalloc-kmod/xvmalloc.o]
Error 1
make[3]: *** [_module_/var/tmp/compcache-0.5.1] Error 2
make[2]: *** [modules] Error 2
make[1]: *** [modules] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.16.60-0.21-obj/x86_64/smp'

What version of the product are you using? On what operating system?

The version compcache is: 0.5.1 and SO: 
Linux linux03 2.6.16.60-0.21-smp #1 SMP Tue May 6 12:41:02 UTC 2008 x86_64
x86_64 x86_64 GNU/Linux
Sles10 SP2

Please provide any additional information below.

Original issue reported on code.google.com by juch...@gmail.com on 9 Feb 2009 at 10:43

GoogleCodeExporter commented 9 years ago
In 2.6.16, "enum km_type" is not defined if CONFIG_HIGHMEM is not set. This is 
evil
done on Linux kernel side. I will add some #ifdef's to work around this issue.

Original comment by nitingupta910@gmail.com on 10 Feb 2009 at 4:01

GoogleCodeExporter commented 9 years ago
Try adding: #include <asm/kmap_types.h> to compcache.c

Original comment by nitingupta910@gmail.com on 26 Feb 2009 at 5:57

GoogleCodeExporter commented 9 years ago
Fixed in SVN r305.

Original comment by nitingupta910@gmail.com on 2 Mar 2009 at 8:35