Build for Linksys EA9500


#63

Thanks! Will try to use this in the next build.


#64

Thanks for all the work.
Question will the EA9500 part of the supported device list and part of the stable release build at one time? What needs to happen for it to be totally integrated into the LEDE project?

Keep up the good work!


#65

The new Linksys routers have two copies of firmware stored in separate partitions. At present this is not completely supported.

The support has been added in kernel to parse these partitions. Now, it needs to be seen when will that be utilized by Openwrt.


#66

What release did you use to compile the firmware? I don't see a patch for the EA9500 in the current kernel.
I see you patches for 4.4 and 4.9

target/linux/bcm53xx/patches-4.4/047-0005-ARM-dts-BCM5301X-Add-basic-DT-for-Linksys-EA9500.patch
Showing the top two matches Last indexed 19 days ago
4	Subject: [PATCH] ARM: dts: BCM5301X: Add basic DT for Linksys EA9500
5	MIME-Version: 1.0
6	Content-Type: text/plain; charset=UTF-8
…	
46	+	compatible = "linksys,panamera", "brcm,bcm47094", "brcm,bcm4708";
47	+	model = "Linksys EA9500";
48	+
49	+	chosen {
50	+		bootargs = "console=ttyS0,115200";
Diff target/linux/bcm53xx/patches-4.9/033-0005-ARM-dts-BCM5301X-Add-basic-DT-for-Linksys-EA9500.patch
Showing the top two matches Last indexed 19 days ago
4	Subject: [PATCH] ARM: dts: BCM5301X: Add basic DT for Linksys EA9500
5	MIME-Version: 1.0
6	Content-Type: text/plain; charset=UTF-8
…	
46	+	compatible = "linksys,panamera", "brcm,bcm47094", "brcm,bcm4708";
47	+	model = "Linksys EA9500";
48	+
49	+	chosen {
50	+		bootargs = "console=ttyS0,115200";
Makefile

Do I have to load the
git checkout v17.01.4
to compile the firmware and packages for the EA9500

Thanks for the help


#67

My patches have not made it to mainline yet. I use trunk for building these builds.

The patches I mentioned were for the dual partition parsing. These were developed by @rmilecki

HTH


#68

Hi npcomplete

Can you help me on this? I'm trying to have the dual boot in the web interface as the EA8500 already has it.

Thanks

I hear you wrote a patch to support EA9500 dual partitions setup. Can you help me add support for EA9500 in luci-app-advanced-reboot (https://github.com/stangri/openwrt-luci/blob/luci-app-advanced-reboot/applications/luci-app-advanced-reboot/luasrc/controller/advanced_reboot.lua)?

I need to know shell commands/parameters to switch boot partition and which partitions and offsets to use to read the kernel information for images stored on either of dual partitions.

Thanks!


#69

You can switch partitions using this -

nvram set bootpartition=0 && nvram set partialboots=0 && nvram commit

bootpartition can be 0 or 1

You can see the partitions on LEDE for yourself - firmware is the first partition while failsafe is the second.

root@OpenWrt:/# cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00080000 00020000 "boot"
mtd1: 00100000 00020000 "nvram"
mtd2: 00080000 00020000 "nvram"
mtd3: 01d00000 00020000 "firmware"
mtd4: 003fffe4 00020000 "linux"
mtd5: 01900000 00020000 "ubi"
mtd6: 06100000 00020000 "failsafe"

Also, make sure to edit /etc/rc.local file where I force the bootpartition to 0


#70

Compiling the firmware image.

I have been googling for couple of days and trying to figure out what I'm doing wrong.
I also have a EA8500 and was able to compile it and install it on my device.
Where my problem seems to be is applying the EA9500 patches the right way

I did:
git clone https://git.lede-project.org/source.git lede
cd lede
./scripts/feeds update -a
./scripts/feeds install -a
To get the source tree.

with the EA8500 all I had to do is

make menuconfig

What are the commands to get the patches applied so that I have the EA9500 in the compilation menu so I can select it?

I'm probably missing something simple, but I read in the forums and documentation and tried all kinds of ways without success.

Do I need to load a certain stage of the source? As there is no patch for the latest kernel? I tried that too to load the 17.01.3 Version of the source

git fetch --tags
git tag -l
git checkout v17.01.3

Thanks


#71

Before make menuconfig you can apply patch using patch -p1 < Add-support-for-ea9500-using-DSA-driver.patch

Also, as I mentioned earlier I'm using trunk to build, so no need to switch to any particular tag.


#72

Thanks. Downloaded your patch and ran the command

patch -p1 < Add-support-for-ea9500-using-DSA-driver.patch

Perfect I was able to compile the firmware.

One question before I upload it to the router. Will the /lib/firmware/brcfmac/4366c.bin be included in the build, or do I have to make a copy of it and transfer it after reboot.
If yes will I be able to connect over ethernet to it when I reboot the firmware before I copy the firmware back?

Just wanted to assure.

Thanks


#73

Just extract this to your source root (next to target folder) then rebuild. You will also need to enable ip-bridge and ip-full packages. Cheers!


#74

Tanks for all the help -- I got it compiled and rebooted to my firmware.

Thanks for the help.

Now I need to see what else I need to do
Wifi is not working yet, but I think i need to work on it.


#75

Good morning @npcomplete
Would you share with me you .config file from your December build?

Thanks


#76

.config is now uploaded and link is in this thread's opening post.


#77

Thanks
I compiled it and loaded it into the router

one thing that I thought was interesting is I used the following command to change the boot partition

nvram set bootpartition=1 && nvram set partialboots=0 && nvram commit

And it changed back to the linksys firmware. I thought I flashed both partitions.
Is this normal?

CFE> flash -noheader 192.168.1.10:/ea9500.trx nflash0.trx
CFE> flash -noheader 192.168.1.10:/ea9500.trx nflash1.trx

I also have not gotten wifi to work. Is there anything I have to do special?

Thanks


#78

nflash0.trx and nflash1.trx point to same partition. nflash0.trx2 and nflash1.trx2 points to the second partition.

This might be purely for compatibility.

Regarding WiFi break, I think it is a genuine bug. I've tried it as well and I get the same thing.
It most likely has to do with pcie.


#79

Thanks for the answer.

So if I do

CFE> flash -noheader 192.168.1.10:/ea9500.trx nflash2.trx

It will flash the other partition and I can have LEDE on both and just switch.

Basically keep one stable and the other one for trials.

Thanks


#80

Let me add some correction to my yesterday's reply. This is what the CFE sees:

CFE> show devices
Device Name          Description
-------------------  ---------------------------------------------------------
uart0                NS16550 UART at 0x18000300
uart1                NS16550 UART at 0x18000400
nflash0              Toshiba NAND flash size 131072KB
nflash0.boot         Toshiba NAND flash offset 0 size 512KB
nflash0.nvram        Toshiba NAND flash offset 80000 size 1024KB
nflash0.devinfo      Toshiba NAND flash offset 180000 size 512KB
nflash0.trx          Toshiba NAND flash offset 200000 size 1KB
nflash0.os           Toshiba NAND flash offset 20001C size 29696KB
nflash0.trx2         Toshiba NAND flash offset 1F00000 size 1KB
nflash0.os2          Toshiba NAND flash offset 1F0001C size 29696KB
nflash1.boot         Toshiba NAND flash offset 0 size 512KB
nflash1.nvram        Toshiba NAND flash offset 80000 size 1024KB
nflash1.devinfo      Toshiba NAND flash offset 180000 size 512KB
nflash1.trx          Toshiba NAND flash offset 200000 size 29696KB
nflash1.trx2         Toshiba NAND flash offset 1F00000 size 29696KB
nflash1.brcmnand     Toshiba NAND flash offset 3C00000 size 69632KB

So, nflash0.trx and nflash1.trx point to first partition.
While, nflash0.trx2 and nflash1.trx2 points to second partition.


#81

Thanks for the update
I did not try it yet.

I have one more question. Your build is around 16MB. I used your .config and my build ends up being only 7.5MB. Any idea what I'm missing?

Thanks


#82

You probably forgot to update and install feeds.