[U-Boot] Atheros "ART" data crc calculation

Drassal, Allan drasal at wsu.edu
Wed Dec 5 15:34:57 CET 2012


Hello all:
I am attempting to recover the ART "Atheros Radio Test" EEPROM data for a router and am attempting to copy the data from one router to the other, which may not be the best of ideas, but the two boards are identical and purchased at the same time...

The command "progmac" seems to be broken.  This is the command supplied by the vendor, it does not alter the data, or I don't know how to use it properly.  I am issuing the command "progmac 1234" where 1234 is the last 4 digits of the MAC to program.

I have located the two ethernet addresses in the data and wish to alter the data.
I can alter the data, but then the CRC check fails, and the data is rejected.
I would like to recalculate the CRC, and I think it is using an XOR method, and the result of the calculation should be 0xffffffff, but I am not sure on this point.

I located a .c program that reads and writes this data, but I don't think it is for embedded cards (such as this router board).

The specific board details are Buffalo WZR-HP-AG300H, running a platform similar to an AP96 reference design.
The following web page has the specifications... http://wiki.openwrt.org/toh/buffalo/wzr-hp-ag300h

The information is stored at address 0xbf050000 in the FLASH and this sector is 64kb in size (one flash sector).

I can alter the data by copying to RAM, modifying the bytes, then erase and rewrite the flash sector.
However, when I start up, I get a "Bad CRC of EEPROM!!" from the U-Boot, and I can continue the boot process with a "boot" command, however, the Atheros driver refuses to use the information since it fails the CRC check, and the driver does not load.

I have searched for some time on the internet to see if anyone else has run across this problem, but I can't turn up many results.

I thought I would put this out on the mailing list to see if anyone can provide assistance with this.

Thanks,
Allan Drassal


More information about the U-Boot mailing list