Intel® Business Client Software Development
Support for Intel® vPro™ software development and technologies associated with Intel vPro platforms.
1381 Discussions

copy_to_user() error when compiling open source AMT driver

opperpanter
Beginner
611 Views

Hello,

I downloaded the Linux AMT drivers from http://software.intel.com/en-us/articles/download-the-latest-intel-amt-open-source-drivers/#comment-61036

The article by Jeffrey Rott.

I tried to compile (make) on Debian Squeeze (2.6.32-amd64), but this fails:

root@NAS2:/home/qst/mei7/mei-7.1.20# make

cd src && make

make[1]: Entering directory `/home/qst/mei7/mei-7.1.20/src'

make -C /lib/modules/`uname -r`/build M=`pwd` modules

make[2]: Entering directory `/usr/src/linux-headers-2.6.32-5-amd64'

CC /home/qst/mei7/mei-7.1.20/src/iorw.o

/home/qst/mei7/mei-7.1.20/src/iorw.c: In function amthi_read:

/home/qst/mei7/mei-7.1.20/src/iorw.c:368: error: implicit declaration of funcn copy_to_user

make[5]: *** [/home/qst/mei7/mei-7.1.20/src/iorw.o] Error 1

make[4]: *** [_module_/home/qst/mei7/mei-7.1.20/src] Error 2

make[3]: *** [sub-make] Error 2

make[2]: *** [all] Error 2

make[2]: Leaving directory `/usr/src/linux-headers-2.6.32-5-amd64'

make[1]: *** [all] Error 2

make[1]: Leaving directory `/home/qst/mei7/mei-7.1.20/src'

make: *** [all] Error 2

root@NAS2:/home/qst/mei7/mei-7.1.20# ls

COPYING Makefile README src

Since I am new to linux, it might be something simple.

What do I need to change to fix this. Is this some compiler setting? Some kernel flag or come missing kernel library/header?

The README doesn't have info about requirements, so I am not sure whether my kernel version is approprioate.

Thanks!


0 Kudos
2 Replies
opperpanter
Beginner
611 Views
Most google results told me to include a header file:
#include
This didn't work.
Since the MEI/AMT driver will be part of kernel 3.0 (2.6.40), I tried to look up the source code for that:
That version of the file is newer than the one in the download offered by Intel.
One of the differences is addition of:
#include
Now it compiles!
0 Kudos
Judy_H_Intel
Employee
611 Views
Hi opperpanter,
I'm glad you got it figured out and I'm also glad that you posted here so other developers will be able to see the solution.

Thanks,
Judy
0 Kudos
Reply