Solution
This issue was caused by a SMBALERT_DIS bit of SLVCMD register that enables polling on i801_smbus interrupt, which increases the CPU usage. This was determined to be a bug. There are several solutions to this issue, depending on NI Linux Real-Time versions installed on NI cRIO 904x.
Before implementing the solution in this article, please ensure that you are using NI cRIO 904x Revision C normal or TPM controller AND observe high CPU Interrupts on i801_SMB. Please refer to
Find the Revision of NI Hardware link on the method on how to check the revision version of your NI cRIO 904x. To check whether high CPU interrupts is caused by i801_SMB, please run
cat /proc/interrupts command in console out. Please refer to
Accessing the Shell on NI Linux Real-Time Devices link for the method on how to connect to your controller’s console via SSH and the picture below.
NI Linux Real Time version can be checked by going into your controller’s
System Settings in
NI MAX. Please refer to picture below.
If NI Linux Real-Time version is later than x64 4.9.47-rt37-6.0.0f1 version (NI CompactRIO 18.5):
- Update the BIOS version on your NI cRIO 904x to BIOS version 2.0.3f0 and later. The latest BIOS version can be downloaded from cRIO-904x Firmware and Additional Drivers link.
- Please refer to the readme file for a guide to update BIOS, which will be included with the BIOS installation file. You can also refer to CompactRIO 904x Firmware and Additional Drivers Readme link.
- Please take note that NI does not support downgrading BIOS version and is not responsible for any damage that is caused by downgrading BIOS.
If NI Linux Real-Time version is same or older than x64 4.9.47-rt37-6.0.0f1 version (NI CompactRIO 18.5), please implement either one of the following methods.
METHOD 1: Creating a RTOS file to set SMBALERT_DIS bit of SLVCMD register:
- Please first update BIOS version on NI cRIO 9040x to BIOS version 2.0.3f0 and later. Please refer to “If NI Linux Real-Time version is later than x64 4.9.47-rt37-6.0.0f1 version (NI CompactRIO 18.5)” section for additional information.
- Reboot your controller and initiate an SSH connection. Please refer to Accessing the Shell on NI Linux Real-Time Devices link for guide.
- For this step, please create a RTOS script file. To create the RTOS file, input cat > /etc/rc5.d/S01smbfix line and press Enter. Input #! /bin/bash line and press Enter. Next, input devmem 0x91612011 8 0x5 line and press Enter. Finally, press <Ctrl-D>. This command line will create and save a RTOS file in the controller’s local location. Once the script file has been saved, the console will prompt to set permission for the script file.
- Input chmod +x /etc/rc5.d/S01smbfix line and press Enter. This will set permission for the script file. This completes the process of creating the RTOS script file. Please refer to the picture below.
- Next, exit from console out and reboot your controller by pressing the Restart button in NI MAX. Please refer to picture below
- Reconnect to your controller’s console out and run devmem 0x91612011 8 command and check if the output is 0x05. Run cat /proc/interrupts command and check whether high CPU usage on i801_smbus interrupt is resolved. Please refer to the picture below.
METHOD 2: Instruct modprobe to ignore i801_smbus interrupt.
- Initiate an SSH connection. Please refer to Accessing the Shell on NI Linux Real-Time Devices link for guide.
- Input echo "options i2c-i801 disable_features=0x10" >> /etc/modprobe.d/i2c-i801.conf && reboot line and press Enter.
- Run cat /proc/interrupts command and check whether high CPU usage on i801_smbus interrupt is resolved.
After implementing the solution above, the CPU usage caused by i801_smbus interrupt should be resolved.