Linksys WRT54GS v4.0
From DD-WRT Wiki
 How To Flash
This is the process I developed based on comments left below. I was unsuccessful in flashing the router directly to the standard dd-wrt firmware, as some of the comments state is possible. I decided to err on the side of caution; I don't know if all of the resets are necessary.
Please, if this is the first time you're flashing a router with dd-wrt, read up on the basics before starting this process. You will avoid yourself a world of annoyance as a result.
- Read the Peacock Announcement: http://www.dd-wrt.com/phpBB2/viewtopic.php?t=51486
- Upgrade the router to the latest Linksys firmware (version 1.06.3). This can be obtained from the manufacturer's website.
- Perform a hard (30-30-30) reset.
- Flash router with this 14929 firmware. ftp://ftp.dd-wrt.com/others/eko/BrainSlayer-V24-preSP2/2010/08-12-10-r14929/broadcom/dd-wrt.v24_mini_wrt54gs.bin
- Wait 5 minutes. Perform another hard reset.
- If you wish to flash to another firmware, be sure to read and understand the peacock announcement notes1, 3, and 4 and flash a generic firmware of your choice that will fit on your router.
- Wait 5 minutes and then a third hard reset.
- Wait for the router to reboot, then profit!
 Other Notes
The stock firmware from Linksys on the WRT54GS v4 won't accept a firmware image over 3MB in size (you will get the error: "Upgrade are failed!"(sic) if you try) so you will need to flash the mini version of DD-WRT onto the router BEFORE flashing the std or voip versions. (Remember to hold reset button for 30 sec after flashing mini version.)
DO NOT PUT FULL VERSION ON FIRST, i just did that and now my router is bricked:( make sure you do mini first guys!