OpenWrt Forum Archive

Topic: Openwrt build compatibility Routers + versions

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

I have about 25 routers; mostly linksys wrt54G* and i am planing to do a big firmware change to openwrt backfire 10.03.1 however having checked the documentation and supported hardware i have one doubt about the builds and their versions.

My current routers are:
Wrt54G v2, Wrt54G v1.1, Wrt54GL v1.1, Wrt,54G v4, Wrt54GS v2, Wrt54G RG v2, Wrt54g v2.2

also : Linksys WRT150N v1.1, Linksys WRT300N v1

and Asus WL500 premium v1 and v2, Asus WL-520GU

While all these models seem to be supported by openwrt, i see that the build status version is not 10.03 for all. For example for the wrt54g* the status is 0.9 and my question is if these routers are ONLY supported by 0.9 and not newer builds or it means that they are supported from 0.9 and up which includes the latest backfire.

I am asking just to be sure and avoid doing mass router bricking.
I also have doubts about the 2 linksys N. 150 and 300. Any stable success at the moment ?

Protip: there's a Legend at the top of the page ansering your question:

* The Status column contains the first OpenWrt version that fully supported the given model, unless otherwise stated it should apply to all subsequent releases. In doubt, consult the model specific article.

Thank you very much for your time and answer.

If i may; i have another question somewhat related to the topic. I intend to run a B.a.t.m.a.n-adv ad-hoc mesh and while i thought that i could run batman-adv with backfire kernel builds 2.4 i was recently told that i cannot as batman-adv is for 2.6 kernels and it seems to be confirmed by the fact that i don't find the package available under 2.5 kernel.

Can you confirm that this package only works for 2.6 and there will not be a 2.4 package ?

I also tried 2.6 kernel trunk for some routers such as wrt300n v1 upgrading from 2.4 kernel  10.03.1. In the case of wrt300n v1 i was not able to access luci. I could ping the router sometimes; other times i was not and had to reflash on recovery mode.
I also had to play with .bin and .trx builds as some would work for flash in one way and another would not.

Before i get into production with 25 routers i thought about replicate the hardware environment with virtualbox openwrt x86 vdi image and a wireless pci broadcom chip with a couple computers. Do you think it is a valid idea from the technical point of view to test 2.6 kernels and batman-adv ? (It's is also intended to train and tech a few new people in my project.)

I thought I would give you some feedback before you go to all that work.  I just installed OpenWrt Backfire 10.03.1 brcm47xx on a WRT54GL v1.1 (prebuilt image) yesterday, and am having trouble.  The flash went flawlessy (web flash from an old version of DD-WRT), but I am having stability issues.  UCI config changes persist after reboots, but the downloaded package list will not persist after reboot, nor have I been able to install any packages via Luci, or opkg (at the command line).

I read somewhere about the 4mb flash being just a touch too small for 10.03.1, but I am just starting to do my research/troubleshoot, so I don't know if that's the issue, or there is something I may have done wrong in the filesystem.

I am interested in following how you make out with all your upgrades, as I also have a couple Asus WL520GU to upgrade as well (they too have 4mb flash).  The routers are all for home-office use.

Here is the answer:
http://wiki.openwrt.org/toh/linksys/wrt54g

The Linksys WRT54G ver. 1.1 hardware (4 MB of flash) has trouble with OpenWrt 10.03.1-rc6 and maybe all 10.03 releases as of 2011-12-08. In a test with OpenWrt 10.03.1-rc6, the OS will install but LuCI will be unable to update settings because there isn't enough flash left free.

This makes me consider an openwrt  built without a luci or maybe luci without features that we don't really need.

I am now thinking about building my own specific firmware package. One reason is because of what i stated above and the observed problems.

I would like to get my freifunk network working with a 2.6 kernel and batman-adv. I have all the hardware and it is ready except the firmware but i have a few questions to make sure my time will not be unproductive.

I would also like to build one firmware image only for all the chips i use and will use.
This may help reduce the size of the firmware as well as the removal of Luci and httpd; possibly even other unneeded packages.

I would like to know if can can do all this without problems. If it is possible and from which source i should start trunk ? or backfire 10.03.1 ?
One firmware  for all my hardware is my goal. Driver support for specific used chips. No luci + httpd plus batman-adv build in.

The chips are:

  • Linksys WRT54G v1 - Broadcom BCM4712 chip rev 1
    Linksys WRT54G v1.1 -  Broadcom BCM4710 chip rev 0
    Linksys WRT54G v2 - Broadcom BCM4712 chip rev 1
    Linksys WRT54G V2.2 - Broadcom BCM4712 chip rev 1
    Linksys WRT54G v3 - Broadcom BCM4712 chip rev 1
    Linksys WRT54G v4 - Broadcom BCM5352 chip rev 0

    Linksys WRT54GL v1.1 - Broadcom BCM5352 chip rev 0

    Buffalo WHR-G54S - Broadcom BCM5352 chip rev 0

    Asus WL-520GU/GC - Broadcom BCM5354 chip rev 3
    Asus WL-500g Premium gpv1 - Broadcom BCM4704 chip rev 9
    Asus WL-500G Premium V2 - Broadcom BCM5354 chip rev 2


    Linksys WRT150N v1.1 - Broadcom BCM4704 chip rev 9
    Linksys WRT300N v1 - Broadcom BCM4704 chip rev 9


BCM4704 chip rev 9
BCM4710 chip rev 0
BCM4712 chip rev 1

BCM5352 chip rev 0
BCM5354 chip rev 3

If i am not mistaken everything falls under BCRM 47XX; however i inquire why on the downloads we have builds for  wrt54g wrt54gs and wrt54gsv4.

If my idea of building one master firmware for all routers because the N models and asus; i will be ok with that since i will have the possibility of exchanging them.

I found the docs for kamikaze but not for backfire. Will they also work ?

(Last edited by HeXiLeD on 22 Feb 2012, 23:03)

I too am now considering building my own firmwares.  I've only had about 30 minutes to spend studying the imagebuilder, and I think I'm no where near ready to try building my own firmwares.  I've been looking for an ncurses interface.  Have you found one?

I like your idea of building one firmware for ALL of your routers.  I'm no expert, but I think the differences in the prebuilt firmwares lies in the options firmwares may be built with (USB support for wrt54g vs asus WL520) and possibly the builds for router with 8mb+ flash may have more packages built in.

For myself, I think I'm going to finish trying to understand the filesystem before I start tying to build my own firmwares.

I have found that packages installed via opkg (command line) are starting to persist across reboots though

It is quite simple to build a firmware:
http://wiki.openwrt.org/doc/howto/build
http://wiki.openwrt.org/doc/howto/buildroot.exigence
http://wiki.openwrt.org/doc/howto/obtai … e.generate


I'm no expert, but I think the differences in the prebuilt firmwares lies in the options firmwares may be built with (USB support for wrt54g vs asus WL520) and possibly the builds for router with 8mb+ flash may have more packages built in.

It seems you are correct.  When compiling the firmware; we do have the option to select specific target profiles such as wrt300n v1, asus, linksys, netgear and or others rather than just brcm43xx profiles.
When doing so we are presented with specific support like this example:

CONFIG_TARGET_brcm47xx_WL500GPv1:                                                                                                                 
 Package set optimized for the WL-500g Premium v1 with USB and Atheros WiFi card support
 CONFIG_TARGET_brcm47xx_WRT350Nv1:                                                                                                                    
 Package set compatible with the Linksys WRT350Nv1. Contains USB support

VS

CONFIG_TARGET_brcm47xx_Broadcom-b43:                                                                                                                
 Package set compatible with hardware using Broadcom BCM43xx cards

Right now i am not looking into usb support. In fact i am not planing to use it. All i want is broadcom wireless stable working with batman-adv.
I also wonder if openwrt will add the opensoruce brcmsmac support that came out stable with kernel 3.2

I am am also now looking how to build the firmware as virtual-box (.vdi) image for testing since it is safer to "brick" a vdi than hardware.

As for ncurses check if what you are looking for is the libncurses package.

Let us know about your progress smile

(Last edited by HeXiLeD on 2 Mar 2012, 23:45)

Thanks HeXiLeD.

Are you using the ImageGenerator? or Buildroot?  How small have you been able to make the images?

I plan to use the ImageGenerator, but one question.  Am I correct to assume the best workflow would involve writing a custom profile, then tweaking it from there?

HeXiLeD

I have made lots of progress, and thought I would offer what I've learned to you, in hopes that it may help you, or anyone else for that matter working with brcm47xx chips with backfire 10.03.1



Looking at your list of hardware, your idea of making one image to use for most of your hardware should work, but I'm not familiar with the entire list.  For example, some Linksys WRT54G versions have less than 4MB flash, so you may have trouble there.  My experiences include only Linksys WRT54GL v1.1 and ASUS WL520GU, so I can only speak for those devices.  If you can't get ALL of your devices with one image, so you should be able to get a good deal of them at least with one image.

As far as the brcm47xx images with the 2.6 kernel, I have only been using WPA-PSK, and I've been getting uptimes so far of 1 day+, so the wireless is good, but I certainly haven't been pushing the boxes to their limits.  For your batman-adv packages, I don't know if there's still anything that you would need in the binary drivers included with the 2.4 kernel (included with the brcm-2.4 packages).  The brcm47xx packages seem to be working for me, so I think I will stay with them for now, unless I discover I need something exotic of the wireless (bridging is something I think I read that would benefit from the brrm-2.4 drivers).

I've used OpenWrt-ImageBuilder-brcm47xx-for-Linux-i686 to make the initial image, and it works really good.  I used the "make image PROFILE=Broadcom-b43".  That, with the base packages, gave a very minimalist image.  From there, there were only a few packages that I needed to remove with the "PACKAGES=" option.  By using the Broadcom-b43 profile, Luci wasn't installed either, which really kept the image size down once flashed onto the routers.  I never thought to check for you if the batman packages would install for at this point.

Once the images were created, I ended up working with the openwrt-brcm47xx-squashfs.trx image.  The reason for this is that only .trx files are supported by the sysupgrade tool (and some web-update tools), so I found this much easier than trying to get the routers into recovery mode over-and-over, then TFTP .bin files over.  I believe the difference between .trx and .bin files are the addition or removal of some header information.  Seeing that I am only using .trx file/images now, I hope someone else reading this post will point out if I'm doing something wrong.

Once you have on router flashed, and you can telnet/ssh into it, this is where you could set up asl much under /etc/config/ that would be common for all of your routers.  At the very least, set up the files to obtain an IP from DHCP (or however your manage your network).  With multiple routers, I didn't want to have every new flash with a static ip of 192.168.1.1, and thus all the work of getting into them and changing manually.

Once I had the /etc/config/ files working on one (ie network and wireless), I extracted the relevant files (scp), and went back to ImageBuilder.  Make clean in the ImageBuilder, then rebuilt the .trx images with the FILES=[the files I just extraced]

This is where I love the Sysupgrade tool on openwrt.  I scped the new .trx image over to /tmp on the next router, then ran sysupgrade -v -n  /tmp/openwrt-brcm47xx-squashfs.trx.  The -v switch is obviously for verbose, but it took me a while to catch the -n switch.  Without the -n switch, sysupgrade keeps lots of files <http://wiki.openwrt.org/doc/howto/notuc … grade.conf>, and the files you just put into the .trx image using FILES=xxx may be overwritten during the flash (but I haven't confirmed this yet).

I hope this information isn't redundant for you, and it may not be what you need right now, but in the spirit of opensource, I thought I would share with you (and anyone else) anyway.  I read somewhere that openwrt is great, as long as you don't mind reading.  This project took me a little while longer that I had allowed for it, but I'm glad I finished it.  I had considered switching back to DD-WRT a couple times, but I'm glad I found the time to follow through with Openwrt.

I have only two obstacles remaining now:

1)  Learning how to get a zImage onto a Linksys NSLU2 through Upslug2, and

2) As I want Luci (and some other packages) my main router, I have to decide whether I try to source an Asus WL500Gp (8mb) flash, or learn extroot for one Asus WL520GU with an old thumbdrive that everyone has around.  I'm sure I could learn the UCI in openwrt, but it's how much more time I'm willing to put into this project.

Drool

Your feedback is very welcome.
I have been reading and seeing some openwrt video presentations such as 22C3-1099-en-hacking openwrt.mp4 (download).

I will only be using 4MB+ flash memory routers the the Brcm47xx .trx files.
I believe you are correct regarding the difference between .trx and .bin files and their headers.

I have been using only buildroot and not the image generator. I wonder if the advantage of the image generator is more than build times.
I also prefer to use trx images to bin images for the same reasons as you stated. trx seems to work in all cases. Bin's tends to fail sometimes.

I also noticed that i can get all with one image for all my chips brcm47xx. However this will mean (if i am not mistaken) that all build will either include usb support or not even if the hardware does not have usb features. This situation causes some builds to be bigger than what is necessary. Personally USB support is something i don't really need for my project.

This :

Once I had the /etc/config/ files working on one (ie network and wireless), I extracted the relevant files (scp), and went back to ImageBuilder.  Make clean in the ImageBuilder, then rebuilt the .trx images with the FILES=[the files I just extraced]

...interests me as i intend to have my builds set with a default configuration for the network that will not require the network users to need to configure the firmware every time a router is added to the mesh. The only configuration need will be to change their own default ip. Everything else is intended to be default on the firmware.

Currently i do not plan to use encryption but will be good to know how well it is working as apossible implementation in the future.

I just got a new router (wrt54g v2.2) which i flashed with brcm47xx (2.6 kernel) and removed a couple unneeded packages related to ppp/pppoe.

I also had some problems installing packages. For example opkg search fdisk or any other *fdisk* keyword failed to display available packages.
The same problem occurred when using Luci to search but when i used luci to install fdisk; it worked.

How much space do you have on your router after flash ?

# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root                 1.9M      1.9M         0 100% /rom
tmpfs                     6.5M     56.0K      6.5M   1% /tmp
tmpfs                   512.0K         0    512.0K   0% /dev
/dev/mtdblock3          960.0K    320.0K    640.0K  33% /overlay
mini_fo:/overlay          1.9M      1.9M         0 100% /

Correct me if i am wrong but it seems only to display 2 MB flash when it should be 4MB. What am i missing here?

# lsmod
Module                  Size  Used by    Not tainted
batman_adv             85072  0
nf_nat_tftp              432  0
nf_conntrack_tftp       2400  1 nf_nat_tftp
nf_nat_irc               864  0
nf_conntrack_irc        2592  1 nf_nat_irc
nf_nat_ftp              1360  0
nf_conntrack_ftp        4896  1 nf_nat_ftp
ipt_MASQUERADE           992  1
iptable_nat             2880  1
nf_nat                 12544  5 nf_nat_tftp,nf_nat_irc,nf_nat_ftp,ipt_MASQUERADE,iptable_nat
xt_NOTRACK               672  0
iptable_raw              656  1
xt_state                 800  3
nf_conntrack_ipv4       8352  6 iptable_nat,nf_nat
nf_defrag_ipv4           608  1 nf_conntrack_ipv4
nf_conntrack           44032 12 nf_nat_tftp,nf_conntrack_tftp,nf_nat_irc,nf_conntrack_irc,nf_nat_ftp,nf_conntrack_ftp,ipt_MASQUERADE,iptable_nat,nf_nat,xt_NOTRACK,xt_state,nf_conntrack_ipv4
ipt_REJECT              1984  2
xt_TCPMSS               2720  1
ipt_LOG                 4640  0
xt_comment               464  0
xt_multiport            1904  0
xt_mac                   576  0
xt_limit                1152  1
iptable_mangle           992  1
iptable_filter           768  1
ip_tables               8864  4 iptable_nat,iptable_raw,iptable_mangle,iptable_filter
xt_tcpudp               1856  4
x_tables                9824 13 ipt_MASQUERADE,iptable_nat,xt_NOTRACK,xt_state,ipt_REJECT,xt_TCPMSS,ipt_LOG,xt_comment,xt_multiport,xt_mac,xt_limit,ip_tables,xt_tcpudp
b43legacy              95568  0
b43                   151040  0
mac80211              258368  2 b43legacy,b43
crc_ccitt                976  0
cfg80211              149024  3 b43legacy,b43,mac80211
compat                 17904  4 b43legacy,b43,mac80211,cfg80211
arc4                     816  2
aes_generic            31056  0
deflate                 1328  0
ecb                     1328  0
cbc                     2016  0
switch_robo             4208  0
switch_core             5216  1 switch_robo
diag                    7504  0
/# cat proc/cpuinfo
system type             : Broadcom BCM47XX
processor               : 0
cpu model               : Broadcom BCM3302 V0.7
BogoMIPS                : 214.52
wait instruction        : yes
microsecond timers      : yes
tlb_entries             : 32
extra interrupt vector  : yes
hardware watchpoint     : no
ASEs implemented        :
shadow register sets    : 1
core                    : 0
VCED exceptions         : not available
VCEI exceptions         : not available
# cat proc/meminfo
MemTotal:          13388 kB
MemFree:            1848 kB
Buffers:            1384 kB
Cached:             3348 kB
SwapCached:            0 kB
Active:             2608 kB
Inactive:           3072 kB
Active(anon):        196 kB
Inactive(anon):      824 kB
Active(file):       2412 kB
Inactive(file):     2248 kB
Unevictable:           0 kB
Mlocked:               0 kB
SwapTotal:             0 kB
SwapFree:              0 kB
Dirty:                 0 kB
Writeback:             0 kB
AnonPages:           960 kB
Mapped:              980 kB
Shmem:                72 kB
Slab:               3600 kB
SReclaimable:        648 kB
SUnreclaim:         2952 kB
KernelStack:         264 kB
PageTables:          180 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:        6692 kB
Committed_AS:       3236 kB
VmallocTotal:    1048372 kB
VmallocUsed:         664 kB
VmallocChunk:    1037204 kB

Hello again HeXiLeD,

I have been learning lots about openwrt as well.  I will make a more thorough reply to your post when I have a couple minutes, but I thought I would give you this for now;

I have been using Backfire 10.03.1 brcm47xx images on a wrt54gl v1.1 and an Asus WL520gu.  The wrt54gl v1.1 was had an uptime of 7 days now, passing lite web-browsing/mobile phone throughput, with wpa-psk encryption.  It works well.  However, the WL520gu will not even get passed enabling wifi without locking up. 

Although according to <http://wiki.openwrt.org/toh/asus/wl520gu>:

(Updated: In 10.03.1-rc1 (Backfire update RC1, August 2010), the b43 driver seems to work fine on the WL520GU. Hopefully this means 10.03.1 will have robust support for this router via the brcm47xx target.
Updated: as of 10.03.1-rc4 (February 2011) wifi works with brcm47xx )

I will be testing the Backfire 10.03.1 brcm-2.4 on the wl520gu, and let you know how I make out (along with some other feedback to help you). 

Which hardware have you been doing your testing on?  I would suspect you've chosen one router, and have been continually re-flashing it?

The hardware i wil be using will be this one on post 6.
Right now it will be only wrt54g* and yes at the moment i am using only one router.
I am also using  10.03.1. My concern now is the amount of free ram and flash. I have no plans to use kernel 2.4 since i really want to use batman-adv
Lets see how it all plays out. I just did my first build and will be doing a second one to test a few more things.
I am also striping the build from extra packages that may not be needed.
I have a doubt about this one.

CONFIG_PACKAGE_kmodswitch:                                                                                                                                                                     
 This package contains switch drivers for ADM6996L and BCM53XX RoboSwitc

Is this package needed for BCM53 chips or is it an extra.

(Last edited by HeXiLeD on 11 Mar 2012, 06:36)

HeXiLeD

"I also had some problems installing packages. For example opkg search fdisk or any other *fdisk* keyword failed to display available packages.
The same problem occurred when using Luci to search but when i used luci to install fdisk; it worked."

Before you run "opkg list *fdisk* (I don't know if 'search' works), you need to run "opkg update".  The updated list of packages gets cleared after a reboot.  I think this is intentional design, to keep space available on the overlay. This is what I get using 10.03.1 br47xx:

root@OpenWrt:~# opkg list *fdisk*
cfdisk - 2.13.0.1-4 - This package contains a utility for managing disk partition tables.
fdisk - 2.13.0.1-4 - This package contains a utility for managing disk partition tables.
mtd-utils-docfdisk - 20090227-1.1 - MTD docfdisk
sfdisk - 2.13.0.1-4 - This package contains a utility for managing disk partition tables using command-line only.


"How much space do you have on your router after flash ?

Code:

# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root                 1.9M      1.9M         0 100% /rom
tmpfs                     6.5M     56.0K      6.5M   1% /tmp
tmpfs                   512.0K         0    512.0K   0% /dev
/dev/mtdblock3          960.0K    320.0K    640.0K  33% /overlay
mini_fo:/overlay          1.9M      1.9M         0 100% /

Correct me if i am wrong but it seems only to display 2 MB flash when it should be 4MB. What am i missing here?"



When you read <http://wiki.openwrt.org/doc/techref/filesystems>, there are no instructions on how to easily view how much flash you are using up (using df -h), but this is what I think from working with it.

!) The two important lines to watch are the mount points of /rom (/dev/root) and /overlay (/dev/mtdblock3)

    a.  The /rom is actually the size of the image (or .bin or .trx) that you flashed to the router, which is using SquashFS.  It is read-only, and that's why /rom will always show Use% 100%.   However, the Size column will vary depending on the .trx or .bin size that you've flashed to the router.  I've had some /rom mount points vary between 1.4 MB to I (if I recall correctly) 2.4 MB.

    b.  The /overlay entry is the JFFS2 partition.  This is read-write, and this is where all changes since the initial flashing get stored.

So, the larger the .bin/.trx under /rom is, the less space will be allocated to /overlay.  I don't know the exact formula that openwrt uses to build the two filesystems, but if you add /rom and /overlay, you will come in just under 4 MB (assuming you are using 4MB flash sizes).

The Use% column under /overlay is the entry I keep an I on.  This will grow as you 'opkg update', and then add packages.  Most of my builds start off with 16% to 45%, then climb as high as 94% if I 'opkg install luci luci-app-qos' and a couple more packages (luci is one of the largest packages, while luci-app-qos is pretty big too).

I found that studying <http://wiki.openwrt.org/doc/techref/flash.layout> really helped me understand how the SquashFS and JFFS2 worked (in particular the diagram of the sample flash layout).



"I just got a new router (wrt54g v2.2) which i flashed with brcm47xx (2.6 kernel) and removed a couple unneeded packages related to ppp/pppoe."

When removing packages AFTER flashing does not save you any space, as the /rom size is still the same.  If you're concerned with space, then ppp/pppoe needs to be removed BEFORE the flashing.


Using Image Generator for Backfire 10.03.1/br47xx, in about 5 minutes, I built this image :

2.5M Mar 11 16:57 openwrt-brcm47xx-squashfs.trx

with this command:

make image PROFILE=Broadcom-b43 PACKAGES="-ppp -ppp-mod-pppoe -iptables -firewall batmand kmod-batman-adv"

I don't know anything about batman, so I am making an assumption that for your purposes you need batmand & kmod-batman-adv packages.  There is no luci, no usb support.  At 2.5 MB, that should be small enough to work comfortably on a 4MB flash-router (and that should be pretty close to the same size that will show up on the /rom entry using df -h once flashed on the router).

What I've been doing is keeping a working 'make image' command, then tweak it as I go (cut and paste).  I have all my routers pick up an IP address via DHCP, and manage them on the main router, so I include custom "FILES=" switch at the end of the command, and one /etc/config/network files works for all the routers to switch to DHCP instead of the traditional static '192.168.1.1'.  This has saved me lots of time, as after every new flash, the new router is visible immediately on the network: that is, I don't mess around with changing desktop IPs, unplugging/replugging network cables, telnet/ssh into the new routers, changing ips...

For you purposes, if you decide to switch to ImageGenerator, once you an image that you want to flash to all of your routers (with all of your custom /etc/config/...) files, you could make one flash per router.  The only change for each router image would be the editing of /etc/config/network file (using any text editor) for the specific ip you want that router to be visible at.  This would also give you a benefit in that if the router gets a hard reset (think the /overlay-jffs2 gets wiped out, and goes back to what was initially on the /rom-squashfs), you will still be able to find your router on the network, without going through the whole 192.168.1.1 dance.


"Code:

CONFIG_PACKAGE_kmodswitch:                                                                                                                                                                     
This package contains switch drivers for ADM6996L and BCM53XX RoboSwitc

Is this package needed for BCM53 chips or is it an extra."

I'm not sure what this package is used for.  Unless you installing luci on all of your routers, I think you won't have any issue with flash.  To check on your ram use the 'free' command, and you will see output like this:

           total         used         free       shared      buffers
  Mem:        13388        10264         3124            0          584
Swap:            0            0            0
Total:        13388        10264         3124


I hope this is readable.  I don't post to forums that often, so I haven't taken the time yet to figure out how to give cleaner formatting; with the time that I have, I think I would offer you more content, then a pretty post.  I just hope you don't get a headache reading.


Could you let me know how you make out when start working on your Asus WL520gu routers?  I would like to stick with the br47xx images, but I also need wireless working.   Do you know the difference between the kmod-b43  and kmod-b43legacy modules/packages?  Before I start playing with brcm2.4 images, I think I will try to find out which drivers are being used (and thus making my wl520gu lock up, when the wrt54gl is working fine)

So far i have been able to make images with 1800K size which got up to 2.3MB once wireless drivers and batman-adv support was added.
I removed and compiled new images without undded kernel support which helped keeping  RAM usage lower from a default openwrt install that leaves only 1800K RAM available to 3700K on my builds which i believe i can optimize even more and reach to 4MB free after boot.

When compiling the image i use only buildroot and make menuconfig (matter of personal preference) which allows to see for example which driver revision b43 brcm driver uses such as 5.10.144.3  508.154 and so on. Menuconfig even allows you to select which driver revision you want.

I am now working on custom /etc/config/<files> to add to "build_root/packages/base-files/files/etc/config/" in order to have my builds built according to my needs.

I found out that CONFIG_PACKAGE_kmodswitch:   This package contains switch drivers for ADM6996L and BCM53XX RoboSwitc is needed for some of my (53xx) chips but once the router boots it can be rmmod to save ram. Other packages such as diag, switch_robo and switch_core can also be unloded after boot.

As for the  Asus WL520gu router i cannot help you since my network is 6000 Km away from me. I have almost all the same type of hardware with me for development reasons but i will probably replace that router by another one.

Regarding  kmod-b43  and kmod-b43legacy as far as i know b43legacy inst really used so i removed it from my builds and will be doing tests.

I am also looking at 2 types of builds for now. One build for routers with 16 mb RAM and another for 32MB RAM routers.
Given my study and experience so far i will not longer obtain routers with 16mb RAM but superior. Preferably also 8 mb flash.

I also have this in mind for RAM optimization:
https://lists.openwrt.org/pipermail/ope … 012910.htm

The objective is a wireless batman-adv mesh using kernel 2.6.* or 3.*.
I also do not plan to add Luci or any other gui since i find them slow and resource consuming while at the same time very optional.
I am also looking into linksys wrt300n v1 routers as an replacement to the wrt54g* since i have a few.
Starting studding the atheros chip is also on my todo list but not yet.

Right now my concerns are regarding the b43 wireless performance. Which driver revision are you using and how do you describe it's performance  and stability ?

Right now i have encountered a problem when doing custom builds regarding custom files on <buildroot dir>/files/.

Not all files i place there actually keep my configuration. For example:
wireless, network, system keep my setup when the build is completed but dropbear, ntpclient, dhcp get overwritten either by the build process or the first time the router boots. (I am unsure which one).
This happens for files inside /etc/config/* as for just /etc/ everything seems working as intended

Any feedback about this or how to override this auto change ?

Custom files
http://wiki.openwrt.org/doc/howto/build

Here goes another update regarding building an image with buildroot and using the Image Generator while adding custom files.

While using buildroot i noticed that all my custom configuration files placed inside:

Custom files

In many cases, you may want to have a custom image that has been pre-configured to your link. If so, place your custom files in
<buildroot dir>/files/

For example, let's say that you want an image with a pre-configured /etc/config/firewall, then place your modified firewall config in here:
<buildroot dir>/files/etc/config/

...get copied somewhat but either during the build process or the first time the router boots; they get re-written.
In other words if i place 10 files inside <buildroot dir>/files/etc/config/ they will exist inside the generated image but some (not all) will have the content changed from my specifications such as firewall, dropbear, dhcp, ntpclient and will use openwrt default configuration.

The only way i was able to overcome this issue was to build an image from Image Generator.

Files

A directory with custom files to add can be specified using the FILES variable. Custom files will replace default ones if necessary.
mkdir -p files/etc/config
make image PROFILE=Broadcom-b43 PACKAGES="-kmod-b43legacy -ppp -ppp-mod-pppoe -wpad-mini" FILES=files/

When using Image Generator all custom files get preserved in the final image and remain unchanged; but at the same defaults get added for some such as:

- dhcp gets a default named dhcp-opkg
- dropbear gets a default named dropbear-dhcp
- firewall gets a default named firewall-opkg
- ntpclient gets a default named ntpclient-opkg

I have experienced this all times i built images.

Questions:
- How can the described issue while building root can be changed?
- How can the described detail while generating image can be avoided ?

(Last edited by HeXiLeD on 18 Mar 2012, 17:59)

The discussion might have continued from here.