Can this image work for TP-Link EC220-G5 ? Support for tp-link ec220-g5 - #5 by Guerra
I have no idea.
Maybe it will help? Support for tp-link ec220-g5 - #10 by nybash
Please share your solution for serial flash. I am having the same problem. The router fails to respond to '4' and 't' during power up.
Your help is appreciated.
Sorry all. I discovered the problem. Please ignore my request.
Thank you all.
Thank you for the images. I am using 19.07.02. I received kernel version mismatch error after openvpn-openssl package installation attempt. Please update the images to match kernel versions for this package. Thank you for your help.
FYI, the DSA driver for the Realtek rtl8367s got merged upstream today. It might arrive with kernel 5.18. Once that switch driver is available, it might not be too difficult to have C5v4 support merged.
This driver does not offload forwarding and all traffic between LAN ports still goes through the CPU. Maybe we can add the offload support before OpenWrt really uses it.
I have a branch with 5.15.17 kernel and dozens of backported patches that can generate a working image. There is a hack to disable all mediatek resets that prevented to boot the image. Mediatek Ethernet also have some trouble with checksum offload and incompatible dsa tag. I'll test changing the Realtek CPU tag position to the end of the packet. Maybe Mediatek will be happy with it. For now, it is disabling checksum offload.
If someone wants to take a look:
rstrip.sh: /home/lede-firmware/openwrt-luizluca/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/packages/ipkg-mipsel_24kc/kmod-nf-ipt/lib/modules/5.10.92/ip_tables.ko: relocatable rstrip.sh: /home/lede-firmware/openwrt-luizluca/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/packages/ipkg-mipsel_24kc/kmod-nf-ipt/lib/modules/5.10.92/x_tables.ko: relocatable Packaged contents of /home/lede-firmware/openwrt-luizluca/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/packages/ipkg-mipsel_24kc/kmod-nf-ipt into /home/lede-firmware/openwrt-luizluca/bin/targets/ramips/mt7620/packages/kmod-nf-ipt_5.10.92-1_mipsel_24kc.ipk ERROR: module '/home/lede-firmware/openwrt-luizluca/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/linux-5.10.92/net/netfilter/nf_log_syslog.ko' is missing. make: *** [modules/netfilter.mk:88: /home/lede-firmware/openwrt-luizluca/bin/targets/ramips/mt7620/packages/kmod-ipt-core_5.10.92-1_mipsel_24kc.ipk] Error 1 make: Leaving directory '/home/lede-firmware/openwrt-luizluca/package/kernel/linux' time: package/kernel/linux/compile#5.44#1.65#8.78 ERROR: package/kernel/linux failed to build. make: *** [package/Makefile:116: package/kernel/linux/compile] Error 1 make: Leaving directory '/home/lede-firmware/openwrt-luizluca' make: *** [package/Makefile:110: /home/lede-firmware/openwrt-luizluca/staging_dir/target-mipsel_24kc_musl/stamp/.package_compile] Error 2 make: Leaving directory '/home/lede-firmware/openwrt-luizluca' make: *** [/home/lede-firmware/openwrt-luizluca/include/toplevel.mk:230: world] Error 2
How can I manage it?
You need to enable testing kernel (5.15). You are building linux-5.10.92
make menuconfig > global > use testing kernel
Sorry, I could be more explicit. Thanks for sharing the way.
Unfortunately, this firmware won't work on my TP-LINK EC220. Ethernet switch and wlan5 don't work.
Hi! Can I flash the compiled firmware straight from stock? Thanks.
A little update, I got stuck in here:
make: Entering directory '/home/felipearanda/openwrt/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/linux-5.15.17' CALL scripts/checksyscalls.sh CALL scripts/atomic/check-atomics.sh CHK include/generated/compile.h CC drivers/net/ethernet/ralink/mtk_eth_soc.o In file included from ./include/linux/printk.h:11, from ./include/linux/kernel.h:19, from ./include/linux/list.h:9, from ./include/linux/module.h:12, from drivers/net/ethernet/ralink/mtk_eth_soc.c:15: drivers/net/ethernet/ralink/mtk_eth_soc.c: In function 'fe_features_check': drivers/net/ethernet/ralink/mtk_eth_soc.c:817:41: error: request for member 'needed_tailroom' in something not a structure or union 817 | WARN_ONCE(tag_ops->proto.needed_tailroom, | ^ ./include/linux/once_lite.h:15:41: note: in definition of macro 'DO_ONCE_LITE_IF' 15 | bool __ret_do_once = !!(condition); \ | ^~~~~~~~~ drivers/net/ethernet/ralink/mtk_eth_soc.c:817:17: note: in expansion of macro 'WARN_ONCE' 817 | WARN_ONCE(tag_ops->proto.needed_tailroom, | ^~~~~~~~~ In file included from ./arch/mips/include/asm/bug.h:42, from ./include/linux/bug.h:5, from ./arch/mips/include/asm/cmpxchg.h:11, from ./arch/mips/include/asm/atomic.h:22, from ./include/linux/atomic.h:7, from ./include/linux/cpumask.h:13, from ./include/linux/smp.h:13, from ./arch/mips/include/asm/cpu-type.h:12, from ./arch/mips/include/asm/timex.h:19, from ./include/linux/timex.h:65, from ./include/linux/time32.h:13, from ./include/linux/time.h:60, from ./include/linux/stat.h:19, from ./include/linux/module.h:13, from drivers/net/ethernet/ralink/mtk_eth_soc.c:15: drivers/net/ethernet/ralink/mtk_eth_soc.c:821:41: error: invalid type argument of '->' (have 'unsigned int') 821 | tag_ops->proto->name); | ^~ ./include/asm-generic/bug.h:91:62: note: in definition of macro '__WARN_printf' 91 | warn_slowpath_fmt(__FILE__, __LINE__, taint, arg); \ | ^~~ ./include/linux/once_lite.h:19:25: note: in expansion of macro 'WARN' 19 | func(__VA_ARGS__); \ | ^~~~ ./include/asm-generic/bug.h:150:9: note: in expansion of macro 'DO_ONCE_LITE_IF' 150 | DO_ONCE_LITE_IF(condition, WARN, 1, format) | ^~~~~~~~~~~~~~~ drivers/net/ethernet/ralink/mtk_eth_soc.c:817:17: note: in expansion of macro 'WARN_ONCE' 817 | WARN_ONCE(tag_ops->proto.needed_tailroom, | ^~~~~~~~~ drivers/net/ethernet/ralink/mtk_eth_soc.c: In function 'fe_probe': drivers/net/ethernet/ralink/mtk_eth_soc.c:1624:9: warning: ignoring return value of 'device_reset' declared with attribute 'warn_unused_result' [-Wunused-result] 1624 | device_reset(&pdev->dev); | ^~~~~~~~~~~~~~~~~~~~~~~~ make: *** [scripts/Makefile.build:277: drivers/net/ethernet/ralink/mtk_eth_soc.o] Error 1 make: *** [scripts/Makefile.build:540: drivers/net/ethernet/ralink] Error 2 make: *** [scripts/Makefile.build:540: drivers/net/ethernet] Error 2 make: *** [scripts/Makefile.build:540: drivers/net] Error 2 make: *** [Makefile:1868: drivers] Error 2 make: Leaving directory '/home/felipearanda/openwrt/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/linux-5.15.17' make: *** [Makefile:24: /home/felipearanda/openwrt/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7620/linux-5.15.17/.modules] Error 2 make: Leaving directory '/home/felipearanda/openwrt/target/linux/ramips' make: *** [Makefile:11: compile] Error 2 make: Leaving directory '/home/felipearanda/openwrt/target/linux' time: target/linux/compile#3.76#1.19#5.02 ERROR: target/linux failed to build. make: *** [target/Makefile:30: target/linux/compile] Error 1 make: Leaving directory '/home/felipearanda/openwrt' make: *** [target/Makefile:23: /home/felipearanda/openwrt/staging_dir/target-mipsel_24kc_musl/stamp/.target_compile] Error 2 make: Leaving directory '/home/felipearanda/openwrt' make: *** [/home/felipearanda/openwrt/include/toplevel.mk:230: world] Error 2
Hi! I was able to keep compiling by commenting out this part of the code:
/*WARN_ONCE(tag_ops->proto.needed_tailroom, "The DSA TAG %s is added to the end of the packet." "It will break HW and SW checksum for any driver " "incompatible with that TAG (different vendor)", tag_ops->proto->name);*/
But I believe this is part of the HW offload fix @luizluca created, right?
No. I believe you still need to use the tftp recovery method (or the serial port). Nothing has changed in that front.
I'll try to cleanup that branch a little bit more. There were some upstream changes that I need to put in sync.
Yes, it is more a "disable HW offload" than a fix There is no possible fix.
Got it! So, is it ok to leave that part off? It successfully built the image. Thank you for your time on this project
A post was split to a new topic: Full dump of TP Link Archer C5 v4 needed
Hi luizluca, I'm trying to compile sysupgrade image for my C5 v4, using the branch tplink_c5v4_dsa_5.15up.
For config, select:
- Target system : MediaTek Ralink MIPS
- Subtarget : MT7620 based boards
- Target profile : TP-Link Archer C5 v4
- Enable experimental features by default
The image compiles successfully, but when flash it to the router, no ports seems to work (wan & lan). Only wifi works when enable it from serial console.
Am I missing something, or doing something wrong?
Thanks in advance!
i guess you are missing a kernel driver patch for the switch or not enabled the vendor specifc DSA tag + vendor specifc DSA switch support for your device..