[U-Boot] [PATCH v2, RFC] armv7: fixloop: don't fixup if location is invalid on RAM

Joakim Tjernlund joakim.tjernlund at transmode.se
Tue Jan 4 10:49:29 CET 2011


>
> Need to check that location is valid on RAM before the fixup.

Why this change? The [PATCH RFC] armv7: fixloop: don't fixup if location is NULL
should be what you need.
You could mention what causes these NULL fixups, here is commit
entry for powerpc:

powerpc: do not fixup NULL ptrs

    The fixup routine must not fixup NULL pointers.
    Problem can be seen by
     char *testfun(void) __attribute__((weak));
     char *(*myfun)(void) = testfun;

    Then add
      printf("myfun:%p, &myfun:%p\n", myfun, &myfun);
    before relocation and after relocation.
    myfun should be NULL in both cases but it is not.



More information about the U-Boot mailing list