+
+ /* XXX: hack for supporting the CFE environment stuff on WGT634U */
+ if (lim >= 8 * 1024 * 1024) {
-+ src = (u32 *) iobase + 8 * 1024 * 1024 - 0x2000;
-+ dst = (u32 *) nvram_buf;
++ src = (u32 *)(iobase + 8 * 1024 * 1024 - 0x2000);
++ dst = (u32 *)nvram_buf;
+
+ if ((*src & 0xff00ff) == 0x000001) {
+ printk("early_nvram_init: WGT634U NVRAM found.\n");
/* TODO: when nvram is on nand flash check for bad blocks first. */
off = FLASH_MIN;
while (off <= lim) {
-@@ -181,6 +203,13 @@ int bcm47xx_nvram_getenv(const char *nam
+@@ -189,6 +211,13 @@ int bcm47xx_nvram_getenv(const char *nam
return err;
}
+
/* Look for name=value and return value */
var = &nvram_buf[sizeof(struct nvram_header)];
- end = nvram_buf + sizeof(nvram_buf) - 2;
+ end = nvram_buf + sizeof(nvram_buf);