ayufan-rock64 / linux-build

Rock64 Linux build scripts, tools and instructions
MIT License
561 stars 98 forks source link

PXE boot on Rock64 - UDP wrong checksum #341

Open Halytskyi opened 5 years ago

Halytskyi commented 5 years ago

I tried several instructions (also https://forum.pine64.org/showthread.php?tid=6814) for configure boot via PXE on Rock64 - no luck :( Have issue with "UDP wrong checksum":

DDR version 1.13 20180428
ID:0x805 N
In
LPDDR3
786MHz
Bus Width=32 Col=11 Bank=8 Row=15/15 CS=2 Die Bus-Width=32 Size=4096MB
ddrconfig:7
OUT

U-Boot SPL 2017.09-rockchip-ayufan-1035-gd646df03ac (Oct 26 2018 - 08:35:43)
setup_ddr_param  1
booted from SPI flash
Trying to boot from SPI
NOTICE:  BL31: v1.3(debug):9d3f591
NOTICE:  BL31: Built : 14:39:02, Jan 17 2018
NOTICE:  BL31:Rockchip release version: v1.3
INFO:    ARM GICv2 driver initialized
INFO:    Using opteed sec cpu_context!
INFO:    boot cpu mask: 1
INFO:    plat_rockchip_pmu_init: pd status 0xe
INFO:    BL31: Initializing runtime services
WARNING: No OPTEE provided by BL2 boot loader, Booting device without OPTEE initialization. SMC`s destined for OPTEE will return SMC_UNK
ERROR:   Error initializing runtime service opteed_fast
INFO:    BL31: Preparing for EL3 exit to normal world
INFO:    Entry point address = 0x200000
INFO:    SPSR = 0x3c9

U-Boot 2017.09-rockchip-ayufan-1035-gd646df03ac (Oct 26 2018 - 08:36:01 +0000)

Model: Pine64 Rock64
DRAM:  4 GiB
MMC:   rksdmmc@ff520000: 0, rksdmmc@ff500000: 1
SF: Detected gd25q128 with page size 256 Bytes, erase size 4 KiB, total 16 MiB
*** Warning - bad CRC, using default environment

In:    serial@ff130000
Out:   serial@ff130000
Err:   serial@ff130000
Model: Pine64 Rock64
misc_init_r
cpuid=55524b50303930323100000000132807
serial=888ee9b333c974b
Net:   eth0: ethernet@ff540000
Hit any key to stop autoboot:  0
Card did not respond to voltage select!
mmc_init: -95, time 9
Card did not respond to voltage select!
mmc_init: -95, time 9
starting USB...
USB0:   USB EHCI 1.00
USB1:   USB OHCI 1.0
USB2:   Core Release: 3.10a
USB3:   Register 2000140 NbrPorts 2
Starting the controller
USB XHCI 1.10
scanning bus 0 for devices... 1 USB Device(s) found
scanning bus 1 for devices... 1 USB Device(s) found
scanning bus 2 for devices... 1 USB Device(s) found
scanning bus 3 for devices... 1 USB Device(s) found
       scanning usb for storage devices... 0 Storage Device(s) found

Device 0: unknown device
Speed: 1000, full duplex
BOOTP broadcast 1
DHCP client bound to address 192.168.120.101 (2 ms)
*** Warning: no boot file name; using 'C0A87865.img'
Using ethernet@ff540000 device
TFTP from server 192.168.120.5; our IP address is 192.168.120.101
Filename 'C0A87865.img'.
Load address: 0x800800
Loading:
TFTP error: 'File not found' (1)
Not retrying...
missing environment variable: pxeuuid
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/01-22-62-24-29-72-b4
Speed: 1000, full duplex
Using ethernet@ff540000 device
TFTP from server 192.168.120.5; our IP address is 192.168.120.101
Filename 'pxelinux.cfg/01-22-62-24-29-72-b4'.
Load address: 0x600000
Loading: #
         72.3 KiB/s
done
Bytes transferred = 1049 (419 hex)
Config file found
1:      rock64
missing environment variable: bootfile
Retrieving file: boot/initrd.img-4.4.167-1161-rockchip-ayufan-g6f1664023387
Speed: 1000, full duplex
Using ethernet@ff540000 device
TFTP from server 192.168.120.5; our IP address is 192.168.120.101
Filename 'boot/initrd.img-4.4.167-1161-rockchip-ayufan-g6f1664023387'.
Load address: 0x4000000
Loading:  UDP wrong checksum 00000800 000022da
T  UDP wrong checksum 00001008 00003091
 UDP wrong checksum 00001008 000022da
T  UDP wrong checksum 00001008 000022da
 UDP wrong checksum 00001008 00003091
T  UDP wrong checksum 00000800 00003091
 UDP wrong checksum 00000810 000022da
# UDP wrong checksum 00000008 00004c20
 UDP wrong checksum 00000800 00003769
 UDP wrong checksum 00000800 00003091
 UDP wrong checksum 00000800 000022da
 UDP wrong checksum 00000800 00008016

P.S. Tried several SPI images, include the latest "2017.09-rockchip-ayufan-1045-g9922d32c04". The same issue on all of them.

Halytskyi commented 5 years ago

Ok, seems I found the issue... I tried the same method on other 2nd rock64 board and it's WORKS without any issues! on 3rd rock64 board it works but time to time I see messages about "UDP wrong checksum". After I defined on switch (tl-108e) speed 100MF - no issues. I tried define speed to 10 and 100 for "problem board" - no luck :( Also changing ethernet cable didn't solve issue. Seems this is hardware issue with this board :( But it's strange. If board loaded from SD card - no issues with ethernet, everything works well.

Can be this hardware issue or it's some specific of hardware and it's can current issue be solved on software level?

ayufan commented 5 years ago

It is software. There is some problem with u boot

On Thu, 4 Apr 2019 at 08:08, Oleh Halytskyi notifications@github.com wrote:

Ok, seems I found the issue... I tried the same method on other 2nd rock64 board and it's WORKS without any issues! on 3rd rock64 board it works but time to time I see messages about "UDP wrong checksum". After I defined on switch (tl-108e) speed 100MF - no issues. I tried define speed to 10 and 100 for "problem board" - no luck :( Also changing ethernet cable didn't solve issue. Seems this is hardware issue with this board :( But it's strange. If board loaded from SD card - no issues with ethernet, everything works well.

Can be this hardware issue or it's some specific of hardware and it's can current issue be solved on software level?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ayufan-rock64/linux-build/issues/341#issuecomment-479763074, or mute the thread https://github.com/notifications/unsubscribe-auth/ACTpQRCQ4SSS9szFDQDSwDvBkuidiNoNks5vdZbjgaJpZM4cXJho .

Halytskyi commented 5 years ago

It is software. There is some problem with u boot

Is it possible to fix? Thanks.

DenisPolygalov commented 5 years ago

Experiencing same problem with new ROCK64 board.. Tried 3 different TFTP servers, no luck. It is sad to see how boards with such outstanding hardware as Rock64/Rock64Pro are being bated by RPi just due to lack of normal OS/infrastructure...

vercas commented 4 years ago

Encountering this problem as well.

JJTech0130 commented 3 years ago

I am encountering this issue on one brand-new Rock64 board, but not on an identical second. Seems to be tied to the physical board somehow. checksum_error.log It doesn't always happen, but often enough (9/10) to make PXE booting almost impossible. EDIT: Sometimes it doesn't manifest as a checksum error, it also throws errors like this:

Filename '/pxelinux.cfg/01-22-b2-c4-29-75-ef'.
Load address: 0x600000
ARP Retry count exceeded; starting again 

Not completely sure if they are the same issue, but they seem to be at least related. EDIT 2: Possible HW fix: https://forum.pine64.org/showthread.php?tid=7545 ? Not sure why it would only affect certain boards... EDIT 3: Similar to Halytskyi's 3rd board, moving to a 100M switch seemed to fix the issue. Not desirable, because it can't use gigabit speeds, but it does work.