The following applications demonstrate some of the user-level interrupt (ULI) interface:
The applications are installed with the ULI RPM and are located in:
/usr/share/react/uli/examples/ |
The uli_sample program registers for notification on CPU 0 for occurrences of a specified interrupt number. To use uli_sample, do the following:
Load the ULI feature kernel module:
[root@linux root]# modprobe uli |
Change to the directory containing uli_sample:
[root@linux root]# cd /usr/share/react/uli/examples/ |
Run uli_sample, where interrupt# is the interrupt number:
[root@linux root]# ./uli_sample interrupt# |
For example, to register for notification on CPU 0 for occurrences of the interrupt number 34, enter the following:
[root@linux root]# ./uli_sample 34 |
The uli_ei program requires the external interrupt to run and prints a message every time the external interrupt line is toggled. To use uli_ei, do the following:
Load the ULI feature kernel module, if not already done:
[root@linux root]# modprobe uli |
Load the external interrupt kernel module:
[root@linux root]# modprobe pcie_rt |
Set the external interrupt mode to toggle:
[root@linux root]# echo toggle > /sys/class/extint/extint0/mode |
Change to the directory containing uli_ei:
[root@linux root]# cd /usr/share/react/uli/examples/ |
Run uli_ei:
[root@linux root]# ./uli_ei |