On 1/21/20 6:07 AM, Keerthy wrote: > Move the generic elf loading/validating functions to lib/ > so that they can be re-used and accessed by code existing > outside cmd. > > Signed-off-by: Keerthy <j-keer...@ti.com> > Suggested-by: Simon Goldschmidt <simon.k.r.goldschm...@gmail.com> > Reviewed-by: Simon Goldschmidt <simon.k.r.goldschm...@gmail.com> > --- > diff --git a/include/elf.h b/include/elf.h > index 81f40191d7..e7c51986df 100644 > --- a/include/elf.h > +++ b/include/elf.h > @@ -692,6 +692,10 @@ unsigned long elf_hash(const unsigned char *name); > > #ifndef __ASSEMBLER__ > int valid_elf_image(unsigned long addr); > +unsigned long load_elf64_image_phdr(unsigned long addr); > +unsigned long load_elf64_image_shdr(unsigned long addr); > +unsigned long load_elf_image_phdr(unsigned long addr); > +unsigned long load_elf_image_shdr(unsigned long addr); > #endif > > #endif /* _ELF_H */ > diff --git a/lib/Kconfig b/lib/Kconfig > index d040a87d26..b155ced4b2 100644 > --- a/lib/Kconfig > +++ b/lib/Kconfig > @@ -601,4 +601,7 @@ config TEST_FDTDEC > config LIB_DATE > bool > > +config ELF
LIB_ELF? Andrew