aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2008-05-05 17:31:36 +0000
committerGabor Juhos <juhosg@openwrt.org>2008-05-05 17:31:36 +0000
commit2d697dad7b74b9e1463670ba99c9e6d761044f0a (patch)
treedf6386340fba60512d151764b6d562e7b4c0004f
parenta7cc49940d5b44988519bc984383c7fa6348c49b (diff)
downloadupstream-2d697dad7b74b9e1463670ba99c9e6d761044f0a.tar.gz
upstream-2d697dad7b74b9e1463670ba99c9e6d761044f0a.tar.bz2
upstream-2d697dad7b74b9e1463670ba99c9e6d761044f0a.zip
[atheros] fix size calculation of the radio_config
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@11049 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r--target/linux/atheros/files/arch/mips/atheros/board.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/target/linux/atheros/files/arch/mips/atheros/board.c b/target/linux/atheros/files/arch/mips/atheros/board.c
index 1b1e04fcee..ba427883a7 100644
--- a/target/linux/atheros/files/arch/mips/atheros/board.c
+++ b/target/linux/atheros/files/arch/mips/atheros/board.c
@@ -121,7 +121,7 @@ int __init ar531x_find_config(char *flash_limit)
radio_config = board_config + 0x100 + ((rcfg - bcfg) & 0xfff);
printk("Radio config found at offset 0x%x(0x%x)\n", rcfg - bcfg, radio_config - board_config);
- rcfg_size = BOARD_CONFIG_BUFSZ - ((rcfg - bcfg) & (BOARD_CONFIG_BUFSZ - 1));
+ rcfg_size = BOARD_CONFIG_BUFSZ - ((0x100 + rcfg - bcfg) & (BOARD_CONFIG_BUFSZ - 1));
memcpy(radio_config, rcfg, rcfg_size);
return 0;