Following the guide from https://rocketboards.org/foswiki/view/Documentation/EmbeddedLinuxBeginnerSGuide , I have managed to load fpga rbf and blink leds using user-space program in chapter 11. Custom kernel driver in chapter 12 is also working.
It took a couple of days, as I had to fix hps_common_board_info.xml and soc_system.sopcinfo. New device-tree is compatible with kernel 4.6.5. I also fixed the annoying lag jitter by setting ethenet ex delays to values from kernel dts subsystem. You can find all files in Project files -> soc_system_tree.zip. Included you may find the final soc_system.dts, that you may convert to dtb and use directly.
With new device-tree overlays, development process is very simplified. Loading soc_system.rbf and/or adding new devices to device-tree is quite simple:
/* Example device-tree overlay. Load soc_system.rbf from /lib/firmware */ /dts-v1/; / { fragment@0 { target-path = "/sopc@0/base_fpga_region@0xff200000"; #address-cells = <2>; #size-cells = <1>; __overlay__ { #address-cells = <2>; #size-cells = <1>; firmware-name = "soc_system.rbf"; }; }; };
mkdir -p /config && mount -t configfs configfs /config && mkdir /config/device-tree/overlays/foo
dtc -I dts -O dtb -o test.dtbo overlay.dts
cat test.dtbo > /config/device-tree/overlays/foo/dtbo
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.