Driver Development Kit (DDK)

cancel
Showing results for 
Search instead for 
Did you mean: 

MHDDK broken on Linux kernel 4.0

Solved!
Go to solution

One of the tools that ships with MHDDK is broken on new Linux kernels.

 

The problem is easy to reproduce:

 

cd nimhddk_linuxkernel/LinuxKernel/nirlpk

make

sudo make install

 

gives the following error:

 

nirlp: 4.0.0-040000-generic kernel not supported

 

Directly executing nirlp gives the same error. Older kernels (e.g. 3.13) don't have this issue.

 

Without this tool, none of the examples can even access the board.

 

This issue will presumably affect all new kernels. Since this tool is binary-only, a fix will have to come from NI.

 

NI, please provide a fix or workaround for this issue.

0 Kudos
Message 1 of 3
(7,400 Views)
Solution
Accepted by topic author drobson

drobson wrote:

 

 Since this tool is binary-only, a fix will have to come from NI.

The MHDDK is 100% source code, scripts, and Makefiles -- all editable text files.

 

The nirlp file is a bash script, and it includes a check for kernel versions that were tested with the DDK examples. The last time the kernel module was updated was during the Linux 3.6 window. You can change the script to allow for newer kernels, and since you were able to compile the module, it looks hopeful that the module will load and support your devices.

Joe Friedchicken
NI Configuration Based Software
Get with your fellow OS users
[ Linux ] [ macOS ]
Principal Software Engineer :: Configuration Based Software
Senior Software Engineer :: Multifunction Instruments Applications Group (until May 2018)
Software Engineer :: Measurements RLP Group (until Mar 2014)
Applications Engineer :: High Speed Product Group (until Sep 2008)
Message 2 of 3
(7,388 Views)

Oops, I should have checked if it was a bash script.

 

I can confirm that MHDDK is working well on 4.0.0-040000-generic after modifying the nirlp script:

 

if [ "$kernelMajor" == "2" -a "$kernelMinor" == "6" -o "$kernelMajor" == "3" -o "$kernelMajor" == "4" ]; then

 

Thanks very much for your prompt response!

-Drew

0 Kudos
Message 3 of 3
(7,380 Views)