Problems trying to apply FastPath ar71xx 17.01 branch

Hello, i`m trying to recompile Lede from branch Lede-17.01 (for Tp-Link 1043ND V4) and i get bridge: automatic filtering via arp/ip/ip6tables has been deprecated message and continously rebooting of the router.

Any ideea how to skip this?

Thanks!

[    0.385755] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.391935] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[    0.404366] io scheduler noop registered
[    0.408533] io scheduler deadline registered (default)
[    0.414072] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[    0.421109] console [ttyS0] disabled
[    0.444904] serial8250.0: ttyS0 at MMIO 0x18020000 (irq = 11, base_baud = 1562500) is a 16550A
[    0.454000] console [ttyS0] enabled
[    0.454000] console [ttyS0] enabled
[    0.461551] bootconsole [early0] disabled
[    0.461551] bootconsole [early0] disabled
[    0.472190] m25p80 spi0.0: found w25q128, expected m25p80
[    0.477821] m25p80 spi0.0: w25q128 (16384 Kbytes)
[    0.482715] 9 cmdlinepart partitions found on MTD device spi0.0
[    0.488837] Creating 9 MTD partitions on "spi0.0":
[    0.493795] 0x000000000000-0x000000020000 : "u-boot"
[    0.500686] 0x000000020000-0x0000001a0000 : "kernel"
[    0.507078] 0x0000001a0000-0x000000f50000 : "rootfs"
[    0.513443] mtd: device 2 (rootfs) set to be root filesystem
[    0.519384] 1 squashfs-split partitions found on MTD device rootfs
[    0.525779] 0x000000720000-0x000000f50000 : "rootfs_data"
[    0.532583] 0x000000f50000-0x000000f70000 : "product-info"
[    0.539555] 0x000000f70000-0x000000fc0000 : "config"
[    0.545932] 0x000000fc0000-0x000000fd0000 : "partition-table"
[    0.553126] 0x000000fd0000-0x000000ff0000 : "logs"
[    0.559529] 0x000000ff0000-0x000001000000 : "ART"
[    0.565632] 0x000000020000-0x000000f50000 : "firmware"
[    0.590275] libphy: ag71xx_mdio: probed
[    1.161181] ag71xx ag71xx.0: connected to PHY at ag71xx-mdio.0:00 [uid=004dd036, driver=Generic PHY]
[    1.171275] eth0: Atheros AG71xx at 0xb9000000, irq 4, mode:SGMII
[    1.179415] NET: Registered protocol family 10
[    1.187543] NET: Registered protocol family 17
[    1.192218] bridge: automatic filtering via arp/ip/ip6tables has been deprecated. Update your scripts to load br_netfilter if you need this.
[    1.205253] 8021q: 802.1Q VLAN Support v1.8
[    1.216516] VFS: Mounted root (squashfs filesystem) readonly on device 31:2.
[    1.224871] Freeing unused kernel memory: 192K (803d0000 - 80400000)
Error relocating /etc/preinit: __extendsfdf2: symbol not found
Error relocating /etc/preinit: __fixunsdfsi: symbol not found
[    2.115317] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00007f00
[    2.115317]
[    2.124758] Rebooting in 1 seconds..

Unlikely that you rebooting would be related to that line, which just warns about firewall/netfilter capabilities & settings.

More likely it is related to these lines below, as it seems that there are gcc related linking problems:

Have you fetched fresh sources?
And you have built the toolchain from scratch?
And you are building a vanilla build with no special config options?

Have you already built a firmware successfully on that buildhost? (e.g. a LEDE master snapshot)

Hello and thanks for your reply. I trying to install and build from scratch and not from master branch but from final lede-17.01 one.

I copied the branch, made some adjustments in config (luci packages, and so) and applying Fast Patch (https://github.com/gwlim/mips24k-ar71xx-lede-patch)

After that, just make the source and get that error at boot.

And yes, i builded before directly from master and has been worked. Sure, without FE.

FastPath is likely the reason for your problems. gwlim's implementation is not quite clean/simple as it modifles quite a lot of unrelated other stuff (and clones extra repo from CodeAurora etc.) like shown in https://github.com/gwlim/mips24k-ar71xx-lede-patch/blob/lede-17.01/patch_LEDE.sh

I`ll try now to recompile from scratch without Fast Path to see if it was from that package.

Update 1: Without Fast Path its workin. Now ill try to reinclude it and see if can write the bin.

Maybe you should try the cleaned up patch by @dissent1

Final version is here Qualcomm Fast Path For LEDE

thanks @dissent1 . Can you explain how can i install it?

Seriously why are you taking the mips24kc branch when your CPU is mips74kc?
WR1043NDv4_IS_NOT_MIPS24KC!
My mips24kc is NOT SUPPOSED to be used on mips74kc CPU.
I don't hesitate to brick all other architecture to squeeze more performance out of that architecture
My patchset is not just an FE patch set it is a patchset I tested repeatedly to improve the performance for a particular CPU architecture, instead of having a working patchset that gives average performance for all architecture

@gwlim Ok, my mistake ! You have in plan to release a patch for mips74kc cpu ?
I guess https://github.com/gwlim/mips74k-ar71xx-lede-patch this one is not for mips74kc ?

It is already there look carefully

Ok so mips74k is even for mips74kc

Yes that is correct don't take 24kc.
Although my mips74kc has a final mip24kc tag, it is still build for 74kc
see -march=74kc
I also removed all the ar71xx packed patches in LEDE which absolutely destroy performance on 74kc
If you keep the ar71xx packed align patches mips74kc suffers
If you delete the ar71xx packed align patches mips24kc suffers
Therefore they have to be separate
mips74kc is a mips74k core

After ./patch_LEDE.sh

Hunk #1 succeeded at 20 with fuzz 1.
Hunk #2 FAILED at 218.
Hunk #5 succeeded at 272 (offset 1 line).
Hunk #6 FAILED at 281.
Hunk #7 succeeded at 313 (offset 2 lines).
Hunk #8 succeeded at 325 (offset 2 lines).
Hunk #9 succeeded at 333 with fuzz 2.
Hunk #10 succeeded at 373 with fuzz 1 (offset -1 lines).
Hunk #11 succeeded at 393 (offset -1 lines).
Hunk #12 succeeded at 401 (offset -1 lines).
Hunk #13 FAILED at 416.
Hunk #14 succeeded at 429 (offset -4 lines).
3 out of 14 hunks FAILED -- saving rejects to file target/linux/ar71xx/config-4.4.rej

git clone -b lede-17.01 https://github.com/gwlim/mips74k-lede-patch.git
You have to take the stable branch default is master branch but maintaining trunk is too much work

This is how i've do. Should be a clean copy of lede? Before i`ll installing your patch?

Yes it has to be clean copy.
Because I can patch then go grab a drink while it builds.
Time saver compared to keeping a git repo on my harddisk looking at all those files
When I am done I just delete the whole thing
When I need it I just clone again isn't that convenient?
This is a awesome 1 liner
rm -rf lede && git clone -b lede-17.01 https://github.com/lede-project/source.git lede && git clone -b lede-17.01 https://github.com/gwlim/mips74k-lede-patch.git temp; mv temp/* lede/; rm -rf temp && cd lede && ./patch_LEDE.sh

After that make menuconfig select the fast-classifier default target etc after that if you are happy
then make
Go eat drink whatever come back when it is done.
After getting your firmware delete the whole thing
If want it even faster don't delete the dl folder keep it cache it somewhere on your harddisk and put a softlink to it.
When you build just copy the softlink to it.
You can do make -j 8, - j10 whatever if your cpu is beefy enough you can build architecture optimized firmware within 30 mins

1 Like

Yes. Thanks for short command. I`ll recompile it from scratch.

@gwlim another question, please. How did you find tp-link 1043ND v4 has cpu mips74kc?

As i see on: https://lede-project.org/toh/hwdata/tp-link/tp-link_tl-wr1043nd_v4 it is Package architecture: mips_24kc

I asked you this because after i`ll finished to build image, i trying to flash and get error:

Error code: 18001
Upgrade unsuccessfully because the length of the upgraded file is incorrect. Please check the file name.

Anyway, i builded again from scratch without any other settings and it worked fine with mips74kc patch !

Thanks for patient.

Please mind that Package architecture may be different from what is listed in the ToH as (Sub-)Instruction Set.
Different CPUs/SoCs with different architectures / Instructionssets can share the same package architecture.

https://lede-project.org/toh/views/toh_dev_arch-target-cpu?datasrt=version&dataflt[Model*~]=TL-WR1043

1 Like