When executing OpenCL™ host applications on an attached development kit while IOMMU (e.g. intel_iommu) is enabled in a Linux Kernel, a kernel panic may occur and cause the host to hang.
This may happen even if 'aocl diagnose' and 'aocl program' pass. The hang occurs because the OpenCL™ board support packages (BSPs) for the development kits don't support SR-IOV.
To work around this problem, disable IOMMU functionality :
For example on CentOS7.4, with grub2, UEFI and intel_iommu :
1. Edit /etc/default/grub and delete the following line.
intel_iommu=on in GRUB_CMDLINE_LINUX
2. Update grub configuration file
grub2-mkconfig -o /boot/efi/EFI/centos/grub.cfg
3. Reboot
4. Check /proc/cmdline
Ensure intel_iommu=on does not appear on the kernel command line.
This workaround does not apply to the Intel FPGA Programmable Acceleration Card (PAC) since that OpenCL™ BSP does support SR-IOV. If IOMMU is disabled when using the PAC, refer to the Intel® Acceleration Stack Quick Start Guide for instructions to enable the Intel IOMMU driver.