提交 acdcd10c 编写于 作者: S stroese

Update for esd auto_update and hh405 board

上级 89c02e2c
......@@ -2,6 +2,9 @@
Changes for U-Boot 1.1.3:
======================================================================
* Patch by Stefan Roese, 16 Mar 2005:
Update for esd auto_update and hh405 board
* Adapt for U-Boot image size (new features enabled) on TQM5200
* Update code for TQM8540 board (and 85xx in general):
......
......@@ -224,6 +224,25 @@ int au_do_update(int i, long sz)
start = au_image[i].start;
end = au_image[i].start + au_image[i].size - 1;
/*
* do not update firmware when image is already in flash.
*/
if (au_image[i].type == AU_FIRMWARE) {
char *orig = (char*)start;
char *new = (char *)((char *)hdr + sizeof(*hdr));
nbytes = ntohl(hdr->ih_size);
while(--nbytes) {
if (*orig++ != *new++) {
break;
}
}
if (!nbytes) {
printf("Skipping firmware update - images are identical\n");
break;
}
}
/* unprotect the address range */
/* this assumes that ONLY the firmware is protected! */
if (au_image[i].type == AU_FIRMWARE) {
......
此差异已折叠。
因为 它太大了无法显示 source diff 。你可以改为 查看blob
此差异已折叠。
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册