I created a DFX project with one reconfigure partition, which include only one IP using axi interface. I successfully generate the bistream and I put it on my KV260 board along with the partial bitstream and hwh file. But after I download the partial bitstream, I cannot use the IP even though I can see different IP names. The error says:
---------------------------------------------------------------------------
PermissionError Traceback (most recent call last)
Input In [7], in <cell line: 2>()
1 # help(ol.rp_0)
----> 2 rp = ol.rp_0.sub_0
File /usr/local/share/pynq-venv/lib/python3.10/site-packages/pynq/overlay.py:904, in _IPMap.__getattr__(self, key)
902 ipdescription = self._description["ip"][key]
903 try:
--> 904 driver = ipdescription["driver"](ipdescription)
905 except UnsupportedConfiguration as e:
906 warnings.warn(
907 "Configuration if IP {} not supported: {}".format(key, str(e.args)),
908 UserWarning,
909 )
File /usr/local/share/pynq-venv/lib/python3.10/site-packages/pynq/overlay.py:694, in DefaultIP.__init__(self, description)
691 from .pl_server.device import Device
693 self.device = Device.active_device
--> 694 self.mmio = MMIO(
695 description["phys_addr"], description["addr_range"], device=self.device
696 )
697 if "interrupts" in description:
698 self._interrupts = description["interrupts"]
File /usr/local/share/pynq-venv/lib/python3.10/site-packages/pynq/mmio.py:73, in MMIO.__init__(self, base_addr, length, device, **kwargs)
71 self.read = self.read
72 self.write = self.write_mm
---> 73 self.array = self.device.mmap(base_addr, length)
74 elif self.device.has_capability("REGISTER_RW"):
75 self.read = self.read
File /usr/local/share/pynq-venv/lib/python3.10/site-packages/pynq/pl_server/embedded_device.py:591, in EmbeddedDevice.mmap(self, base_addr, length)
589 # Open file and mmap
590 mmap_file = os.open("/dev/mem", os.O_RDWR | os.O_SYNC)
--> 591 mem = mmap.mmap(
592 mmap_file,
593 length + virt_offset,
594 mmap.MAP_SHARED,
595 mmap.PROT_READ | mmap.PROT_WRITE,
596 offset=virt_base,
597 )
598 os.close(mmap_file)
599 array = np.frombuffer(mem, np.uint32, length >> 2, virt_offset)
PermissionError: [Errno 1] Operation not permitted
Here is the block design of my project:
And how I download the bitstream (sorry I cannot provide another screenshot because I’m a new user):
import numpy as np
import time
from pynq import PL, allocate, Overlay
PL.reset()
ol = Overlay("test.xsa")
# download partial for hierarchy rp_0
ol.rp_0.download('add.bit')
# after both download, if I check rp_0 I see different IP blocks in it
ol.rp_0.download('sub.bit')
# but when I try to use the ip inside of rp_0 I got the error above
ip = ol.rp_0.sub_0
I didn’t find any similar problem over the Internet. Besides, since pynq is installed for root user, there shouldn’t be any permission issue, right? I tried use sudo
to execute python script but I got the same error.
I’m using PYNQ-3.0.1 on Ubuntu 22.04. Any help is appreciated!