Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 362132
b: refs/heads/master
c: 9736751
h: refs/heads/master
v: v3
  • Loading branch information
Jonas Gorski authored and Ralf Baechle committed Mar 19, 2013
1 parent bfa87bc commit 1b4a4b7
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 63c2b6812f1dc0beda4d6adad0365e048aa693e2
refs/heads/master: 97367519d7dac94de566796f034d5f72cbc671f7
5 changes: 1 addition & 4 deletions trunk/arch/mips/bcm63xx/boards/board_bcm963xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -745,10 +745,7 @@ void __init board_prom_init(void)
strcpy(cfe_version, "unknown");
printk(KERN_INFO PFX "CFE version: %s\n", cfe_version);

if (bcm63xx_nvram_init(boot_addr + BCM963XX_NVRAM_OFFSET)) {
printk(KERN_ERR PFX "invalid nvram checksum\n");
return;
}
bcm63xx_nvram_init(boot_addr + BCM963XX_NVRAM_OFFSET);

board_name = bcm63xx_nvram_get_name();
/* find board by name */
Expand Down
7 changes: 3 additions & 4 deletions trunk/arch/mips/bcm63xx/nvram.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ struct bcm963xx_nvram {
static struct bcm963xx_nvram nvram;
static int mac_addr_used;

int __init bcm63xx_nvram_init(void *addr)
void __init bcm63xx_nvram_init(void *addr)
{
unsigned int check_len;
u32 crc, expected_crc;
Expand All @@ -60,9 +60,8 @@ int __init bcm63xx_nvram_init(void *addr)
crc = crc32_le(~0, (u8 *)&nvram, check_len);

if (crc != expected_crc)
return -EINVAL;

return 0;
pr_warn("nvram checksum failed, contents may be invalid (expected %08x, got %08x)\n",
expected_crc, crc);
}

u8 *bcm63xx_nvram_get_name(void)
Expand Down
4 changes: 1 addition & 3 deletions trunk/arch/mips/include/asm/mach-bcm63xx/bcm63xx_nvram.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,8 @@
*
* Initialized the local nvram copy from the target address and checks
* its checksum.
*
* Returns 0 on success.
*/
int __init bcm63xx_nvram_init(void *nvram);
void bcm63xx_nvram_init(void *nvram);

/**
* bcm63xx_nvram_get_name() - returns the board name according to nvram
Expand Down

0 comments on commit 1b4a4b7

Please sign in to comment.