KV260 PYNQ Failed to open /dev/xlnk

Hello, I am working on the KV260 development board. I have installed the Ubuntu 22.04 LTS image according to the tutorial and also installed PYNQ.

Currently, I am deploying an LLM model on the KV260. I have already written an acceleration core on the PL side to speed up matrix calculations and connected it to the PS through AXI. I am sure that the simulation in Vivado is fine. The block design is as follows.

The model inference part is implemented in C. I have set up the project according to the pynq_api tutorial and can load the bit file. However, when running, I get an error: Failed to open /dev/xlnk. I also did not find the xlnk file or folder in the dev directory. How can I solve this problem?

Hi @xenbabala,

Welcome to the PYNQ community.

according to the pynq_api tutorial and can load the bit file.

I am not sure what tutorial you are referring to.

It has been a few versions since we do not use xlnk for memory allocation. xrt is used for memory allocation

Mario

Thank you very much for your reply. I have also noticed that the API I am using is outdated. This is the link to the API: GitHub - mesham/pynq_api: C API drivers for PYNQ FPGA board. This API uses xlnk for memory allocation, but as you said, it is already outdated.

However, the LLM that I am currently trying to run has its entire inference process implemented in C. I want to run it on the PYNQ (KV26), so I need some C APIs to interact with some IP cores in the PL using C. I don’t know if you have any recommended methods.

Hi @xenbabala,

If you search for CYNQ, you’ll find some 3rd party work that has some C APIs.

Mario

Thank you for your reply. I will give it a try.