How to enable Opencl support on hikey960?


#64

Thanks. but If you would like update your debian image someday, could you please add V4L/V4L2 support? thx.


#65

You are aware you can simply download the kernel from https://github.com/TallGuy74/linux.git (branch daedalean) and compile the support for that into your kernel right?

  1. git clone https://github.com/TallGuy74/linux.git
  2. cd linux
  3. git checkout daedalean
  4. apt install build-essential gcc-aarch64-linux-gnu
  5. make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu daedalean_defconfig
  6. make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- menuconfig
  7. Enable V4L and whatever other option you want enabled.
  8. make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- Image modules
  9. mkdir -p /tmp/tmp_install/boot
  10. make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_MOD_PATH=/tmp/tmp_install INSTALL_MOD_STRIP=1 modules_install
  11. cp arch/arm64/boot/Image /tmp/tmp_install/boot/Image-
  12. Transfer everything from /tmp/tmp_install to the hikey960 and modify /boot/grub/grub.cfg or similar to boot the new kernel.

And you are running your very own kernel on the hikey960.


#66

So it seems that the problem for me is somehow related to the clinfo version in the debian-repositories. If i build clinfo from source i get some valid output. But there are still some errors if i try to run a opencl application. Maybe it is necessary to install the ARM computelibrary


#67

Thank you bvermeul, it is working


#68

Can you share pre compiled image for debian?


#69

The pre-compiled kernel is on the debian image in /boot.


#70

Thanks, can you provide related link?


#71

It’s a little higher up in this thread.


#72

I just flashed the http://blackstar.xs4all.nl/debian-hikey960-public.rootfs.img.gz. However, I cannot login with “linaro”.
What is the login & pass ?


#73

Please read the thread completely. All of the questions you’ve had up till now were in my responses to it.
In this case, user root, no password.


#74

thanks, I cannot see wlan0 with http://blackstar.xs4all.nl/debian-hikey960-public.rootfs.img.gz.
but I can access to /etc/wpa_supplicant/wpa_supplicant-wlan0.conf
how to fix wifi problem?


#75

Go through dmesg and check why the wifi driver isn’t loading. Fix any problems you find there (you can use google for many problems and get decent results at finding a solution).


#76

@bvermeul do you have any prebuilt image for Hikey970?


#77

What are you trying to do on Hikey970?


#78

@nish I am trying to run a deep learning model on HiKey970, so I was wondering if a pre-built image with opencl support available?


#79

Hi, please let me know what AI library you are using for DL. We have an image with tensorflow pre-built in it. We are still trying to make OpenCL work. But if you just want to run inference on your model, I think having GPU support (which is why OpenCL is needed) won’t matter. GPU only makes a difference while training a model.


#80

Hi, I am using ssd mobilenet model in tensorflow. Yes i want to run inference on the model. It would be great if you could share your image or steps to produce the image or github details.

GPU only makes a difference while training a model.
Yes GPU definitely makes difference while training. However many time it helps in generating inference in real time.

Thanks a lot for quick response.


#81

@allanmac How to point ICD at libOpenCL.so, could you please explain?


#82

@jainrahul1
Using the command:

echo “path to libmali.so” > /etc/OpenCL/vendors/mali.icd

will do this. Please make sure that /dev/mali* is owned by a group you are a part of, or to use any OpenCL programs as root or with sudo.


#83

@nish could you please provide image for pre-built library?