aboutsummaryrefslogtreecommitdiffstats
path: root/package/mtd/src/jffs2.c
diff options
context:
space:
mode:
authorDaniel Dickinson <crazycshore@gmail.com>2010-12-26 04:18:08 +0000
committerDaniel Dickinson <crazycshore@gmail.com>2010-12-26 04:18:08 +0000
commitb3bcc483b2d075e1151ea814d5e4f5b458b0e1f7 (patch)
tree4c707b89967dad05f5588212795147444c5ebfbf /package/mtd/src/jffs2.c
parent6ee541168614bebd8f3113f0a81d309ddfe0db9c (diff)
downloadupstream-b3bcc483b2d075e1151ea814d5e4f5b458b0e1f7.tar.gz
upstream-b3bcc483b2d075e1151ea814d5e4f5b458b0e1f7.tar.bz2
upstream-b3bcc483b2d075e1151ea814d5e4f5b458b0e1f7.zip
mtd: Added trx_fixup for brcm63xx imagetag, and made references to fix_trx use the weak reference rather than the brcm47xx ifdef. This fixes a bug in which sysupgrade failed due to changing bad CRC on reboot.
Signed-off-by: Daniel Dickinson <daniel@cshore.neomailbox.net> SVN-Revision: 24837
Diffstat (limited to 'package/mtd/src/jffs2.c')
-rw-r--r--package/mtd/src/jffs2.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/package/mtd/src/jffs2.c b/package/mtd/src/jffs2.c
index 512f22278c..aaf9be5a92 100644
--- a/package/mtd/src/jffs2.c
+++ b/package/mtd/src/jffs2.c
@@ -244,9 +244,9 @@ int mtd_replace_jffs2(const char *mtd, int fd, int ofs, const char *filename)
pad(erasesize);
free(buf);
-#ifdef target_brcm
- trx_fixup(outfd, mtd);
-#endif
+ if (trx_fixup) {
+ trx_fixup(outfd, mtd);
+ }
return (mtdofs - ofs);
}
@@ -347,9 +347,9 @@ int mtd_write_jffs2(const char *mtd, const char *filename, const char *dir)
err = 0;
-#ifdef target_brcm
- trx_fixup(outfd, mtd);
-#endif
+ if (trx_fixup) {
+ trx_fixup(outfd, mtd);
+ }
done:
close(outfd);