openhwgroup / cva6-sdk

CVA6 SDK containing RISC-V tools and Buildroot
59 stars 64 forks source link

devmem cann't write into all physical address of a new peripheral #63

Open monireee opened 2 years ago

monireee commented 2 years ago

I tried to write data to the physical address of the already available peripheral, Timer (base address 0x18000000), and newly added peripheral (base address 0x60000000). The read data after writing at several physical addresses for these peripherals are shared in screenshots. For Timer: Data written into an address is read at another address as you see in the screenshot.

image

For new peripheral: Data can be written with the offset of multiple of 8, 0x60000000, 0x60000008, 0x60000010, 0x60000018. But after that, data reads as zero for the rest of the addresses.

image

Can anybody explain this data pattern that I read after writing? Again, would you please suggest how can I write into all physical addresses while OS is running? Thanks in advance.

wal222 commented 1 month ago

Hi, I also wanna add a peripheral to the core. Could you tell how exactly you did it? I would highly appreciate it.