Hi all, I have finally figured out why it was not working. I compared the beagleboard linux kernel with the kernel mainline. This led to the pruss_soc_bus module. When this module is loaded I could read and otherwise it would fail.
By looking at the code I figured out that in my case the PRUSS reset was never deasserted. So I had to set RM_PER_RSTCTRL defined in section 8.1.13.2.1 of the AM335x technical reference manual. (The correct clock also wasn't enabled, but that could have been my undoing.) The solution confirms that I am still a newbie at this. I post the solution anyway as it might help someone else in the future. Best wishes, Hugo I did not deassert the reset line. RM_PER_RSTCTRL On Monday 30 December 2019 15:29:27 UTC+1 Hugo van den Brand wrote: > > > Dear all, > > To make a system with a minimal footprint, I am compiling my own kernel > for the BeagleBone black. > With this kernel I am trying to use the PRU using the uio-pruss (which > memory maps the PRU memory and offers interrupts to userspace). > > However, I cannot access the PRU memory. > I tried to use devmem (part of busybox) to read the address to which the > PRU is mapped and I get back: > > # devmem 0x4a300000 > [ 568.572896] Unhandled fault: external abort on non-linefetch (0x1018) > at 0xb6fd5000 > [ 568.580634] pgd = 17e21f9e > [ 568.583361] [b6fd5000] *pgd=9d4e4831, *pte=4a300183, *ppte=4a300a32 > Bus error > > > What I found for this type of error is that it could be caused by not > having the right clocks enabled > (*https://forums.xilinx.com/t5/Embedded-Linux/Unhandled-fault-external-abort-on-non-linefetch-0x1018-at/td-p/904286 > > <https://forums.xilinx.com/t5/Embedded-Linux/Unhandled-fault-external-abort-on-non-linefetch-0x1018-at/td-p/904286>* > ) > > When I boot with the default ubuntu image for the BeagleBone Black > (4.14.108-ti-r113), I am able to read the PRU memory. > > Therefore, I compared all clocks on the default ubuntu and adapted > uio_pruss to enable all these clocks. > This did not solve the issue. > > Anybody has some suggestions on what might be different between a > linux-4.14.108 kernel and dtb and the default ubuntu image? > > Best wishes, > Hugo > -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/e1efbe36-6c87-43b5-8fb7-31608b8afaab%40googlegroups.com.