PandABlocks / PandABlocks-server

TCP server exposing an ASCII interface to functional blocks
Apache License 2.0
2 stars 3 forks source link

drive error: "panda: disagrees about version of symbol module_layout" #53

Closed gi4you closed 7 months ago

gi4you commented 7 months ago

I build TCP-server from docker container, but it shows "panda: disagrees about version of symbol module_layout" https://pandablocks.github.io/main/developer/how-to/run-container.html

It means root_fs and device driver versions are mismatched? I did build root_fs and tcp-server in the same environment. How do I fix my issue?

image

EmilioPeJu commented 7 months ago

That's right, you probably need to update rootfs to use a newer kernel, this can be confirmed by running the following commands:

$ strings /opt/share/panda-server/panda.ko | grep vermagic=
vermagic=6.1.0-xilinx SMP preempt mod_unload modversions ARMv7 p2v8

$ uname -r
6.1.0-xilinx

If your checked out repositories seem to match, you might have some stale build files in rootfs and you could try removing the build folder (or maybe just uImage) and building from scratch

gi4you commented 7 months ago

I see, we are using an old kernel version. root@xf31id1-lab3-panda1:/tmp# strings /opt/share/panda-server/panda.ko | grep vermagic= vermagic=5.15.0-xilinx SMP preempt mod_unload modversions ARMv7 p2v8 root@xf31id1-lab3-panda1:/tmp# uname -r 5.15.0-xilinx

How do I update a new kernel from a Docker container? I already pulled the latest PandABlocks-rootfs and built.

EmilioPeJu commented 7 months ago

Could you please let me know of the steps you are following to build it?

gi4you commented 7 months ago

Ok, I rebuild and copied uImage, imagefile.cpio.gz and panda-server@zynq-3.0-7-g2531584.zpg And web server is working with your latest tcp-server.

I did for root-fs: 1) make kernel 2) make boot

for tcp-server: make zpkg

root@xf31id1-lab3-panda1ptp:~# strings /opt/share/panda-server/panda.ko | grep vermagic= vermagic=6.1.0-xilinx SMP preempt mod_unload modversions ARMv7 p2v8 root@xf31id1-lab3-panda1ptp:~# uname -r 6.1.0-xilinx

dmesg

fpga_manager fpga0: writing panda_top.bin to Xilinx Zynq FPGA Manager panda: loading out-of-tree module taints kernel. Loading PandA driver Allocate 32x 2097152 blocks

EmilioPeJu commented 7 months ago

Nice, I'm glad that worked

gi4you commented 7 months ago

Thank you so much! I am still using Vivado 2022.2 for hw-ts FPGA firmware, it okay with the new Linux kernel? Or do we need to update Vivado 2023.2 ?

EmilioPeJu commented 7 months ago

In theory, you'd need to use Vivado 2023.2 to generate a device tree consistent with the linux version, however, in practice, the device tree doesn't change that much between those two versions and it is likely to work just fine.

glennchid commented 7 months ago

In theory, you'd need to use Vivado 2023.2 to generate a device tree consistent with the linux version, however, in practice, the device tree doesn't change that much between those two versions and it is likely to work just fine.

Yes, just to add that we tested in the lab with 2022.2, as the 2023.2 is not merged yet, and it worked fine.

gi4you commented 7 months ago

Thank you! solved issues and closed it.