Changes for U-Boot 1.1.3:
 ======================================================================
 
+* Fix byteorder problem in usbboot and scsiboot commands.
+
 * Patch by Cajus Hahn, 04 Feb 2005:
   - don't insist on leading '/' for filename in ext2load
   - set default partition to useful value (1) in ext2load
 
 
        hdr = (image_header_t *)addr;
 
-       if (hdr->ih_magic == IH_MAGIC) {
+       if (ntohl(hdr->ih_magic) == IH_MAGIC) {
                printf("\n** Bad Magic Number **\n");
                return 1;
        }
        }
 
        print_image_hdr (hdr);
-       cnt = (hdr->ih_size + sizeof(image_header_t));
+       cnt = (ntohl(hdr->ih_size) + sizeof(image_header_t));
        cnt += info.blksz - 1;
        cnt /= info.blksz;
        cnt -= 1;
 
 
        hdr = (image_header_t *)addr;
 
-       if (hdr->ih_magic != IH_MAGIC) {
+       if (ntohl(hdr->ih_magic) != IH_MAGIC) {
                printf("\n** Bad Magic Number **\n");
                return 1;
        }
 
        print_image_hdr (hdr);
 
-       cnt = (hdr->ih_size + sizeof(image_header_t));
+       cnt = (ntohl(hdr->ih_size) + sizeof(image_header_t));
        cnt += info.blksz - 1;
        cnt /= info.blksz;
        cnt -= 1;