Forum Discussion
Altera_Forum
Honored Contributor
9 years agoPlease ignore the question in my post above.
As far as I know, compiling driver for desktop linux requires kernel header files which are usually set under /usr/src, and with the same kernel version number; Compiling driver for embedded linux usually needs the linux source code direcory where you build your zImage for the board, not header files. In other words: (1) For desktop linux: make -C /usr/src/(header file directory) M=${PWD} modules; (2) For embedded linux: make ARCH=arm -C /linux-socfpga-ret-ltsi M=${PWD} modules; I have successfully compiled a simple driver for my Arrow SoC like this, but the difference are not sure. Could be that desktop linux is too large for you to have all source code; and embedded linux usually not that large so that you can work under its source code directory which already contains header files.