How do I re-enumerate the PCIe bus/tree my Hailo device is connected to?

The Hailo8 driver encountered an issue during the loading process. Upon running the dmesg command, the following output was observed:

The presence of the Hailo8 device was confirmed by running the lspci command and filtering the results for ‘Hailo’:

$ lspci | grep Hailo
01:00.0 Co-processor: Hailo Technologies Ltd. Hailo-8 AI Processor (rev 01)

The issue was resolved by re-enumerating the PCIe bus/tree to which the Hailo8 device is connected. The following commands were executed:

$ sudo -i
# `01:00.0` is the Hailo8's slot, as seen in `lspci`s output above
$ echo 1 >/sys/bus/pci/devices/0000\:01\:00.0/remove
$ echo 1 > /sys/bus/pci/rescan
$ exit

After re-enumerating, the driver must be re-loaded:

$ sudo modprobe -r hailo_pci
$ sudo modprobe hailo_pci

Here’s the dmesg output after the fix:

1 Like