euspectre/kedr

Fails to compile with linux 3.9

euspectre opened this issue · 2 comments

Original issue 13 created by euspectre on 2013-05-07T12:09:11.000Z:

What steps will reproduce the problem?

  1. mkdir build
  2. cd build
  3. cmake ..
  4. make

What version of the product are you using? On what operating system?
Archlinux testing/linux

Please provide any additional information below.

Scanning dependencies of target kedr
[ 2%] Generating arch/x86/lib/inat-tables.h
[ 2%] Generating kedr_module.c
[ 2%] Generating kedr_base.c
[ 2%] Generating kedr_instrumentor.c
[ 4%] Generating kedr_functions_support.c
[ 4%] Generating kedr_target_detector.c
[ 4%] Generating arch/x86/lib/inat.c
[ 4%] Generating arch/x86/lib/insn.c
[ 7%] Generating kedr.ko, Module.symvers
/tmp/kedr-0.4.1/build/core/kedr_base.c: In function ‘functions_map_add’:
/tmp/kedr-0.4.1/build/core/kedr_base.c:849:63: error: macro "hlist_for_each_entry" passed 4 arguments, but takes just 3
hlist_for_each_entry(map_elem, node_tmp, &map->heads[i], list)
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:849:2: error: ‘hlist_for_each_entry’ undeclared (first use in this function)
hlist_for_each_entry(map_elem, node_tmp, &map->heads[i], list)
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:849:2: note: each undeclared identifier is reported only once for each function it appears in
/tmp/kedr-0.4.1/build/core/kedr_base.c:850:2: error: expected ‘;’ before ‘{’ token
{
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:844:21: warning: unused variable ‘node_tmp’ [-Wunused-variable]
struct hlist_node* node_tmp;
^
/tmp/kedr-0.4.1/build/core/kedr_base.c: In function ‘functions_map_remove’:
/tmp/kedr-0.4.1/build/core/kedr_base.c:876:63: error: macro "hlist_for_each_entry" passed 4 arguments, but takes just 3
hlist_for_each_entry(map_elem, node_tmp, &map->heads[i], list)
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:876:2: error: ‘hlist_for_each_entry’ undeclared (first use in this function)
hlist_for_each_entry(map_elem, node_tmp, &map->heads[i], list)
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:877:2: error: expected ‘;’ before ‘{’ token
{
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:872:29: warning: unused variable ‘map_elem’ [-Wunused-variable]
struct functions_map_elem* map_elem;
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:871:21: warning: unused variable ‘node_tmp’ [-Wunused-variable]
struct hlist_node* node_tmp;
^
/tmp/kedr-0.4.1/build/core/kedr_base.c: In function ‘function_counters_table_get’:
/tmp/kedr-0.4.1/build/core/kedr_base.c:996:61: error: macro "hlist_for_each_entry" passed 4 arguments, but takes just 3
hlist_for_each_entry(elem, node_tmp, &table->heads[i], list)
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:996:2: error: ‘hlist_for_each_entry’ undeclared (first use in this function)
hlist_for_each_entry(elem, node_tmp, &table->heads[i], list)
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:997:2: error: expected ‘;’ before ‘{’ token
{
^
/tmp/kedr-0.4.1/build/core/kedr_base.c:991:21: warning: unused variable ‘node_tmp’ [-Wunused-variable]
struct hlist_node* node_tmp;
^
make[4]: *** [/tmp/kedr-0.4.1/build/core/kedr_base.o] Error 1
make[3]: *** [module/tmp/kedr-0.4.1/build/core] Error 2
make[2]: *** [core/kedr.ko] Error 2
make[1]: *** [core/CMakeFiles/kedr.dir/all] Error 2
make: *** [all] Error 2

Comment #1 originally posted by euspectre on 2013-05-07T14:32:07.000Z:

I suppose this is because of the following commit to the kernel:
"hlist: drop the node parameter
from iterators" (b67bfe0d42cac56c512dd5da4b1b347a23f4b70a)

I'll fix that in KEDR and KernelStrider.

Thanks for reporting!

Comment #2 originally posted by euspectre on 2013-05-14T06:53:32.000Z:

Fixed in the repository.