Closed jmonfer closed 5 years ago
Thanks for testing the debian.sh script. I've just tried to reproduce the problem with unmodified version of my scripts. The script runs without any error and the resulting image boots without kernel panic.
I've just uploaded the updated SD card image to dropbox and updated the link in the LED blinker notes.
Here is a direct link to the updated SD card image:
Thank you Pavel for your efforts and help. This morning I’ve tried your last img file and works perfect. Then, I’ve been trying to follow again all the process using your original files from github. My new generated .img file is still not working. If I compare the boot using your image and my generated one, everything works equally until Starting init process (until "Freeing unused kernel memory: 1024K" ).
I want to generate my own .img file because, if it works, I will generate a new img file with modifications in the device tree.
My intention is to modify your devicetree.patch file line 92 where memory is reserved to “reg=<0x0 0x10000000>”. This is to leave the last DDR3 256Mbytes to be shared with the programmable logic through hp0 and hp1 ports using DMA blocks. At the moment, my problem is generating your img file with your original files. I attach my console output when I run your script: sudo sh scripts/image.sh scripts/debian.sh red-pitaya-debian-9.9-armhf.img 1024
But, sincerely, I don’t know if the problem is there or in the step before (make NAME=led_blinker all). If you have any idea where the problem could be, it will be very helpful to continue searching for a solution. Thank you again
Thanks for the log file. The following error message doesn't look good:
W: Failure while installing base packages. This will be re-attempted up to five times.
W: See //debootstrap/debootstrap.log for details (possibly the package /var/cache/apt/archives/init_1.48_armhf.deb is at fault)
Looks like the init_1.48_armhf.deb
can't be installed. That's why the Linux kernel can't start the init process and panics.
I've just checked the version of the debootstrap package installed on my Debian 8 machine. Looks like I had to install a more up-to-date version from the jessie-backports repository. I think that it can be done with the following commands:
wget http://archive.debian.org/debian/pool/main/d/debootstrap/debootstrap_1.0.89~bpo8+1_all.deb
dpkg -i debootstrap_1.0.89~bpo8+1_all.deb
My intention is to modify your devicetree.patch file line 92 where memory is reserved to “reg=<0x0 0x10000000>”. This is to leave the last DDR3 256Mbytes to be shared with the programmable logic through hp0 and hp1 ports using DMA blocks.
I think that zynq-red-pitaya.dts should also be modified. This file is used by u-boot. So, it should be modified before building u-boot.
It's also possible to just rebuild devicetree.dtb
and boot.bin
and copy them to a pre-built SD card image. The commands to rebuild devicetree.dtb
, u-boot and boot.bin
are
rm -rf devicetree.dtb tmp/led_blinker.tree
make devicetree.dtb
rm -rf boot.bin tmp/u-boot.elf tmp/u-boot-xlnx-xilinx-v2018.3
make boot.bin
Now everything is working. .img file is generated perfectly, and redpitaya linux boots without any problems.
Also, I’ve generated the device tree and u-boot performing the modifications as you recommend me. Everything worked as expected, the logic has written 256Mbytes on DDR3 of known values using a simple verilog designed module and the linux appears to read the values without any problem.
Thank you again for your advice. It has been very helpful
Hi Pavel, I want to thank you for your great work, it is very useful. In this moment, I’m trying to generate the SD card debian image following the steps that you indicate at led-blinker project web page: 1- make NAME=led_blinker all 2- sudo sh scripts/image.sh scripts/debian.sh red-pitaya-debian-8.11-armhf.img 1024 3- I copy the img file to windows os. Then, using Win32 Disk Imager the SD card is generated.
The Linux virtual machine that I’m using has been created following your instructions.
A minor modification has been done in the Makefile. The line 48 “LINUX_TAR = tmp/linux-$(LINUX_TAG).tar.xz” now is “LINUX_TAR = tmp/linux-$(LINUX_TAG).tar.gz “. Also, in debian.sh file, at several apt-get command calls, the “—allow-unauthenticated” attribute has been added. My last file modification is in debian.sh line 183 where I put my redpitaya fixed eth0 IP address.
When I start the system, the serial console it’s working but the system suffers a kernel panic. I have no experience with operating systems and for these reason I’m not capable of detecting my problem. Your advice regarding this problem will very helpful.
Thank you.
The last serial console lines are: