Hailort driver Installation issues / Raspberry Pi 5 Ubuntu Desktop 24.04.01 LTS

Hi, I need your help regarding my Hailo 8 M.2 (M-key version).

In short: I am trying to get the hailort-driver working on my Raspberry Pi 5 running Ubuntu Desktop 24.04.01 LTS with kernel: 6.8.0-1018-raspi
, but it won’t work.

I’ve tried to install the following hailort-driver versions:

  • v4.17.0
  • v4.19.0
  • v4.20.0

I’ve installed them like this:

sudo apt install linux-headers-$(uname -r)
sudo apt install build-essential

git clone https://github.com/hailo-ai/hailort-drivers.git --branch v4.17.0

cd hailort-drivers/linux/pcie
make all
sudo make install
cd ../..
./download_firmware.sh
sudo mkdir -p /lib/firmware/hailo
sudo mv hailo8_fw.4.17.0.bin /lib/firmware/hailo/hailo8_fw.bin
sudo cp ./linux/pcie/51-hailo-udev.rules /etc/udev/rules.d/
sudo udevadm control --reload-rules && sudo udevadm trigger
sudo modprobe hailo_pci
sudo reboot

I also tried to build using this flag without success:

...
cd hailort-drivers/linux/pcie
make all CFLAGS="-DHAILO_RASBERRY_PIE"
sudo make install
...

Description of the issue:

The result is the same: the expected device (a node like /dev/hailo or a folder /dev/hailo*) is not created.

Even though a udev rule (51-hailo-udev.rules) is installed to adjust the permissions for devices under the hailo_chardev subsystem, the driver itself does not create the device node.

When loading the kernel module with sudo modprobe hailo_pci, I get the following messages:

sudo dmesg | grep -i hailo
[  107.632053] hailo_pci: loading out-of-tree module taints kernel.
[  107.632871] hailo: Init module. driver version 4.17.0

It seems that the device is not properly initialized; a lot of the expected initialization information is missing.

Additionally, lsmod shows that the kernel module is loaded but not used (usage count is 0):

lsmod | grep hailo
hailo_pci             110592  0

Expected behaviour would be:

ls /dev/hailo*
/dev/hailo0

sudo dmesg | grep hailo
[    4.980184] hailo_pci: loading out-of-tree module taints kernel.
[    4.980195] hailo_pci: module verification failed: signature and/or required key missing - tainting kernel
[    4.981731] hailo: Init module. driver version 4.17.0
[    4.981844] hailo 0000:01:00.0: Probing on: 1e60:2864...
[    4.981849] hailo 0000:01:00.0: Probing: Allocate memory for device extension, 11600
[    4.981859] hailo 0000:01:00.0: enabling device (0000 -> 0002)
[    4.981865] hailo 0000:01:00.0: Probing: Device enabled
[    4.981880] hailo 0000:01:00.0: Probing: mapped bar 0 - 00000000b70945f0 16384
[    4.981884] hailo 0000:01:00.0: Probing: mapped bar 2 - 00000000d21184c7 4096
[    4.981888] hailo 0000:01:00.0: Probing: mapped bar 4 - 00000000fde02b51 16384
[    4.981893] hailo 0000:01:00.0: Probing: Setting max_desc_page_size to 4096, (page_size=4096)
[    4.981901] hailo 0000:01:00.0: Probing: Enabled 64 bit dma
[    4.981906] hailo 0000:01:00.0: Probing: Using userspace allocated vdma buffers
[    4.981910] hailo 0000:01:00.0: Disabling ASPM L0s 
[    4.981914] hailo 0000:01:00.0: Successfully disabled ASPM L0s 
[    5.030118] UBSAN: array-index-out-of-bounds in /home/jpmeijers/hailort-drivers/linux/pcie/../../common/pcie_common.c:351:53
[    5.030152]  hailo_pcie_write_firmware+0x260/0x280 [hailo_pci]
[    5.030169]  hailo_pcie_probe+0x970/0xd98 [hailo_pci]
[    5.030204]  hailo_pcie_module_init+0x98/0xff8 [hailo_pci]
[    5.161028] hailo 0000:01:00.0: Firmware was loaded successfully
[    5.172591] hailo 0000:01:00.0: Probing: Added board 1e60-2864, /dev/hailo0

I found an information mentioned by omria in in the Hailo forum regarding Linux kernel dependencies for hailort-driver versions ≤ v4.18.0 on Linux Kernel 6.5:

The latest update for Raspberry Pi OS (based on kernel 6.6) states:

stable_20250127: drivers: media: pci: Update Hailo accelerator device driver to v4.20

Now, with Ubuntu Desktop 24.04.01 I can’t downgrade below linux kernel 6.8.0…

According to the changelogs for hailort-driver v4.20.0, there is kernel support for Linux kernel 6.12.0:

HailoRT PCIe Driver for Linux

  • Add support for linux kernel 6.12

This answer from pierrem shows there seems to be work in progress regarding ubuntu 24:

Our team is currently working to support Ubuntu 24. Not only HailoRT, but also the other components of the SW Suite will be available for Ubuntu 24 users in the near future (exact release version to be confirmed).

I wonder why it worked for others on Ubuntu 24.04 and not for me:

As you can see, the situation is a bit diffuse. Therefore, I have a few questions:

Questions:
1.) Does your changelog from hailort-driver v4.20.0 explicitly mean kernel 6.12. or up to kernel 6.12.?

2.) What should I do now?
→ 2.1) Forget Ubuntu 24 and switch to Raspberry Pi OS?
→ 2.2) Wait for your driver support?

3.) Can you please give more information about the actual status regarding Raspberry Pi 5 and Ubuntu 24?

Welcome to the Hailo Community!

Likely yes. I use Raspberry Pi OS and I believe most of my colleagues too. The Raspberry Team is integrating and testing HailoRT into their OS. That makes the whole installation and update process very easy.

Ubuntu 24 support will likely come with the next software release which is still a bit away.

We will be validating Ubuntu 24 on x86 not necessarily on Raspberry Pi. Most Raspberry Pi users use the official OS.

1 Like

Thank you for the clear explanation. However, I hope the Hailo team reconsiders this, as I don’t believe the user base for this use case (trying to get the Hailo8 working with an LTS version of Ubuntu on a Raspberry Pi 5) is small.

I’ve made an image backup of my current setup, hoping I can continue developing on Ubuntu. But I will follow your advice and switch to the Raspberry Pi OS route.

Have a good day.

You can still give it a try when we release Ubuntu 24 support — it will likely work. Like most R&D teams, we have a limit on the combinations of hardware and OS we can run validation on.

1 Like

The first thing, dmesg should show many more lines related to the Hailo device. For me (Ubuntu 24.04. - completely patched + some rebuild RaspberryOS packages):

root@ubuntu-2404-pi:~# dmesg | fgrep hailo
[    5.075415] hailo_pci: loading out-of-tree module taints kernel.
[    5.075430] hailo_pci: module verification failed: signature and/or required key missing - tainting kernel
[    5.076979] hailo: Init module. driver version 4.19.0
[    5.077115] hailo 0000:01:00.0: Probing on: 1e60:2864...
[    5.077122] hailo 0000:01:00.0: Probing: Allocate memory for device extension, 11632
[    5.077133] hailo 0000:01:00.0: enabling device (0000 -> 0002)
[    5.077138] hailo 0000:01:00.0: Probing: Device enabled
[    5.077169] hailo 0000:01:00.0: Probing: mapped bar 0 - 00000000f68c5a81 16384
[    5.077178] hailo 0000:01:00.0: Probing: mapped bar 2 - 00000000a8499935 4096
[    5.077184] hailo 0000:01:00.0: Probing: mapped bar 4 - 00000000c6230a10 16384
[    5.077188] hailo 0000:01:00.0: Probing: Force setting max_desc_page_size to 4096 (recommended value is 4096)
[    5.077203] hailo 0000:01:00.0: Probing: Enabled 64 bit dma
[    5.077209] hailo 0000:01:00.0: Probing: Using userspace allocated vdma buffers
[    5.077216] hailo 0000:01:00.0: Disabling ASPM L0s 
[    5.077219] hailo 0000:01:00.0: Successfully disabled ASPM L0s 
[    5.081610] hailo 0000:01:00.0: Writing file hailo/hailo8_fw.4.19.0.bin
[    5.167761] hailo 0000:01:00.0: File hailo/hailo8_fw.4.19.0.bin written successfully
[    5.167772] hailo 0000:01:00.0: Writing file hailo/hailo8_board_cfg.bin
[    5.167834] Failed to write file hailo/hailo8_board_cfg.bin
[    5.167836] hailo 0000:01:00.0: File hailo/hailo8_board_cfg.bin written successfully
[    5.167839] hailo 0000:01:00.0: Writing file hailo/hailo8_fw_cfg.bin
[    5.167876] Failed to write file hailo/hailo8_fw_cfg.bin
[    5.167878] hailo 0000:01:00.0: File hailo/hailo8_fw_cfg.bin written successfully
[    5.304877] hailo 0000:01:00.0: Firmware loaded successfully
[    5.316914] hailo 0000:01:00.0: Probing: Added board 1e60-2864, /dev/hailo0
root@ubuntu-2404-pi:~# uname -a
Linux ubuntu-2404-pi 6.8.0-1018-raspi #20-Ubuntu SMP PREEMPT_DYNAMIC Fri Jan 17 12:35:36 UTC 2025 aarch64 aarch64 aarch64 GNU/Linux
root@ubuntu-2404-pi:~# dpkg -l | fgrep -i hailo | fgrep ii
ii  hailo-all                                        4.19.0                                   all          Hailo support (metapackage)
ii  hailo-dkms                                       4.19.0-1                                 all          Hailo PCIe driver
ii  hailo-tappas-core                                3.30.0-1                                 arm64        This package contains the core components of the Hailo Tappas platform.
ii  hailofw                                          4.19.0-2                                 all          Hailo firmware
ii  hailort                                          4.19.0-3                                 arm64        HailoRT
ii  python3-hailort                                  4.19.0-2                                 arm64        HailoRT Python API, which wraps the runtime library
ii  rpicam-apps-hailo-postprocess                    1.5.3-1                                  arm64        rpicam-apps-hailo

That setup works ok for the examples with streams and a PiCam v3w;-)

1 Like

Running the basic_pipelines/pose_estimation.py

:wink:

2 Likes