Commit 9c89614d3f1ea510d7fcb4a2b438fb3e0d58392c

Authored by Christian Eggers
Committed by Tom Rini
1 parent 1cb8393a13

common: Remove invalid endianess conversion

do_bootm_standanlone() calls ntohl(images->ep) which is wrong because
endianess conversion has already been done:

do_bootm()
\-do_bootm_states()
  +-bootm_find_os()
  | \-images.ep = image_get_ep();
  |   \-uimage_to_cpu(hdr->ih_ep);
  \-boot_selected_os()
    \-do_bootm_standanlone()

Without this conversion the code works correctly at least on AT91SAM9G45.
On big endian systems there should be no difference after applying this
patch because uimage_to_cpu(x) and ntohl(x) both expand to 'x'.

Signed-off-by: Christian Eggers <ceggers@gmx.de>

Showing 1 changed file with 2 additions and 2 deletions Side-by-side Diff

... ... @@ -514,8 +514,8 @@
514 514 setenv_hex("filesize", images->os.image_len);
515 515 return 0;
516 516 }
517   - appl = (int (*)(int, char * const []))(ulong)ntohl(images->ep);
518   - (*appl)(argc, argv);
  517 + appl = (int (*)(int, char * const []))images->ep;
  518 + appl(argc, argv);
519 519 return 0;
520 520 }
521 521