• Home
  • Raw
  • Download

Lines Matching refs:nsec

376 	uint32_t *buf = NULL, nsec;  in module_package_read_offsets()  local
400 nsec = *sections = le32_to_cpu(buf[2]); in module_package_read_offsets()
402 if (nsec > MAXSECTIONS) { in module_package_read_offsets()
404 nsec); in module_package_read_offsets()
408 off = (size_t *) malloc((nsec + 1) * sizeof(size_t)); in module_package_read_offsets()
415 buf = malloc(sizeof(uint32_t) * nsec); in module_package_read_offsets()
420 rc = next_entry(buf, file, sizeof(uint32_t) * nsec); in module_package_read_offsets()
426 for (i = 0; i < nsec; i++) { in module_package_read_offsets()
436 rc = policy_file_length(file, &off[nsec]); in module_package_read_offsets()
440 if (nsec && off[nsec] < off[nsec-1]) { in module_package_read_offsets()
442 "offset %zu -> %zu", nsec, off[nsec - 1], in module_package_read_offsets()
443 off[nsec]); in module_package_read_offsets()
467 uint32_t buf[1], nsec; in sepol_module_package_read() local
472 if (module_package_read_offsets(mod, file, &offsets, &nsec)) in sepol_module_package_read()
477 for (i = 0; i < nsec; i++) { in sepol_module_package_read()
653 uint32_t buf[5], len, nsec; in sepol_module_package_info() local
662 if (module_package_read_offsets(mod, file, &offsets, &nsec)) { in sepol_module_package_info()
666 for (i = 0; i < nsec; i++) { in sepol_module_package_info()
878 uint32_t buf[5], offsets[5], len, nsec = 0; in sepol_module_package_write() local
891 nsec++; in sepol_module_package_write()
907 nsec++; in sepol_module_package_write()
910 nsec++; in sepol_module_package_write()
913 nsec++; in sepol_module_package_write()
916 nsec++; in sepol_module_package_write()
920 buf[2] = cpu_to_le32(nsec); in sepol_module_package_write()
925 offsets[0] = (nsec + 3) * sizeof(uint32_t); in sepol_module_package_write()
954 if (put_entry(buf, sizeof(uint32_t), nsec, file) != nsec) in sepol_module_package_write()