[CRIU] [PATCH 3/4] vdso: Rework vdso processing files
Christopher Covington
cov at codeaurora.org
Tue Sep 15 08:01:01 PDT 2015
On 09/15/2015 09:54 AM, Christopher Covington wrote:
>> -int vdso_fill_symtable(char *mem, size_t size, struct vdso_symtable *t)
>> -{
>> - Elf64_Phdr *dynamic = NULL, *load = NULL;
>> - Elf64_Ehdr *ehdr = (void *)mem;
>> - Elf64_Dyn *dyn_strtab = NULL;
>> - Elf64_Dyn *dyn_symtab = NULL;
>> - Elf64_Dyn *dyn_strsz = NULL;
>> - Elf64_Dyn *dyn_syment = NULL;
>> - Elf64_Dyn *dyn_hash = NULL;
>> - Elf64_Word *hash = NULL;
>> - Elf64_Phdr *phdr;
>> - Elf64_Dyn *d;
>> -
>> - Elf64_Word *bucket, *chain;
>> - Elf64_Word nbucket, nchain;
>> -
>> - /*
>> - * See Elf specification for this magic values.
>> - */
>> - const char elf_ident[] = {
>> - 0x7f, 0x45, 0x4c, 0x46, 0x02, 0x01, 0x01, 0x00,
>> - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
>> - };
>> -
>> - const char *vdso_symbols[VDSO_SYMBOL_MAX] = {
>> - [VDSO_SYMBOL_CLOCK_GETRES] = VDSO_SYMBOL_CLOCK_GETRES_NAME,
>> - [VDSO_SYMBOL_CLOCK_GETTIME] = VDSO_SYMBOL_CLOCK_GETTIME_NAME,
>> - [VDSO_SYMBOL_GETTIMEOFDAY] = VDSO_SYMBOL_GETTIMEOFDAY_NAME,
>> - [VDSO_SYMBOL_RT_SIGRETURN] = VDSO_SYMBOL_RT_SIGRETURN_NAME,
>> - };
It looks like making vdso_symbols global was the problem. Any objections to
moving the definition (the version that uses architecture-provided macro
ARCH_VDSO_SYMBOLS) inside the vdso_fill_symtable function?
Thanks,
Christopher Covington
--
Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project
More information about the CRIU
mailing list