OpenWrt Forum Archive

Topic: Add support for Linksys E1000 v1 (and brcm4716)

The content of this topic has been archived between 8 Feb 2018 and 2 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

For flash ID 0x15 on the RT-N12, I needed a patch: https://dev.openwrt.org/ticket/7586#comment:2

I haven't synced code in a while, so I can't be sure that's still an issue, but it's worth checking.

cuviper wrote:

For flash ID 0x15 on the RT-N12, I needed a patch: https://dev.openwrt.org/ticket/7586#comment:2

I haven't synced code in a while, so I can't be sure that's still an issue, but it's worth checking.

Thanks! The patch for the serial flash is now in trunk, and it works for me.

Therefore I was able to finally test out the bgmac patch by Zajec, and thank G-d it works!

So now the wired networking is working!!!

Thanks Zajec and everyone else for your assistance!

(Last edited by hhm1 on 30 Dec 2012, 11:40)

The wireless and wired is working now. They are not currently on by default, though. Currently, a firmware image needs to be built, using the source code, with the following modifications...


The wired networking needs the bgmac driver to be enabled in order to function at all:

make menuconfig - Kernel modules -> Network devices -> kmod-bgmac - y(es).

The wireless networking works by default, however a patch is currently needed in order for the wired and wireless networking to work at the same time:

patch -p1 < patch-file-name]

(Last edited by hhm1 on 15 Jan 2013, 07:10)

hhm1 wrote:

The wireless and wired is working now. They are not currently on by default, though. Currently, a firmware image needs to be built, using the source code, with the following modifications...

I'm coming here from DD-WRT and wanting something more customizable, so it's nice to see this is working. Am I correct in assuming that if the E1000 works, the WRT160Nv3 (same hardware) should also work? If so I'm willing to help test this, I'm new to OpenWRT but I have some C, C++ and Ruby programming experience and I already have the Buildroot installed on my machine (Ubuntu 12.10 64-bit).

Other than enabling kmod-bgmac and applying the patch, is there anything special I need to do to the config (assuming I'm starting with the config.brcm47xx_generic from the most recent Attitude Adjustment build)?

stevenh512 wrote:
hhm1 wrote:

The wireless and wired is working now. They are not currently on by default, though. Currently, a firmware image needs to be built, using the source code, with the following modifications...

I'm coming here from DD-WRT and wanting something more customizable, so it's nice to see this is working. Am I correct in assuming that if the E1000 works, the WRT160Nv3 (same hardware) should also work? If so I'm willing to help test this, I'm new to OpenWRT but I have some C, C++ and Ruby programming experience and I already have the Buildroot installed on my machine (Ubuntu 12.10 64-bit).

My guess is yes, but I really do not know for certain. Seeing how different their firmware images are might tell more; the sources are available here; the E1000 source is not currently up, there is a link to a request form there though, and they responded for me pretty fast (for sources for E1000 and M10).

I would say that if you think you can access the serial console if needed, just in case of bricking, you probably can upload it without worries.
(That is how I started soldering; I first learnt soldering on my E1000, when taping the wires was not working. Then the Arduino Uno becomes my usb-to-serial adapter; wrote a tutorial here)

I think it will work; the main thing as far as I know, that could stop it, would be the bootloader (comparing 160N bootlogs and e1000 bootlogs might give useful info); I think the bootloaders are at least somewhat similar. Uploading the image from DD-WRT might be better than uploading it from stock firmware, though. (I sometimes uploaded it from dd-wrt and sometimes via serial/TFTP)

stevenh512 wrote:

Other than enabling kmod-bgmac and applying the patch, is there anything special I need to do to the config (assuming I'm starting with the config.brcm47xx_generic from the most recent Attitude Adjustment build)?

I use the svn trunk, attitude adjustment might be too old; the bgmac driver was released after AArc1. As far as the config: as far as I know, that should be all that is needed.

(Last edited by hhm1 on 16 Jan 2013, 08:47)

hhm1 wrote:

I would say that if you think you can access the serial console if needed, just in case of bricking, you probably can upload it without worries.
(That is how I started soldering; I first learnt soldering on my E1000, when taping the wires was not working. Then the Arduino Uno becomes my usb-to-serial adapter; wrote a tutorial here)

I've already done some soldering on this router (external antenna mod) and I have an old Arduino around here somewhere, so I'll have to try that and see if I can get a serial console. I was planning on opening this router at least one more time to add a fan anyway.

hhm1 wrote:

I use the svn trunk, attitude adjustment might be too old; the bgmac driver was released after AArc1. As far as the config: as far as I know, that should be all that is needed.

I have the buildroot installed from svn trunk, just used the BCM47xx config from Attitude Adjustment as a starting point so I wouldn't have to adjust too many settings to get a build that should work. I'm compiling now, as soon as I'm done with that I'll see if I can get a serial console so I can test this.

Just a small update. After having to diagnose and fix a couple compile errors I've managed to get OpenWRT trunk to compile with the right settings and patch. Unfortunately my good soldering iron is missing (the one I can find has a ruined tip) and I'm afraid to try to flash this without a serial console or JTAG to recover a brick. Judging by what I've read on the DD-WRT forums, though, I'm thinking it should probably work with a WRT160Nv3 because the hardware is exactly the same and there's even a procedure for replacing the CFE bootloader to turn a 160Nv3 into an E1000v1.

I'll let you know if I manage to find my good soldering iron (or if I just get brave enough to try flashing it anyway lol).

(Last edited by stevenh512 on 20 Jan 2013, 23:47)

stevenh512 wrote:

Just a small update. After having to diagnose and fix a couple compile errors I've managed to get OpenWRT trunk to compile with the right settings and patch. Unfortunately my good soldering iron is missing (the one I can find has a ruined tip) and I'm afraid to try to flash this without a serial console or JTAG to recover a brick. Judging by what I've read on the DD-WRT forums, though, I'm thinking it should probably work with a WRT160Nv3 because the hardware is exactly the same and there's even a procedure for replacing the CFE bootloader to turn a 160Nv3 into an E1000v1.

I'll let you know if I manage to find my good soldering iron (or if I just get brave enough to try flashing it anyway lol).

Yes, please keep us informed. I've been wanting to run a uMurmur server on my WRT160Nv3, but I can't get it to work just right with DD-WRT or TomatoUSB (so far). It looks relatively easy to do with OpenWRT, though-- installing the firmware appears to be the hard part.

harmon58 wrote:
stevenh512 wrote:

Just a small update. After having to diagnose and fix a couple compile errors I've managed to get OpenWRT trunk to compile with the right settings and patch. Unfortunately my good soldering iron is missing (the one I can find has a ruined tip) and I'm afraid to try to flash this without a serial console or JTAG to recover a brick. Judging by what I've read on the DD-WRT forums, though, I'm thinking it should probably work with a WRT160Nv3 because the hardware is exactly the same and there's even a procedure for replacing the CFE bootloader to turn a 160Nv3 into an E1000v1.

I'll let you know if I manage to find my good soldering iron (or if I just get brave enough to try flashing it anyway lol).

Yes, please keep us informed. I've been wanting to run a uMurmur server on my WRT160Nv3, but I can't get it to work just right with DD-WRT or TomatoUSB (so far). It looks relatively easy to do with OpenWRT, though-- installing the firmware appears to be the hard part.

Actually, if you could send me the firmware, I'd beta test it for you. I don't currently have a working Linux installation (my old Ubuntu partition won't boot properly anymore and I haven't gotten around to troubleshooting it), so I have been unable to compile anything myself. I haven't done anything with the serial connection because I haven't a 3.3V adapter-- and if I'm going to buy one of those, I'd be better off buying a fully-supported router instead.

After two weeks of messing with this router, it would be great to finish this project. My wife would be overjoyed whether I was successful or completely bricked it, as long as it was over. She gets a little frustrated when I fix the unbroken, especially when I could be playing video games with her instead.

I just really want to run a server for Mumble on something besides my old laptop. It drinks a taller glass of watts than a router would, and I could be using it for other things. And it's about time this ol' router started pulling its weight. Or being a paperweight. Whichever.

harmon58 wrote:

Actually, if you could send me the firmware, I'd beta test it for you. I don't currently have a working Linux installation (my old Ubuntu partition won't boot properly anymore and I haven't gotten around to troubleshooting it), so I have been unable to compile anything myself. I haven't done anything with the serial connection because I haven't a 3.3V adapter-- and if I'm going to buy one of those, I'd be better off buying a fully-supported router instead.

Since my hands aren't as steady as they used to be, the serial interface (using an Arduino instead of a 3.3v adapter) was much harder than I expected and I ended up accidentally lifting the tx pad off the circuit board (OOPS!). In comparison, enabling JTAG was much easier, I just had to bridge a few missing SMT resistors on the board and install the pins. Cannibalized an ancient 20mb hard drive for the pins I needed and the 100ohm resistors for my own JTAG adapter.

I'm recompiling now, once it's done I'll try it out here and put it in my public folder on Dropbox for anyone else who wants to try it. I'll be testing it on a WRT160Nv3 with the stock 160N CFE and the E1000 CFE to see if there are any differences.

hhm1 wrote:

The wireless and wired is working now. They are not currently on by default, though. Currently, a firmware image needs to be built, using the source code, with the following modifications...


The wired networking needs the bgmac driver to be enabled in order to function at all:

make menuconfig - Kernel modules -> Network devices -> kmod-bgmac - y(es).

The wireless networking works by default, however a patch is currently needed in order for the wired and wireless networking to work at the same time:

patch -p1 < patch-file-name]

I am pretty sure that the only thing which needs to be done now is the second thing (applying the patch), since it looks like bgmac is included in the default profile now.

This means that wired networking should work out-of-the box now, but I have not tested this yet.

Will this patch and or builds also working on the e3200 version? it use also the new bgmac drivers.

I can confirm that the trunk works on my WRT160Nv3. After some initial configuration confusion, it's working perfectly.

Unfortunately it didn't work for me on a 160Nv3 with E1000v1 CFE, I bricked my router 3 times before finally just tftp flashing DD-WRT back onto it.. I might give this a try later with a new trunk build but for now I'm just happy to have it working again (and a working serial console too, almost needed a microscope to solder to that broken trace lol).

Unfortunately it didn't work for me on a 160Nv3 with E1000v1 CFE, I bricked my router 3 times before finally just tftp flashing DD-WRT back onto it.. I might give this a try later with a new trunk build but for now I'm just happy to have it working again (and a working serial console too, almost needed a microscope to solder to that broken trace lol).

Providing a dmesg from "bricked" router will definitely help in fixing the bug you were affected by.

This firmware isn't what bricked my router, the problem I had was the exact same problem the patch earlier in this thread is supposed to fix. Every time I'd configure wifi and turn it on, I'd lose the wired switch and had to boot into failsafe mode. The bricking actually happened while trying to revert to DD-WRT or stock Linksys firmware so I could get online while I recompiled. smile

Looking at the patch (and knowing that it was correctly applied and didn't work for me) I wonder if the chip_id is different. The patch is looking for chip_id 47612 and I have no idea how to find the chip_id for my router, didn't see it in dmesg or /proc/cpuinfo but /proc/cpuinfo does say "Broadcom BCM4716 chip rev 1" so I'm wondering if I should be looking for chip_id 47611 instead (maybe the E1000 and later 160Nv3 models use a rev 2 CPU?). I really doubt the GPIO is different since it worked for harmon58 but I wouldn't be surprised to find out my router has an older revision of the CPU than the E1000 does.

Edit: I think I may have found my problem. The patch hhm1 posted earlier in this thread is applied to my buildroot and the file package/mac80211/patches/916-b43-gpio_init-maskset.patch is there (and correct), but somehow this patch was never applied to the kernel source. I applied the patch manually and I'm recompiling now, so we'll see soon enough.

(Last edited by stevenh512 on 3 Feb 2013, 12:14)

I've got a wrt160Nv3 and I want to get openwrt on it.  I currently have dd-wrt on it because they had an easier install procedure, but it is not working well for me in trying to turn the device into a wireless repeater, keeps dropping out...

Is it still necessary to build my own firmware using the patch outlined above?  I've never built one before...

Does anyone have a ready made one they could send me?  I do need to have both wired and wireless functionality, so I'm hoping that is working well now.  Seems like it is....

mikeybs wrote:

I've got a wrt160Nv3 and I want to get openwrt on it.  I currently have dd-wrt on it because they had an easier install procedure, but it is not working well for me in trying to turn the device into a wireless repeater, keeps dropping out...

Is it still necessary to build my own firmware using the patch outlined above?  I've never built one before...

Does anyone have a ready made one they could send me?  I do need to have both wired and wireless functionality, so I'm hoping that is working well now.  Seems like it is....

I have not tested building from trunk, without the patch, recently, since the device has been

in use

often. The ticket for the bug and the patch was accepted and assigned to be fixed, but currently, it is not yet fixed/closed. It could be that the bug was fixed, though, and the ticket was not updated yet, for example, if it was fixed upstream.

I have a firmware build with the patch, that has been working for me; you can message me with your e-mail address in my forum user page, and then I can email it to you, if you would like.

Which binary image do I need to install OpenWrt on a WRT160N v3?

Currently using dd-wrt, but have a lot of radio-drops.

wvdakker wrote:

Which binary image do I need to install OpenWrt on a WRT160N v3?

Currently using dd-wrt, but have a lot of radio-drops.

A .bin file is available for download now at trunk snapshots. This, as far as I know, shows that it will also be built in forthcoming releases.

It is being built since just a few days after you posted! :-)


UPDATE: NOTICE! IMPORTANT!!!

(Last edited by hhm1 on 10 Apr 2013, 07:59)

hhm1 wrote:

A .bin file is available for download now at trunk snapshots. This, as far as I know, shows that it will also be built in forthcoming releases.

Thx!
Will try it.

wvdakker wrote:
hhm1 wrote:

A .bin file is available for download now at trunk snapshots. This, as far as I know, shows that it will also be built in forthcoming releases.

Thx!
Will try it.

I made a mistake!
The led issue likely has yet to be fixed in trunk, requiring a patch to work; havent tested recently, though, so maybe it is fixed.

So I would NOT suggest using trunk, until this issue is fixed; instead I think it would be wise to build with the patch, and use the e1000v1/wrt160nv3/etc .bin image from the building.

(Last edited by hhm1 on 10 Apr 2013, 07:58)

hhm1 wrote:

So I would NOT suggest using trunk, until this issue is fixed; instead I think it would be wise to build with the patch, and use the e1000v1/wrt160nv3/etc .bin image from the building.

Thanks for the suggestion.
First I have to debrick my e3200 router, before I can mess up this one big_smile

Looks like the patch is in the trunk now.

Will give it a try today.

Keep you posted.

wvdakker wrote:

Looks like the patch is in the trunk now.

Will give it a try today.

Keep you posted.

Yup, noticed it too.

The trunk snapshots weren't up to date when I tested them though (about 9 hours after the patch was commited; I guess the snapshots take time to update). So I built it from trunk myself.

So I tested it with a trunk build from source code, and it works for me, thank G-d!

Hope it works for everyone else well too.

:-)

(Last edited by hhm1 on 29 Apr 2013, 10:20)