• Home
  • Raw
  • Download

Lines Matching refs:i

163 	int result, i;  in sanity_check_segment_list()  local
180 for (i = 0; i < nr_segments; i++) { in sanity_check_segment_list()
183 mstart = image->segment[i].mem; in sanity_check_segment_list()
184 mend = mstart + image->segment[i].memsz; in sanity_check_segment_list()
197 for (i = 0; i < nr_segments; i++) { in sanity_check_segment_list()
201 mstart = image->segment[i].mem; in sanity_check_segment_list()
202 mend = mstart + image->segment[i].memsz; in sanity_check_segment_list()
203 for (j = 0; j < i; j++) { in sanity_check_segment_list()
219 for (i = 0; i < nr_segments; i++) { in sanity_check_segment_list()
220 if (image->segment[i].bufsz > image->segment[i].memsz) in sanity_check_segment_list()
236 for (i = 0; i < nr_segments; i++) { in sanity_check_segment_list()
239 mstart = image->segment[i].mem; in sanity_check_segment_list()
240 mend = mstart + image->segment[i].memsz - 1; in sanity_check_segment_list()
626 unsigned long i; in kimage_is_destination_range() local
628 for (i = 0; i < image->nr_segments; i++) { in kimage_is_destination_range()
631 mstart = image->segment[i].mem; in kimage_is_destination_range()
632 mend = mstart + image->segment[i].memsz; in kimage_is_destination_range()
646 unsigned int count, i; in kimage_alloc_pages() local
650 for (i = 0; i < count; i++) in kimage_alloc_pages()
651 SetPageReserved(pages + i); in kimage_alloc_pages()
659 unsigned int order, count, i; in kimage_free_pages() local
663 for (i = 0; i < count; i++) in kimage_free_pages()
664 ClearPageReserved(page + i); in kimage_free_pages()
779 unsigned long i; in kimage_alloc_crash_control_pages() local
784 for (i = 0; i < image->nr_segments; i++) { in kimage_alloc_crash_control_pages()
787 mstart = image->segment[i].mem; in kimage_alloc_crash_control_pages()
788 mend = mstart + image->segment[i].memsz - 1; in kimage_alloc_crash_control_pages()
797 if (i == image->nr_segments) { in kimage_alloc_crash_control_pages()
1289 unsigned long i; in SYSCALL_DEFINE4() local
1314 for (i = 0; i < nr_segments; i++) { in SYSCALL_DEFINE4()
1315 result = kimage_load_segment(image, &image->segment[i]); in SYSCALL_DEFINE4()
1353 unsigned long i, result; in COMPAT_SYSCALL_DEFINE4() local
1365 for (i = 0; i < nr_segments; i++) { in COMPAT_SYSCALL_DEFINE4()
1366 result = copy_from_user(&in, &segments[i], sizeof(in)); in COMPAT_SYSCALL_DEFINE4()
1375 result = copy_to_user(&ksegments[i], &out, sizeof(out)); in COMPAT_SYSCALL_DEFINE4()
1389 int ret = 0, i; in SYSCALL_DEFINE5() local
1433 for (i = 0; i < image->nr_segments; i++) { in SYSCALL_DEFINE5()
1436 ksegment = &image->segment[i]; in SYSCALL_DEFINE5()
1438 i, ksegment->buf, ksegment->bufsz, ksegment->mem, in SYSCALL_DEFINE5()
1441 ret = kimage_load_segment(image, &image->segment[i]); in SYSCALL_DEFINE5()
1802 int i; in get_last_crashkernel() local
1805 for (i = 0; suffix_tbl[i]; i++) { in get_last_crashkernel()
1806 q = end_p - strlen(suffix_tbl[i]); in get_last_crashkernel()
1807 if (!strncmp(q, suffix_tbl[i], in get_last_crashkernel()
1808 strlen(suffix_tbl[i]))) in get_last_crashkernel()
2186 int ret = 0, i, j, zero_buf_sz, sha_region_sz; in kexec_calculate_store_digests() local
2227 for (j = i = 0; i < image->nr_segments; i++) { in kexec_calculate_store_digests()
2230 ksegment = &image->segment[i]; in kexec_calculate_store_digests()
2302 int i, ret = 0, entry_sidx = -1; in __kexec_load_purgatory() local
2340 for (i = 0; i < pi->ehdr->e_shnum; i++) { in __kexec_load_purgatory()
2341 if (sechdrs[i].sh_type == SHT_NOBITS) in __kexec_load_purgatory()
2344 sechdrs[i].sh_offset = (unsigned long)pi->ehdr + in __kexec_load_purgatory()
2345 sechdrs[i].sh_offset; in __kexec_load_purgatory()
2353 for (i = 0; i < pi->ehdr->e_shnum; i++) { in __kexec_load_purgatory()
2354 if (!(sechdrs[i].sh_flags & SHF_ALLOC)) in __kexec_load_purgatory()
2357 if (!(sechdrs[i].sh_flags & SHF_EXECINSTR)) in __kexec_load_purgatory()
2361 if (sechdrs[i].sh_addr <= pi->ehdr->e_entry && in __kexec_load_purgatory()
2362 ((sechdrs[i].sh_addr + sechdrs[i].sh_size) > in __kexec_load_purgatory()
2364 entry_sidx = i; in __kexec_load_purgatory()
2365 entry -= sechdrs[i].sh_addr; in __kexec_load_purgatory()
2376 for (i = 0; i < pi->ehdr->e_shnum; i++) { in __kexec_load_purgatory()
2377 if (!(sechdrs[i].sh_flags & SHF_ALLOC)) in __kexec_load_purgatory()
2380 align = sechdrs[i].sh_addralign; in __kexec_load_purgatory()
2381 if (sechdrs[i].sh_type != SHT_NOBITS) { in __kexec_load_purgatory()
2385 buf_sz += sechdrs[i].sh_size; in __kexec_load_purgatory()
2391 bss_sz += sechdrs[i].sh_size; in __kexec_load_purgatory()
2424 for (i = 0; i < pi->ehdr->e_shnum; i++) { in __kexec_load_purgatory()
2425 if (!(sechdrs[i].sh_flags & SHF_ALLOC)) in __kexec_load_purgatory()
2428 align = sechdrs[i].sh_addralign; in __kexec_load_purgatory()
2429 if (sechdrs[i].sh_type != SHT_NOBITS) { in __kexec_load_purgatory()
2433 src = (char *) sechdrs[i].sh_offset; in __kexec_load_purgatory()
2434 memcpy(buf_addr + offset, src, sechdrs[i].sh_size); in __kexec_load_purgatory()
2437 sechdrs[i].sh_addr = curr_load_addr; in __kexec_load_purgatory()
2443 sechdrs[i].sh_offset = (unsigned long)(buf_addr + offset); in __kexec_load_purgatory()
2446 curr_load_addr += sechdrs[i].sh_size; in __kexec_load_purgatory()
2449 sechdrs[i].sh_addr = bss_addr; in __kexec_load_purgatory()
2450 bss_addr += sechdrs[i].sh_size; in __kexec_load_purgatory()
2478 int i, ret; in kexec_apply_relocations() local
2483 for (i = 0; i < pi->ehdr->e_shnum; i++) { in kexec_apply_relocations()
2486 if (sechdrs[i].sh_type != SHT_RELA && in kexec_apply_relocations()
2487 sechdrs[i].sh_type != SHT_REL) in kexec_apply_relocations()
2496 if (sechdrs[i].sh_info >= pi->ehdr->e_shnum || in kexec_apply_relocations()
2497 sechdrs[i].sh_link >= pi->ehdr->e_shnum) in kexec_apply_relocations()
2500 section = &sechdrs[sechdrs[i].sh_info]; in kexec_apply_relocations()
2501 symtab = &sechdrs[sechdrs[i].sh_link]; in kexec_apply_relocations()
2518 if (sechdrs[i].sh_type == SHT_RELA) in kexec_apply_relocations()
2520 sechdrs, i); in kexec_apply_relocations()
2521 else if (sechdrs[i].sh_type == SHT_REL) in kexec_apply_relocations()
2523 sechdrs, i); in kexec_apply_relocations()
2580 int i, k; in kexec_purgatory_find_symbol() local
2589 for (i = 0; i < ehdr->e_shnum; i++) { in kexec_purgatory_find_symbol()
2590 if (sechdrs[i].sh_type != SHT_SYMTAB) in kexec_purgatory_find_symbol()
2593 if (sechdrs[i].sh_link >= ehdr->e_shnum) in kexec_purgatory_find_symbol()
2596 strtab = (char *)sechdrs[sechdrs[i].sh_link].sh_offset; in kexec_purgatory_find_symbol()
2597 syms = (Elf_Sym *)sechdrs[i].sh_offset; in kexec_purgatory_find_symbol()
2600 for (k = 0; k < sechdrs[i].sh_size/sizeof(Elf_Sym); k++) { in kexec_purgatory_find_symbol()