GTI Mirabox, Netgear RN102/RN104, Netgear RN2120 Installation & Kernel Upgrade (Linux-6.9.6) November 06, 2019 11:47PM |
Admin Registered: 13 years ago Posts: 18,821 |
md5: 54b4a446cc4566f17e676729d0a4d052 sha256: 62e0ea0acce79d8710447ab4a36f003c1616a8000231454bfbcacf99c4e1f0bb
linux-image-6.9.6-mvebu-370xp-tld-2_2_armhf.deb linux-headers-6.9.6-mvebu-370xp-tld-2_2_armhf.deb zImage-6.9.6-mvebu-370xp-tld-2 config-6.9.6-mvebu-370xp-tld-2 linux-dtb-6.9.6-mvebu-370xp-tld-2.tar linux-6.9.6-mvebu-370xp-tld-1.patch clocksource.c.patch
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx
cd /boot tar xjf linux-6.9.6-mvebu-370xp-tld-2-bodhi.tar.bz2 tar xf linux-dtb-6.9.6-mvebu-370xp-tld-2.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-6.9.6-mvebu-370xp-tld-2_2_armhf.deb
cd /boot
cp -a uImage uImage.bak
cp -a uInitrd uInitrd.bak
cp -a zImage-6.9.6-mvebu-370xp-tld-2 zImage.fdt
cat dts/armada-370-mirabox.dtb >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-6.9.6-mvebu-370xp-tld-2 -d zImage.fdt uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-6.9.6-mvebu-370xp-tld-2 -d initrd.img-6.9.6-mvebu-370xp-tld-2 uInitrd
sync sync sync shutdown -r now
md5: 90f3bd69c161d37a6f0b4c7101243dc9 sha256: 6e8260a520de68c29e7bb7553b4284a643c70b21d37d5f73a99815f8a421f6c1
linux-image-6.9.6-mvebu-370xp-tld-1_1_armhf.deb linux-headers-6.9.6-mvebu-370xp-tld-1_1_armhf.deb zImage-6.9.6-mvebu-370xp-tld-1 config-6.9.6-mvebu-370xp-tld-1 linux-dtb-6.9.6-mvebu-370xp-tld-1.tar linux-6.9.6-mvebu-370xp-tld-1.patch
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx
cd /boot tar xjf linux-6.9.6-mvebu-370xp-tld-1-bodhi.tar.bz2 tar xf linux-dtb-6.9.6-mvebu-370xp-tld-1.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-6.9.6-mvebu-370xp-tld-1_1_armhf.deb
cd /boot
cp -a uImage uImage.bak
cp -a uInitrd uInitrd.bak
cp -a zImage-6.9.6-mvebu-370xp-tld-1 zImage.fdt
cat dts/armada-370-mirabox.dtb >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-6.9.6-mvebu-370xp-tld-1 -d zImage.fdt uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-6.9.6-mvebu-370xp-tld-1 -d initrd.img-6.9.6-mvebu-370xp-tld-1 uInitrd
sync sync sync shutdown -r now
md5: 6bfbd10df607d998bc70ee10bf23ad52 sha256: c2528b2ae162bb77fb003a6ea76c27d847f586c7d29adba1c1e2ebf734428336
linux-image-6.8.7-mvebu-370xp-tld-1_1_armhf.deb linux-headers-6.8.7-mvebu-370xp-tld-1_1_armhf.deb zImage-6.8.7-mvebu-370xp-tld-1 config-6.8.7-mvebu-370xp-tld-1 linux-dtb-6.8.7-mvebu-370xp-tld-1.tar linux-6.8.7-mvebu-370xp-tld-1.patch
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx
cd /boot tar xjf linux-6.8.7-mvebu-370xp-tld-1-bodhi.tar.bz2 tar xf linux-dtb-6.8.7-mvebu-370xp-tld-1.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-6.8.7-mvebu-370xp-tld-1_1_armhf.deb
cd /boot
cp -a uImage uImage.bak
cp -a uInitrd uInitrd.bak
cp -a zImage-6.8.7-mvebu-370xp-tld-1 zImage.fdt
cat dts/armada-370-mirabox.dtb >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-6.8.7-mvebu-370xp-tld-1 -d zImage.fdt uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-6.8.7-mvebu-370xp-tld-1 -d initrd.img-6.8.7-mvebu-370xp-tld-1 uInitrd
sync sync sync shutdown -r now
md5: a44771dd7d586d2171d9c68aeb19e96e sha256: d9e82ba31cf2ddc123aa882bee0dd4c4c05ab5095eccc7546c6c8d33fb9f100c
linux-image-6.7.5-mvebu-370xp-tld-3_3_armhf.deb linux-headers-6.7.5-mvebu-370xp-tld-3_3_armhf.deb zImage-6.7.5-mvebu-370xp-tld-3 config-6.7.5-mvebu-370xp-tld-3 linux-dtb-6.7.5-mvebu-370xp-tld-3.tar
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx
cd /boot tar -xjf linux-6.7.5-mvebu-370xp-tld-3-bodhi.tar.bz2 tar -xf linux-dtb-6.7.5-mvebu-370xp-tld-3.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-6.7.5-mvebu-370xp-tld-3_3_armhf.deb
cd /boot
cp -a uImage uImage.bak
cp -a uInitrd uInitrd.bak
cp -a zImage-6.7.5-mvebu-370xp-tld-3 zImage.fdt
cat dts/armada-370-mirabox.dtb >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-6.7.5-mvebu-370xp-tld-3 -d zImage.fdt uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-6.7.5-mvebu-370xp-tld-3 -d initrd.img-6.7.5-mvebu-370xp-tld-3 uInitrd
sync sync sync shutdown -r now
md5: b0f7e62f67c7b198eae0d8e025a54263 sha256sum: bd478c47e16c201ed2e28c64eab33d7552964170b6d58134549244c38ab810c7
linux-image-6.5.7-mvebu-370xp-tld-1_1_armhf.deb linux-headers-6.5.7-mvebu-370xp-tld-1_1_armhf.deb zImage-6.5.7-mvebu-370xp-tld-1 config-6.5.7-mvebu-370xp-tld-1 linux-dtb-6.5.7-mvebu-370xp-tld-1.tar linux-6.5.7-mvebu-370xp-tld-1.patchAnd as always, please verify the hash of what you've downloaded!
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx
cd /boot tar -xjf linux-6.5.7-mvebu-370xp-tld-1-bodhi.tar.bz2 tar -xf linux-dtb-6.5.7-mvebu-370xp-tld-1.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-6.5.7-mvebu-370xp-tld-1_1_armhf.deb
cd /boot
cp -a uImage uImage.bak
cp -a uInitrd uInitrd.bak
cp -a zImage-6.5.7-mvebu-370xp-tld-1 zImage.fdt
cat dts/armada-370-mirabox.dtb >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-6.5.7-mvebu-370xp-tld-1 -d zImage.fdt uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-6.5.7-mvebu-370xp-tld-1 -d initrd.img-6.5.7-mvebu-370xp-tld-1 uInitrd
sync sync sync shutdown -r now
md5: 0534ba34d6eb25a28a2b62b5987ec810 sha256sum: 550508ad5de1825e54e43f880ecd62c502e621a8c54b9749ec037944339c8ca9
linux-image-6.4.11-mvebu-370xp-tld-1_1_armhf.deb linux-headers-6.4.11-mvebu-370xp-tld-1_1_armhf.deb zImage-6.4.11-mvebu-370xp-tld-1 config-6.4.11-mvebu-370xp-tld-1 linux-dtb-6.4.11-mvebu-370xp-tld-1.tar linux-6.4.11-mvebu-370xp-tld-1.patchAnd as always, please verify the hash of what you've downloaded!
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx
cd /boot tar -xjf linux-6.4.11-mvebu-370xp-tld-1-bodhi.tar.bz2 tar -xf linux-dtb-6.4.11-mvebu-370xp-tld-1.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-6.4.11-mvebu-370xp-tld-1_1_armhf.deb
cd /boot
cp -a uImage uImage.bak
cp -a uInitrd uInitrd.bak
cp -a zImage-6.4.11-mvebu-370xp-tld-1 zImage.fdt
cat dts/armada-370-mirabox.dtb >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-6.4.11-mvebu-370xp-tld-1 -d zImage.fdt uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-6.4.11-mvebu-370xp-tld-1 -d initrd.img-6.4.11-mvebu-370xp-tld-1 uInitrd
sync sync sync shutdown -r now
Quote
linux-image-6.1.8-mvebu-370xp-tld-1_1.0_armhf.deb
linux-headers-6.1.8-mvebu-370xp-tld-1_1.0_armhf.deb
zImage-6.1.8-mvebu-370xp-tld-1
config-6.1.8-mvebu-370xp-tld-1
linux-dtb-6.1.8-mvebu-370xp-tld-1.tar
linux-6.1.8-mvebu-370xp-tld-1.patch
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx dts/
cd /boot tar -xjf linux-6.1.8-mvebu-370xp-tld-1-bodhi.tar.bz2 tar -xf linux-dtb-6.1.8-mvebu-370xp-tld-1.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-6.1.8-mvebu-370xp-tld-1_1.0_armhf.deb
cd /boot
cp -a uImage uImage.bak
cp -a uInitrd uInitrd.bak
cp -a zImage-6.1.8-mvebu-370xp-tld-1 zImage.fdt
cat dts/armada-370-mirabox.dtb >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-6.1.8-mvebu-370xp-tld-1 -d zImage.fdt uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-6.1.8-mvebu-370xp-tld-1 -d initrd.img-6.1.8-mvebu-370xp-tld-1 uInitrd
sync sync sync shutdown -r now
Quote
linux-image-5.19.2-mvebu-370xp-tld-1_1.0_armhf.deb
linux-headers-5.19.2-mvebu-370xp-tld-1_1.0_armhf.deb
zImage-5.19.2-mvebu-370xp-tld-1
config-5.19.2-mvebu-370xp-tld-1
linux-dtb-5.19.2-mvebu-370xp-tld-1.tar
linux-5.19.2-mvebu-370xp-tld-1.patch
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx dts/
cd /boot tar -xjf linux-5.19.2-mvebu-370xp-tld-1-bodhi.tar.bz2 tar -xf linux-dtb-5.19.2-mvebu-370xp-tld-1.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-5.19.2-mvebu-370xp-tld-1_1.0_armhf.deb
cd /boot
cp -a uImage uImage.bak
cp -a uInitrd uInitrd.bak
cp -a zImage-5.19.2-mvebu-370xp-tld-1 zImage.fdt
cat dts/armada-370-mirabox.dtb >> zImage.fdt
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-5.19.2-mvebu-370xp-tld-1 -d zImage.fdt uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-5.19.2-mvebu-370xp-tld-1 -d initrd.img-5.19.2-mvebu-370xp-tld-1 uInitrd
sync sync sync shutdown -r now
Quote
linux-image-5.10.7-mvebu-370xp-tld-1_1.0_armhf.deb
linux-headers-5.10.7-mvebu-370xp-tld-1_1.0_armhf.deb
zImage-5.10.7-mvebu-370xp-tld-1
config-5.10.7-mvebu-370xp-tld-1
linux-dtb-5.10.7-mvebu-370xp-tld-1.tar
linux-5.10.7-mvebu-370xp-tld-1.patch
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx dts/
cd /boot tar -xjf linux-5.10.7-mvebu-370xp-tld-1-bodhi.tar.bz2 tar -xf linux-dtb-5.10.7-mvebu-370xp-tld-1.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-5.10.7-mvebu-370xp-tld-1_1.0_armhf.deb
cd /boot cp -a uImage uImage.bak cp -a uInitrd uInitrd.bak cp -a zImage-5.10.7-mvebu-370xp-tld-1 zImage.fdt cat dts/armada-370-mirabox.dtb >> zImage.fdt mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-5.10.7-mvebu-370xp-tld-1 -d zImage.fdt uImage mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-5.10.7-mvebu-370xp-tld-1 -d initrd.img-5.10.7-mvebu-370xp-tld-1 uInitrd
sync sync sync shutdown -r now
Quote
linux-image-5.9.3-mvebu-370xp-tld-1_1.0_armhf.deb
linux-headers-5.9.3-mvebu-370xp-tld-1_1.0_armhf.deb
zImage-5.9.3-mvebu-370xp-tld-1
config-5.9.3-mvebu-370xp-tld-1
linux-dtb-5.9.3-mvebu-370xp-tld-1.tar
linux-5.9.3-mvebu-370xp-tld-1.patch
mmu.c.patch
uInitrd uImage zImage-xx.xx.xx-mvebu-370xp-xxx initrd.img-xx.xx.xx-mvebu-370xp-xxx System.map-xx.xx.xx-mvebu-370xp-xxx vmlinuz-xx.xx.xx-mvebu-370xp-xxx config-xx.xx.xx-mvebu-370xp-xxx dts/
cd /boot tar -xjf linux-5.9.3-mvebu-370xp-tld-1-bodhi.tar.bz2 tar -xf linux-dtb-5.9.3-mvebu-370xp-tld-1.tar
cd /boot apt-get remove flash-kernel dpkg -i linux-image-5.9.3-mvebu-370xp-tld-1_1.0_armhf.deb
cd /boot cp -a uImage uImage.bak cp -a uInitrd uInitrd.bak cp -a zImage-5.9.3-mvebu-370xp-tld-1 zImage.fdt cat dts/armada-370-mirabox.dtb >> zImage.fdt mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-5.9.3-mvebu-370xp-tld-1 -d zImage.fdt uImage mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-5.9.3-mvebu-370xp-tld-1 -d initrd.img-5.9.3-mvebu-370xp-tld-1 uInitrd
sync sync sync shutdown -r now
Quote
linux-image-5.8.5-mvebu-370xp-tld-1_1.0_armhf.deb
linux-headers-5.8.5-mvebu-370xp-tld-1_1.0_armhf.deb
zImage-5.8.5-mvebu-370xp-tld-1
config-5.8.5-mvebu-370xp-tld-1
linux-dtb-5.8.5-mvebu-370xp-tld-1.tar
linux-5.8.5-mvebu-370xp-tld-1.patch
mkdir -p /media/sdd1/usr/src/kernel cd /media/sdd1/usr/src/kernelCopy the downloaded linux-5.8.5-mvebu-370xp-tld-1-bodhi.tar.bz2 to the current folder (/media/sdd1/usr/src/kernel).
tar xf linux-5.8.5-mvebu-370xp-tld-1-bodhi.tar.bz2
cd /media/sdd1/usr/src/kernel tar -xvf linux-dtb-5.8.5-mvebu-370xp-tld-1.tar dts/armada-370-mirabox.dtb cp -a zImage-5.8.5-mvebu-370xp-tld-1 zImage.fdt cat dts/armada-370-mirabox.dtb >> zImage.fdt mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-5.8.5-mvebu-370xp-tld-1 -d zImage.fdt uImage
cd /media/sdd1/boot cp -a /media/sdd1/usr/src/kernel/uImage . sync sync syncUmount and remove the SD rootfs.
printenvCopy and paste the list of the envs from above command in a notepad. And then,
setenv set_bootargs_stock 'setenv bootargs "console=ttyS0,115200 $mtdparts ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs"' setenv bootcmd_stock 'echo Booting Stock...; nand read 0x6400000 0x400000 0x400000; run set_bootargs_stock; bootm 0x6400000' setenv load_image_addr 0x6400000 setenv load_initrd_addr 0x8400000 setenv load_uImage 'ext2load usb 1:1 $load_image_addr /boot/uImage' setenv load_uInitrd 'ext2load usb 1:1 $load_initrd_addr /boot/uInitrd' setenv set_bootargs_debian 'setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 mtdparts=pxa3xx_nand-0:4M(u-boot),4M(linux),-(filesystem) earlyprintk=serial' setenv bootcmd_debian 'echo Booting Debian... ; usb start; run load_uImage; run load_uInitrd; run set_bootargs_debian; bootm $load_image_addr $load_initrd_addr' setenv bootcmd 'run bootcmd_debian; run bootcmd_stock'
boot
ping debian.local
uname -aExpect Output:
Linux version 5.8.5-mvebu-370xp-tld-1 (root@tldDebianVM) (arm-linux-gnueabihf-gcc (Ubuntu/Linaro 7.5.0-3ubuntu1~18.04) 7.5.0, GNU ld (GNU Binutils for Ubuntu) 2.30) #1.0 SMP PREEMPT Mon Aug 31 00:00:32 PDT 2020
cd /boot cp -a uImage uImage.mirabox.bak cp -a uInitrd uInitrd.bak dpkg -i /usr/src/kernel/linux-image-5.8.5-mvebu-370xp-tld-1_1.0_armhf.deb tar xf /usr/src/kernel/linux-dtb-5.8.5-mvebu-370xp-tld-1.tar cp -a /usr/src/kernel/zImage-5.8.5-mvebu-370xp-tld-1 . cp -a zImage-5.8.5-mvebu-370xp-tld-1 zImage.fdt cat dts/armada-370-mirabox.dtb >> zImage.fdt mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-5.8.5-mvebu-370xp-tld-1 -d zImage.fdt uImage mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-5.8.5-mvebu-370xp-tld-1 -d initrd.img-5.8.5-mvebu-370xp-tld-1 uInitrd
cat /proc/mtdExpected Output:
dev: size erasesize name mtd0: 00400000 00080000 "u-boot" mtd1: 00400000 00080000 "linux" mtd2: 3f800000 00080000 "filesystem"
echo "/dev/mtd0 0x100000 0x00080000 0x00080000" > /etc/fw_env.config
fw_setenv test_xxxx yes fw_printenv test_xxxx fw_printenvExpected Output: If you can list the envs and they look like the envs listed in Step B.1 (with the additional test_xxxx env just set), then it's all checked out. If there is any error at this point then please stop and post question.
fw_setenv set_bootargs_stock 'setenv bootargs "console=ttyS0,115200 $mtdparts ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs"' fw_setenv bootcmd_stock 'echo Booting Stock...; nand read 0x6400000 0x400000 0x400000; run set_bootargs_stock; bootm 0x6400000' fw_setenv load_image_addr 0x6400000 fw_setenv load_initrd_addr 0x8400000 fw_setenv load_uImage 'ext2load usb 1:1 $load_image_addr /boot/uImage' fw_setenv load_uInitrd 'ext2load usb 1:1 $load_initrd_addr /boot/uInitrd' fw_setenv set_bootargs_debian 'setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 mtdparts=pxa3xx_nand-0:4M(u-boot),4M(linux),-(filesystem) earlyprintk=serial' fw_setenv bootcmd_debian 'echo Booting Debian... ; usb start; run load_uImage; run load_uInitrd; run set_bootargs_debian; bootm $load_image_addr $load_initrd_addr' fw_setenv bootcmd 'run bootcmd_debian; run bootcmd_stock'
fw_printenvCopy and paster the envs to a notepad, for safe keeing.
sync sync sync shutdown -r now
mkdir -p /media/sdd1/usr/src/kernel cd /media/sdd1/usr/src/kernelCopy the downloaded linux-5.8.5-mvebu-370xp-tld-1-bodhi.tar.bz2 to the current folder (/media/sdd1/usr/src/kernel).
tar xf linux-5.8.5-mvebu-370xp-tld-1-bodhi.tar.bz2
cd /media/sdd1/usr/src/kernel tar -xvf linux-dtb-5.8.5-mvebu-370xp-tld-1.tar dts/armada-370-netgear-rn102.dtb cp -a zImage-5.8.5-mvebu-370xp-tld-1 zImage.fdt cat dts/armada-370-netgear-rn102.dtb >> zImage.fdt mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-5.8.5-mvebu-370xp-tld-1 -d zImage.fdt uImage
cd /media/sdd1/boot cp -a /media/sdd1/usr/src/kernel/uImage . sync sync syncUmount and remove the USB rootfs.
printenvCopy and paste the list of the envs from above command in a notepad. And then,
setenv mtdparts 'mtdparts=pxa3xx_nand-0:0x180000@0(u-boot),0x20000@0x180000(u-boot-env),0x600000@0x200000(uImage),0x400000@0x800000(minirootfs),-(ubifs)' setenv usb_set_bootargs 'setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 $mtdparts earlyprintk=serial' setenv load_uimage 'ext2load usb 0:1 0x2000000 /boot/uImage' setenv load_uinitrd 'ext2load usb 0:1 0x3000000 /boot/uInitrd' setenv usb_boot 'run load_uimage; if run load_uinitrd; then bootm 0x2000000 0x3000000; else bootm 0x2000000; fi' setenv usb_bootcmd 'run usb_set_bootargs; run usb_boot' setenv bootcmd 'usb start; run usb_bootcmd; usb stop; reset' setenv fdt_skip_update yes
boot
ping debian.local
uname -aExpect Output:
Linux version 5.8.5-mvebu-370xp-tld-1 (root@tldDebianVM) (arm-linux-gnueabihf-gcc (Ubuntu/Linaro 7.5.0-3ubuntu1~18.04) 7.5.0, GNU ld (GNU Binutils for Ubuntu) 2.30) #1.0 SMP PREEMPT Mon Aug 31 00:00:32 PDT 2020
cd /boot cp -a uImage uImage.RN102.bak cp -a uInitrd uInitrd.bak dpkg -i /usr/src/kernel/linux-image-5.8.5-mvebu-370xp-tld-1_1.0_armhf.deb tar xf /usr/src/kernel/linux-dtb-5.8.5-mvebu-370xp-tld-1.tar cp -a /usr/src/kernel/zImage-5.8.5-mvebu-370xp-tld-1 . cp -a zImage-5.8.5-mvebu-370xp-tld-1 zImage.fdt cat dts/armada-370-netgear-rn102.dtb >> zImage.fdt mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-5.8.5-mvebu-370xp-tld-1 -d zImage.fdt uImage mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-5.8.5-mvebu-370xp-tld-1 -d initrd.img-5.8.5-mvebu-370xp-tld-1 uInitrd
cat /proc/mtdExpected Output:
dev: size erasesize name dev: size erasesize name mtd0: 00180000 00020000 "u-boot" mtd1: 00020000 00020000 "u-boot-env" mtd2: 00600000 00020000 "uImage" mtd3: 00400000 00020000 "minirootfs" mtd4: 07400000 00020000 "ubifs"
echo "/dev/mtd1 0x00000 0x20000 0x20000" > /etc/fw_env.config
fw_setenv test_xxxx yes fw_printenv test_xxxx fw_printenvExpected Output: If you can list the envs and they look like the envs listed in Step B.1 (with the additional test_xxxx env just set), then it's all checked out. If there is any error at this point then please stop and post question.
fw_setenv mtdparts 'mtdparts=pxa3xx_nand-0:0x180000@0(u-boot),0x20000@0x180000(u-boot-env),0x600000@0x200000(uImage),0x400000@0x800000(minirootfs),-(ubifs)' fw_setenv usb_set_bootargs 'setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 $mtdparts earlyprintk=serial' fw_setenv load_uimage 'ext2load usb 0:1 0x2000000 /boot/uImage' fw_setenv load_uinitrd 'ext2load usb 0:1 0x3000000 /boot/uInitrd' fw_setenv usb_boot 'run load_uimage; if run load_uinitrd; then bootm 0x2000000 0x3000000; else bootm 0x2000000; fi' fw_setenv usb_bootcmd 'run usb_set_bootargs; run usb_boot' fw_setenv bootcmd 'usb start; run usb_bootcmd; usb stop; reset' fw_setenv fdt_skip_update yes
fw_printenvCopy and paster the envs to a notepad, for safe keeing.
sync sync sync shutdown -r now
Quote
linux-image-4.20.6-mvebu-mirabox-tld-12_12.0_armhf.deb
linux-headers-4.20.6-mvebu-mirabox-tld-12_12.0_armhf.deb
zImage-4.20.6-mvebu-mirabox-tld-12
config-4.20.6-mvebu-mirabox-tld-12
linux-dtb-4.20.6-mvebu-mirabox-tld-12.tar
linux-4.20.6-mvebu-tld-1.patch
mkdir -p /media/sdd1/usr/src/mirabox cd /media/sdd1/usr/src/mirabox tar xf linux-4.20.6-mvebu-mirabox-tld-12-bodhi.tar.bz2
cd /media/sdd1/usr/src/mirabox tar -xvf linux-dtb-4.20.6-mvebu-mirabox-tld-12.tar dts/armada-370-mirabox.dtb cp zImage-4.20.6-mvebu-mirabox-tld-12 zImage.fdt cp -a zImage-4.20.6-mvebu-mirabox-tld-12 zImage.fdt cat dts/armada-370-mirabox.dtb >> zImage.fdt mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-4.20.6-mvebu-mirabox-tld-12 -d zImage.fdt uImage
cd /media/sdd1/boot cp -a uImage uImage.bak cp -a /media/sdd1/usr/src/mirabox/uImage . sync
printenvCopy and paste the list of the envs from above command in a notepad. And then,
setenv set_bootargs_stock 'setenv bootargs "console=ttyS0,115200 $mtdparts ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs"' setenv bootcmd_stock 'echo Booting Stock...; nand read 0x6400000 0x400000 0x400000; run set_bootargs_stock; bootm 0x6400000' setenv load_image_addr 0x6400000 setenv load_initrd_addr 0x8400000 setenv load_uImage 'ext2load usb 1:1 $load_image_addr /boot/uImage' setenv load_uInitrd 'ext2load usb 1:1 $load_initrd_addr /boot/uInitrd' setenv set_bootargs_debian 'setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 mtdparts=pxa3xx_nand-0:4M(u-boot),4M(linux),-(filesystem) earlyprintk=serial' setenv bootcmd_debian 'echo Booting Debian... ; usb start; run load_uImage; run load_uInitrd; run set_bootargs_debian; bootm $load_image_addr $load_initrd_addr' setenv bootcmd 'run bootcmd_debian; run bootcmd_stock'
boot
ping debian.local
uname -aExpect Output:
Linux debian 4.20.6-mvebu-mirabox-tld-12 #6 SMP PREEMPT Wed Mar 13 14:43:16 PDT 2019 armv7l GNU/Linux
cd /boot cp -a uImage uImage.mirabox.bak cp -a uInitrd uInitrd.bak dpkg -i /usr/src/mirabox/linux-image-4.20.6-mvebu-mirabox-tld-12_12.0_armhf.deb tar xf /usr/src/mirabox/linux-dtb-4.20.6-mvebu-mirabox-tld-12.tar cp -a /usr/src/mirabox/zImage-4.20.6-mvebu-mirabox-tld-12 . cp -a zImage-4.20.6-mvebu-mirabox-tld-12 zImage.fdt cat dts/armada-370-mirabox.dtb >> zImage.fdt mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-4.20.6-mvebu-mirabox-tld-12 -d zImage.fdt uImage mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-4.20.6-mvebu-mirabox-tld-12 -d initrd.img-4.20.6-mvebu-mirabox-tld-12 uInitrd
cat /proc/mtdExpected Output:
dev: size erasesize name mtd0: 00400000 00080000 "u-boot" mtd1: 00400000 00080000 "linux" mtd2: 3f800000 00080000 "filesystem"
echo "/dev/mtd0 0x100000 0x00080000 0x00080000" > /etc/fw_env.config
fw_setenv test_xxxx yes fw_printenv test_xxxx fw_printenvExpected Output: If you can list the envs and they look like the envs listed in Step B.1 (with the additional test_xxxx env just set), then it's all checked out. If there is any error at this point then please stop and post question.
fw_setenv set_bootargs_stock 'setenv bootargs "console=ttyS0,115200 $mtdparts ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs"' fw_setenv bootcmd_stock 'echo Booting Stock...; nand read 0x6400000 0x400000 0x400000; run set_bootargs_stock; bootm 0x6400000' fw_setenv load_image_addr 0x6400000 fw_setenv load_initrd_addr 0x8400000 fw_setenv load_uImage 'ext2load usb 1:1 $load_image_addr /boot/uImage' fw_setenv load_uInitrd 'ext2load usb 1:1 $load_initrd_addr /boot/uInitrd' fw_setenv set_bootargs_debian 'setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 mtdparts=pxa3xx_nand-0:4M(u-boot),4M(linux),-(filesystem) earlyprintk=serial' fw_setenv bootcmd_debian 'echo Booting Debian... ; usb start; run load_uImage; run load_uInitrd; run set_bootargs_debian; bootm $load_image_addr $load_initrd_addr' fw_setenv bootcmd 'run bootcmd_debian; run bootcmd_stock'
fw_printenvCopy and paster the envs to a notepad, for safe keeing.
sync shutdown -r now
Re: Mirabox (Armada 370) Installation November 17, 2019 04:52AM |
Registered: 9 years ago Posts: 451 |
Re: Mirabox (Armada 370) Installation November 17, 2019 05:08AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation September 02, 2020 02:58AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: Mirabox (Armada 370) Installation September 02, 2020 06:42PM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: Mirabox (Armada 370) Installation September 05, 2020 01:29AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 26, 2020 04:30PM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 26, 2020 06:29PM |
Registered: 7 years ago Posts: 369 |
------------------------------------------------------------ Server listening on TCP port 5001 TCP window size: 128 KByte (default) ------------------------------------------------------------ [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49012 [ ID] Interval Transfer Bandwidth [ 4] 0.0-10.0 sec 679 MBytes 569 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49014 [ 4] 0.0-10.0 sec 672 MBytes 563 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49016 [ 4] 0.0-10.0 sec 678 MBytes 568 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49018 [ 4] 0.0-10.0 sec 664 MBytes 556 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49020 [ 4] 0.0-10.0 sec 670 MBytes 561 Mbits/sec new kernel 5.9.3 --------------------------------------------------------------------------------------------------- [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 44442 [ 4] 0.0-10.0 sec 980 MBytes 821 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 44444 [ 4] 0.0-10.0 sec 954 MBytes 800 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 44446 [ 4] 0.0-10.0 sec 930 MBytes 779 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 44448 [ 4] 0.0-10.0 sec 949 MBytes 796 Mbits/sec Old Kernel 5.8.5
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 27, 2020 06:54AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 27, 2020 06:57AM |
Registered: 7 years ago Posts: 181 |
$ ssh debian.local tme@debian.local's password: Linux debian 5.9.3-mvebu-370xp-tld-1 #1.0 SMP PREEMPT Tue Nov 24 20:43:55 PST 2020 armv7l The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Fri Nov 27 00:39:20 2020 from 192.168.1.50 tme@debian:~$ ip link show 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 1024 link/ether 28:c6:8e:34:73:94 brd ff:ff:ff:ff:ff:ff 3: sit0@NONE: <NOARP> mtu 1480 qdisc noop state DOWN mode DEFAULT group default qlen 1000 link/sit 0.0.0.0 brd 0.0.0.0 4: ip6tnl0@NONE: <NOARP> mtu 1452 qdisc noop state DOWN mode DEFAULT group default qlen 1000 link/tunnel6 :: brd :: tme@debian:~$But first I learned what happens if one installs the dtb-file for Mirabox on the RN102. The box switches itself off after about half a minute, the last line on the serial console being:
[ 5.372291][ T1] mdio_bus d0072004.mdio-mii: MDIO device at address 1 is missing.Good to know. :-)
tme@debian:~$ dd if=/dev/zero of=/dev/null bs=32k count=32768 32768+0 records in 32768+0 records out 1073741824 bytes (1,1 GB, 1,0 GiB) copied, 0,93677 s, 1,1 GB/sThat is a 80% performance increase over the stock firmware! Before the kernel upgrade, the box was almost par with stock.
tme@debian:~$ dd if=/dev/urandom of=/dev/null bs=32k count=4096 4096+0 records in 4096+0 records out 134217728 bytes (134 MB, 128 MiB) copied, 4,80931 s, 27,9 MB/sThis is as before the upgrade and much better than the stock firmware which needs 40 s for this task, probably lacking support for the hardware random number generator.
tme@debian:~$ time nc -q 0 -l -p 2222 > /dev/null real 0m20,338s user 0m0,307s sys 0m18,424sAnd this is the on the laptop:
$ pv -S -s 1G /dev/zero | nc 192.168.1.39 2222 1,00GiB 0:00:20 [49,0MiB/s] [===================================================================================>] 100% ^CThe same test with 'dd' in stead of 'pv' takes 1 s longer. So, also this kernel is not able to saturate the gigabit Ethernet when receiving. The stock kernel is able, reducing the time to 12 s. That is an annoying performance drop from stock by 33%.
tme@debian:~$ pv -S -s 1G /dev/zero | nc 192.168.1.50 2222 1,00GiB 0:00:52 [19,3MiB/s] [===================================================================================>] 100% ^CReplacing 'pv' with 'dd if=/dev/zero bs=32k count=32768' adds a second here too. So the receiving performance is bad, sending is worse.
tme@debian:~$ iperf -c 192.168.1.50 ------------------------------------------------------------ Client connecting to 192.168.1.50, TCP port 5001 TCP window size: 43.8 KByte (default) ------------------------------------------------------------ [ 3] local 192.168.1.39 port 59142 connected with 192.168.1.50 port 5001 [ ID] Interval Transfer Bandwidth [ 3] 0.0-10.0 sec 721 MBytes 605 Mbits/sec
tme@debian:~$ iperf -s ------------------------------------------------------------ Server listening on TCP port 5001 TCP window size: 128 KByte (default) ------------------------------------------------------------ [ 4] local 192.168.1.39 port 5001 connected with 192.168.1.50 port 45692 [ ID] Interval Transfer Bandwidth [ 4] 0.0- 9.2 sec 634 MBytes 578 Mbits/sec ^C
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 27, 2020 03:47PM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 04:12AM |
Registered: 7 years ago Posts: 181 |
diff -crw mainline/drivers/net/ethernet/marvell/Kconfig netgear/drivers/net/ethernet/marvell/Kconfig *** mainline/drivers/net/ethernet/marvell/Kconfig 2020-11-28 09:39:13.153766986 +0100 --- netgear/drivers/net/ethernet/marvell/Kconfig 2020-02-05 08:32:17.000000000 +0100 *************** *** 72,77 **** --- 72,105 ---- To compile this driver as a module, choose M here. The module will be called pxa168_eth. + config SK98LIN + tristate "Marvell Yukon Chipset / SysKonnect SK-98xx Support" + depends on PCI + ---help--- + Say Y here if you have a Marvell Yukon or SysKonnect SK-98xx/SK-95xx + compliant Gigabit Ethernet Adapter. + + The adapters support Jumbo Frames. + The dual link adapters support link-failover and dual port features. + Both Marvell Yukon and SysKonnect SK-98xx/SK-95xx adapters support + the scatter-gather functionality with sendfile(). Please refer to + Documentation/networking/sk98lin.txt for more information about + optional driver parameters. + Questions concerning this driver may be addressed to: + linux@syskonnect.de + + If you want to compile this driver as a module ( = code which can be + inserted in and removed from the running kernel whenever you want), + say M here and read Documentation/modules.txt. This is recommended. + The module will be called sk98lin. This is recommended. + + config SK98LIN_NAPI + bool "Use Rx polling (NAPI)" + depends on SK98LIN + help + NAPI is a new driver API designed to reduce CPU and interrupt load + when the driver is receiving lots of packets from the card. + config SKGE tristate "Marvell Yukon Gigabit Ethernet support" depends on PCI diff -crw mainline/drivers/net/ethernet/marvell/Makefile netgear/drivers/net/ethernet/marvell/Makefile *** mainline/drivers/net/ethernet/marvell/Makefile 2020-11-28 09:39:13.153766986 +0100 --- netgear/drivers/net/ethernet/marvell/Makefile 2020-02-05 08:32:17.000000000 +0100 *************** *** 7,11 **** --- 7,12 ---- obj-$(CONFIG_MVNETA) += mvneta.o obj-$(CONFIG_MVPP2) += mvpp2.o obj-$(CONFIG_PXA168_ETH) += pxa168_eth.o + obj-$(CONFIG_SK98LIN) += sk98lin/ obj-$(CONFIG_SKGE) += skge.o obj-$(CONFIG_SKY2) += sky2.o diff -crw mainline/drivers/net/ethernet/marvell/mvmdio.c netgear/drivers/net/ethernet/marvell/mvmdio.c *** mainline/drivers/net/ethernet/marvell/mvmdio.c 2020-11-28 09:39:13.153766986 +0100 --- netgear/drivers/net/ethernet/marvell/mvmdio.c 2020-02-05 08:32:18.000000000 +0100 *************** *** 279,284 **** --- 279,343 ---- return 0; } + static void orion_mdio_shutdown(struct platform_device *pdev) + { + struct mii_bus *bus = platform_get_drvdata(pdev); + u16 rega, regb; + int i; + + /* replaces /proc/power_mode_2 */ + /* Force 10Mbps half duplex, disable autoneg */ + for (i = 0; i < 2; i++) { + orion_mdio_write(bus, i, 0x16, 0x0); + orion_mdio_write(bus, i, 0x0, 0x8000); + } + if (system_state == SYSTEM_RESTART) { + /* Clear MII_88E1318S_PHY_LED_TCR_INT_ACTIVE_LOW, or the system + ** will not reboot. RN2120 appears to rely on a PHY link change + ** interrupt to "reboot", so make sure it's enabled. */ + orion_mdio_write(bus, 0, 0x16, 0x3); + rega = orion_mdio_read(bus, 0, 0x12); + regb = (rega | BIT(7)) & ~(BIT(11)); + } else { + /* WoL enabled? */ + orion_mdio_write(bus, 0, 0x16, 0x11); + rega = orion_mdio_read(bus, 0, 0x10); + if (rega & BIT(14)) { + /* Enable interrupt only on WOL event. + ** We get an immediate poweron with large MTU without this */ + for (i = 0; i < 2; i++) { + orion_mdio_write(bus, i, 0x16, 0x0); + orion_mdio_write(bus, i, 0x12, 0x80); + } + /* Magic packet enable, Clear WOL status, ..., 10BT LPM */ + regb = BIT(14) | BIT(12) | BIT(10) | BIT(8) | BIT(7); + pr_debug("MII_88E1318S_PHY_WOL_CTRL: 0x%x => 0x%x\n", + rega, regb); + for (i = 0; i < 2; i++) { + orion_mdio_write(bus, i, 0x16, 0x11); + orion_mdio_write(bus, i, 0x10, regb); + orion_mdio_write(bus, i, 0x16, 0x3); + } + rega = orion_mdio_read(bus, 0, 0x12); + regb = rega | BIT(11) | BIT(7); + } else { + for (i = 0; i < 2; i++) { + orion_mdio_write(bus, i, 0x16, 0x0); + orion_mdio_write(bus, i, 0x0, BMCR_PDOWN); + orion_mdio_write(bus, i, 0x12, 0x0); + orion_mdio_write(bus, i, 0x16, 0x3); + } + rega = orion_mdio_read(bus, 0, 0x12); + regb = rega & ~(BIT(11) | BIT(7)); + } + } + pr_debug("MII_88E1318S_LED_TCR: 0x%x => 0x%x\n", rega, regb); + for (i = 0; i < 2; i++) { + orion_mdio_write(bus, 0, 0x12, regb); + orion_mdio_write(bus, 0, 0x16, 0x0); + } + } + static const struct of_device_id orion_mdio_match[] = { { .compatible = "marvell,orion-mdio" }, { } *************** *** 288,293 **** --- 347,353 ---- static struct platform_driver orion_mdio_driver = { .probe = orion_mdio_probe, .remove = orion_mdio_remove, + .shutdown = orion_mdio_shutdown, .driver = { .name = "orion-mdio", .of_match_table = orion_mdio_match, Only in netgear/drivers/net/ethernet/marvell/: mvmdio.c.orig diff -crw mainline/drivers/net/ethernet/marvell/mvneta.c netgear/drivers/net/ethernet/marvell/mvneta.c *** mainline/drivers/net/ethernet/marvell/mvneta.c 2020-11-28 09:39:13.153766986 +0100 --- netgear/drivers/net/ethernet/marvell/mvneta.c 2020-02-05 08:32:18.000000000 +0100 *************** *** 2930,2935 **** --- 2930,2963 ---- /* Ethtool methods */ + static void + mvneta_eth_get_wol(struct net_device *dev, struct ethtool_wolinfo *wol) + { + struct mvneta_port *pp = netdev_priv(dev); + wol->supported = 0; + wol->wolopts = 0; + if (pp->phy_dev) + phy_ethtool_get_wol(pp->phy_dev, wol); + } + + static int + mvneta_eth_set_wol(struct net_device *dev, struct ethtool_wolinfo *wol) + { + struct mvneta_port *pp = netdev_priv(dev); + int err; + + if (pp->phy_dev == NULL) + return -EOPNOTSUPP; + + err = phy_ethtool_set_wol(pp->phy_dev, wol); + /* Given that mvneta works without the marvell-specific PHY driver, + * this debugging hint is useful to have. + */ + if (err == -EOPNOTSUPP) + netdev_info(dev, "The PHY does not support set_wol, was CONFIG_MARVELL_PHY enabled?\n"); + return err; + } + /* Get settings (phy address, speed) for ethtools */ int mvneta_ethtool_get_settings(struct net_device *dev, struct ethtool_cmd *cmd) { *************** *** 3100,3105 **** --- 3128,3148 ---- return -EOPNOTSUPP; } + #ifdef CONFIG_NET_POLL_CONTROLLER + /* Created after drivers/net/ethernet/dec/tulip/tulip_core.c */ + static void mvneta_poll_controller(struct net_device *dev) + { + struct mvneta_port *pp = netdev_priv(dev); + int irq = pp->dev->irq; + + /* disable_irq here is not very nice, but with the lockless + interrupt handler we have no other choice. */ + disable_irq(irq); + mvneta_isr(irq, dev); + enable_irq(irq); + } + #endif + static const struct net_device_ops mvneta_netdev_ops = { .ndo_open = mvneta_open, .ndo_stop = mvneta_stop, *************** *** 3110,3115 **** --- 3153,3161 ---- .ndo_fix_features = mvneta_fix_features, .ndo_get_stats64 = mvneta_get_stats64, .ndo_do_ioctl = mvneta_ioctl, + #ifdef CONFIG_NET_POLL_CONTROLLER + .ndo_poll_controller = mvneta_poll_controller, + #endif }; const struct ethtool_ops mvneta_eth_tool_ops = { *************** *** 3124,3129 **** --- 3170,3177 ---- .get_strings = mvneta_ethtool_get_strings, .get_ethtool_stats = mvneta_ethtool_get_stats, .get_sset_count = mvneta_ethtool_get_sset_count, + .get_wol = mvneta_eth_get_wol, + .set_wol = mvneta_eth_set_wol, }; /* Initialize hw */ Only in netgear/drivers/net/ethernet/marvell/: mvneta.c.orig Only in netgear/drivers/net/ethernet/marvell/: sk98lin diff -crw mainline/drivers/net/ethernet/marvell/sky2.c netgear/drivers/net/ethernet/marvell/sky2.c *** mainline/drivers/net/ethernet/marvell/sky2.c 2020-11-28 09:39:13.157766985 +0100 --- netgear/drivers/net/ethernet/marvell/sky2.c 2020-02-05 08:32:18.000000000 +0100 *************** *** 2195,2200 **** --- 2195,2201 ---- [FC_RX] = "rx", [FC_BOTH] = "both", }; + char u4[16] = ""; sky2_set_ipg(sky2); *************** *** 2210,2220 **** sky2_write8(hw, SK_REG(port, LNK_LED_REG), LINKLED_ON | LINKLED_BLINK_OFF | LINKLED_LINKSYNC_OFF); netif_info(sky2, link, sky2->netdev, ! "Link is up at %d Mbps, %s duplex, flow control %s\n", sky2->speed, sky2->duplex == DUPLEX_FULL ? "full" : "half", ! fc_name[sky2->flow_status]); } static void sky2_link_down(struct sky2_port *sky2) --- 2211,2227 ---- sky2_write8(hw, SK_REG(port, LNK_LED_REG), LINKLED_ON | LINKLED_BLINK_OFF | LINKLED_LINKSYNC_OFF); + /* NETGEAR: Change PHY power setting to make Ultra 4 alpha gigabit work */ + if (strstr(saved_command_line, "u4_alpha")) { + gm_phy_write(hw, port, PHY_MARV_EXT_CTRL_2, 0x8040); + strcpy(u4, ", ultra4-alpha"); + } + netif_info(sky2, link, sky2->netdev, ! "Link is up at %d Mbps, %s duplex, flow control %s%s\n", sky2->speed, sky2->duplex == DUPLEX_FULL ? "full" : "half", ! fc_name[sky2->flow_status], u4); } static void sky2_link_down(struct sky2_port *sky2) Only in netgear/drivers/net/ethernet/marvell/: sky2.c.orig
diff -crw mainline/drivers/net/ethernet/marvell/ netgear/drivers/net/ethernet/marvell/ > /tmp/mvneta-v4.4.190-netgear.diffwhere
$ diff --version diff (GNU diffutils) 3.7 $ ls -alF mainline netgear lrwxrwxrwx 1 tme tme 13 nov. 28 09:43 mainline -> linux-stable// lrwxrwxrwx 1 tme tme 80 nov. 28 09:44 netgear -> /home/tme/ReadyNAS-RN102/src/Netgear/ReadyNASOS_V6.10.3_WW_src/linux-4.4.190-arm/ $ (cd mainline && git status) On branch mainline-4.4.190 nothing to commit, working tree clean
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 05:22AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 05:48AM |
Registered: 7 years ago Posts: 181 |
Quote
The reasoning: the Mirabox and the RN102 has identical SoC and therefore using the same network chip (is my assumption correct?), and David can get 800's Mbs with iperf test on the Mirabox (running kernel 5.8.5).
Quote
tme
# iperf -c 192.168.1.200 ------------------------------------------------------------ Client connecting to 192.168.1.200, TCP port 5001 TCP window size: 43.8 KByte (default) ------------------------------------------------------------ [ 3] local 192.168.1.192 port 40402 connected with 192.168.1.200 port 5001 [ ID] Interval Transfer Bandwidth [ 3] 0.0-10.0 sec 1.09 GBytes 939 Mbits/sec
*** linux-5.9.3/arch/arm/mach-mvebu/coherency.c 2020-11-28 11:42:20.978304894 +0100 --- netgear/arch/arm/mach-mvebu/coherency.c 2019-08-25 10:53:06.000000000 +0200 *************** *** 107,122 **** .notifier_call = mvebu_hwcc_notifier, }; ! static struct notifier_block mvebu_hwcc_pci_nb __maybe_unused = { .notifier_call = mvebu_hwcc_notifier, }; ! static int armada_xp_clear_l2_starting(unsigned int cpu) { armada_xp_clear_shared_l2(); ! return 0; } static void __init armada_370_coherency_init(struct device_node *np) { struct resource res; --- 107,130 ---- .notifier_call = mvebu_hwcc_notifier, }; ! static struct notifier_block mvebu_hwcc_pci_nb = { .notifier_call = mvebu_hwcc_notifier, }; ! static int armada_xp_clear_shared_l2_notifier_func(struct notifier_block *nfb, ! unsigned long action, void *hcpu) { + if (action == CPU_STARTING || action == CPU_STARTING_FROZEN) armada_xp_clear_shared_l2(); ! ! return NOTIFY_OK; } + static struct notifier_block armada_xp_clear_shared_l2_notifier = { + .notifier_call = armada_xp_clear_shared_l2_notifier_func, + .priority = 100, + }; + static void __init armada_370_coherency_init(struct device_node *np) { struct resource res; *************** *** 147,155 **** of_node_put(cpu_config_np); ! cpuhp_setup_state_nocalls(CPUHP_AP_ARM_MVEBU_COHERENCY, ! "arm/mvebu/coherency:starting", ! armada_xp_clear_l2_starting, NULL); exit: set_cpu_coherent(); } --- 155,162 ---- of_node_put(cpu_config_np); ! register_cpu_notifier(&armada_xp_clear_shared_l2_notifier); ! exit: set_cpu_coherent(); } *************** *** 174,180 **** coherency_cpu_base = of_iomap(np, 0); arch_ioremap_caller = armada_wa_ioremap_caller; - pci_ioremap_set_mem_type(MT_UNCACHED); /* * We should switch the PL310 to I/O coherency mode only if --- 181,186 ---- *** linux-5.9.3/arch/arm/mach-mvebu/coherency.h 2020-11-28 11:35:42.792222332 +0100 --- netgear/arch/arm/mach-mvebu/coherency.h 2019-08-25 10:53:06.000000000 +0200 *************** *** 14,20 **** #ifndef __MACH_370_XP_COHERENCY_H #define __MACH_370_XP_COHERENCY_H - extern void __iomem *coherency_base; /* for coherency_ll.S */ extern unsigned long coherency_phys_base; int set_cpu_coherent(void); --- 14,19 ---- *** linux-5.9.3/arch/arm/mach-mvebu/coherency_ll.S 2020-11-28 11:42:20.978304894 +0100 --- netgear/arch/arm/mach-mvebu/coherency_ll.S 2019-08-25 10:53:06.000000000 +0200 *************** *** 66,72 **** * fabric registers */ ENTRY(ll_get_coherency_cpumask) ! mrc p15, 0, r3, cr0, cr0, 5 and r3, r3, #15 mov r2, #(1 << 24) lsl r3, r2, r3 --- 66,72 ---- * fabric registers */ ENTRY(ll_get_coherency_cpumask) ! mrc 15, 0, r3, cr0, cr0, 5 and r3, r3, #15 mov r2, #(1 << 24) lsl r3, r2, r3
for i in coherency.c coherency.h coherency_ll.S; do diff -cw linux-5.9.3/arch/arm/mach-mvebu/$i netgear/arch/arm/mach-mvebu/$i; done > /tmp/coherency-v5.9.3-netgear.diff
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 06:19AM |
Registered: 6 years ago Posts: 183 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 06:29AM |
Admin Registered: 13 years ago Posts: 18,821 |
Quote
I don't know about the Mirabox, but the RN102 has a Marvell 88E1318 Gigabit Ethernet PHY (ref).
Quote
Anyhow, if the network performance drop is an IO coherency issue, these Netgear patches may be the relevant ones:
for i in coherency.c coherency.h coherency_ll.S; do diff -cw linux-5.9.3/arch/arm/mach-mvebu/$i netgear/arch/arm/mach-mvebu/$i; done > /tmp/coherency-v5.9.3-netgear.diff
armada-370-xp.dtsi: coherencyfab: coherency-fabric@20200 { armada-370-xp.dtsi: compatible = "marvell,coherency-fabric";
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 06:55AM |
Registered: 7 years ago Posts: 181 |
$ grep -i thumb2 netgear/.config # CONFIG_THUMB2_KERNEL is not set $ ls -alF netgear lrwxrwxrwx 1 tme tme 80 nov. 28 09:44 netgear -> /home/tme/ReadyNAS-RN102/src/Netgear/ReadyNASOS_V6.10.3_WW_src/linux-4.4.190-arm/
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 07:53AM |
Registered: 6 years ago Posts: 183 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 12:21PM |
Registered: 7 years ago Posts: 181 |
Quote
Ah, that's a bit different, the Mirabox has 88E1510.
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 03:38PM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 03:58PM |
Admin Registered: 13 years ago Posts: 18,821 |
Settings for eth0: Supported ports: [ TP MII ] Supported link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Full Supported pause frame use: Symmetric Receive-only Supports auto-negotiation: Yes Supported FEC modes: Not reported Advertised link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Full Advertised pause frame use: No Advertised auto-negotiation: Yes Advertised FEC modes: Not reported Link partner advertised link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Full Link partner advertised pause frame use: Symmetric Receive-only Link partner advertised auto-negotiation: Yes Link partner advertised FEC modes: Not reported Speed: 1000Mb/s Duplex: Full Port: MII PHYAD: 1 Transceiver: internal Auto-negotiation: on Supports Wake-on: g Wake-on: g Link detected: yes
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 05:12PM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 28, 2020 11:46PM |
Registered: 7 years ago Posts: 369 |
------------------------------------------------------------ Server listening on TCP port 5001 TCP window size: 128 KByte (default) ------------------------------------------------------------ [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 57762 [ ID] Interval Transfer Bandwidth [ 4] 0.0-10.0 sec 990 MBytes 830 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 57764 [ 4] 0.0-10.0 sec 977 MBytes 819 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 57766 [ 4] 0.0-10.0 sec 974 MBytes 816 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 57768 [ 4] 0.0-10.0 sec 972 MBytes 815 Mbits/sec Old 5.8.5 --------------------------------------------------------------------------------------------------- [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59518 [ 4] 0.0-10.0 sec 928 MBytes 778 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59520 [ 4] 0.0-10.0 sec 952 MBytes 799 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59522 [ 4] 0.0-10.0 sec 890 MBytes 746 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59524 [ 4] 0.0-10.0 sec 921 MBytes 772 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59526 [ 4] 0.0-10.0 sec 904 MBytes 758 Mbits/sec 5.9.3-mvebu-370xp-tld-2 ---------------------------------------------------------------------------------------------- [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49012 [ ID] Interval Transfer Bandwidth [ 4] 0.0-10.0 sec 679 MBytes 569 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49014 [ 4] 0.0-10.0 sec 672 MBytes 563 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49016 [ 4] 0.0-10.0 sec 678 MBytes 568 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49018 [ 4] 0.0-10.0 sec 664 MBytes 556 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49020 [ 4] 0.0-10.0 sec 670 MBytes 561 Mbits/sec 5.9.3-mvebu-370xp-tld-1 (Copied from old data)
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 29, 2020 12:27AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade November 29, 2020 01:55AM |
Registered: 7 years ago Posts: 181 |
Quote
According to Wikidevi the RN102 uses 88E1318, to be exact.
$ grep SMP ~/ReadyNAS-RN102/src/Netgear/ReadyNASOS_V6.10.3_WW_src/linux-4.4.190-arm/.config | sort CONFIG_GENERIC_SMP_IDLE_THREAD=y CONFIG_HAVE_SMP=y CONFIG_SMP_ON_UP=y CONFIG_SMP=y
tme@debian:~$ grep SMP /boot/config-5.9.3-mvebu-370xp-tld-1 | sort CONFIG_GENERIC_SMP_IDLE_THREAD=y CONFIG_HAVE_SMP=y CONFIG_PM_SLEEP_SMP=y CONFIG_SCSI_SAS_HOST_SMP=y CONFIG_SMP_ON_UP=y CONFIG_SMP=y CONFIG_VIDEO_VP27SMPX=m
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade December 02, 2020 04:29AM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade December 02, 2020 07:23AM |
Registered: 7 years ago Posts: 369 |
------------------------------------------------------------ Server listening on TCP port 5001 TCP window size: 128 KByte (default) ------------------------------------------------------------ [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 57762 [ ID] Interval Transfer Bandwidth [ 4] 0.0-10.0 sec 990 MBytes 830 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 57764 [ 4] 0.0-10.0 sec 977 MBytes 819 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 57766 [ 4] 0.0-10.0 sec 974 MBytes 816 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 57768 [ 4] 0.0-10.0 sec 972 MBytes 815 Mbits/sec Old kernel 5.8.5 (Copied from old data) --------------------------------------------------------------------------------------------------- [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 38296 [ ID] Interval Transfer Bandwidth [ 4] 0.0-10.0 sec 1.04 GBytes 896 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 38298 [ 4] 0.0-10.0 sec 1.00 GBytes 859 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 38300 [ 4] 0.0-10.0 sec 1.02 GBytes 875 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 38302 [ 4] 0.0-10.0 sec 1008 MBytes 845 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 38304 [ 4] 0.0-10.0 sec 1.05 GBytes 899 Mbits/sec 5.9.3-mvebu-370xp-tld-3 ---------------------------------------------------------------------------------------------- [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59518 [ 4] 0.0-10.0 sec 928 MBytes 778 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59520 [ 4] 0.0-10.0 sec 952 MBytes 799 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59522 [ 4] 0.0-10.0 sec 890 MBytes 746 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59524 [ 4] 0.0-10.0 sec 921 MBytes 772 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 59526 [ 4] 0.0-10.0 sec 904 MBytes 758 Mbits/sec 5.9.3-mvebu-370xp-tld-2 (Copied from old data) ---------------------------------------------------------------------------------------------- [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49012 [ ID] Interval Transfer Bandwidth [ 4] 0.0-10.0 sec 679 MBytes 569 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49014 [ 4] 0.0-10.0 sec 672 MBytes 563 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49016 [ 4] 0.0-10.0 sec 678 MBytes 568 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49018 [ 4] 0.0-10.0 sec 664 MBytes 556 Mbits/sec [ 4] local 192.168.7.28 port 5001 connected with 192.168.7.48 port 49020 [ 4] 0.0-10.0 sec 670 MBytes 561 Mbits/sec 5.9.3-mvebu-370xp-tld-1 (Copied from old data)
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade December 02, 2020 02:44PM |
Admin Registered: 13 years ago Posts: 18,821 |
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade December 05, 2020 03:20PM |
Admin Registered: 13 years ago Posts: 18,821 |
Quote
linux-image-5.9.3-mvebu-370xp-tld-4_4.0_armhf.deb
linux-headers-5.9.3-mvebu-370xp-tld-4_4.0_armhf.deb
zImage-5.9.3-mvebu-370xp-tld-4
config-5.9.3-mvebu-370xp-tld-4
linux-dtb-5.9.3-mvebu-370xp-tld-3.tar
linux-5.9.3-mvebu-370xp-tld-2.patch
mmu.c.patch
Re: GTI Mirabox and Netgear RN120 (Armada 370) Installation & Kernel Upgrade December 06, 2020 06:55AM |
Registered: 5 years ago Posts: 73 |
Kernel Version 5.8.5 tld-1 5.9.3 tld-3 5.9.3 tld-4 iperf 196 Mbits/sec 722 Mbits/sec 636 Mbits/sec Sysbench Memory 0.66ms 0.67ms 0.77ms Sysbench CPU 4.33ms 6.32ms 6.33ms /dev/zero Not tested 669 MB/s 1.3 GB/s /dev/urandom Not tested 29.2 MB/s 31.8 MB/s