Searched refs:st_size (Results 26 - 50 of 114) sorted by relevance

12345

/linux-master/arch/arm64/include/asm/
H A Dcompat.h59 compat_off_t st_size; member in struct:compat_stat
/linux-master/scripts/basic/
H A Dfixdep.c231 buf = malloc(st.st_size + 1);
236 if (read(fd, buf, st.st_size) != st.st_size) {
240 buf[st.st_size] = '\0';
/linux-master/tools/testing/selftests/kvm/
H A Dguest_memfd_test.c54 TEST_ASSERT_EQ(sb.st_size, total_size);
157 TEST_ASSERT(st1.st_size == 4096, "memfd st_size should match requested size");
164 TEST_ASSERT(st2.st_size == 8192, "second memfd st_size should match requested size");
168 TEST_ASSERT(st1.st_size == 4096, "first memfd st_size should still match requested size");
/linux-master/scripts/
H A Drecordmcount.c58 static struct stat sb; /* Remember .st_size, etc. */
81 munmap(file_map, sb.st_size);
99 file_ptr = file_map + (sb.st_size - offset);
170 * This preserves most aspects of consistency (all except .st_size)
184 sb.st_size = 0;
199 file_map = mmap(0, sb.st_size, PROT_READ|PROT_WRITE, MAP_PRIVATE,
203 file_map = umalloc(sb.st_size);
208 if (read(fd_map, file_map, sb.st_size) != sb.st_size) {
220 file_end = file_map + sb.st_size;
[all...]
H A Dsorttable.c101 addr = mmap(0, sb.st_size, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0);
107 *size = sb.st_size;
H A Dinsert-sys-cert.c176 s->size = elf_sym->st_size;
217 *size = st.st_size;
244 *size = st.st_size;
/linux-master/tools/spi/
H A Dspidev_test.c368 tx = malloc(sb.st_size);
372 rx = malloc(sb.st_size);
376 bytes = read(tx_fd, tx, sb.st_size);
377 if (bytes != sb.st_size)
380 transfer(fd, tx, rx, sb.st_size);
/linux-master/tools/testing/selftests/bpf/prog_tests/
H A Dverify_pkcs7_sig.c153 if (st.st_size > sizeof(data_item->sig)) {
158 data_item->sig_len = st.st_size;
217 modlen = st.st_size;
224 mod = mmap(NULL, st.st_size, PROT_READ, MAP_PRIVATE, fd, 0);
260 munmap(mod, st.st_size);
418 return st.st_size;
/linux-master/tools/perf/util/
H A Dcopyfile.c104 if (st.st_size == 0) { /* /proc? do it slowly... */
120 err = copyfile_offset(fromfd, 0, tofd, 0, st.st_size);
H A Ddata.c144 file->size = st.st_size;
175 file->size = st.st_size;
222 if (!stat(data->path, &st) && st.st_size) {
287 if (!st.st_size) {
293 data->file.size = st.st_size;
/linux-master/arch/sparc/boot/
H A Dpiggyback.c231 st4(buffer + 12, s.st_size);
243 s.st_size);
/linux-master/tools/testing/selftests/memfd/
H A Dfuse_mnt.c37 st->st_size = strlen(memfd_content);
/linux-master/arch/powerpc/include/asm/
H A Dcompat.h34 compat_off_t st_size; member in struct:compat_stat
/linux-master/tools/power/acpi/tools/pfrut/
H A Dpfrut.c342 addr_map_capsule = mmap(NULL, st.st_size, PROT_READ, MAP_SHARED,
353 ret = write(fd_update, (char *)addr_map_capsule, st.st_size);
366 munmap(addr_map_capsule, st.st_size);
/linux-master/arch/powerpc/boot/
H A Dmktree.c60 nblks = (st.st_size + IMGBLK) / IMGBLK;
/linux-master/arch/mips/include/asm/
H A Dcompat.h45 compat_off_t st_size; member in struct:compat_stat
/linux-master/arch/parisc/include/asm/
H A Dcompat.h33 compat_off_t st_size; member in struct:compat_stat
/linux-master/samples/bpf/
H A Dtest_lru_dist.c178 b = malloc(fst.st_size);
181 assert(read(dist_fd, b, fst.st_size) == fst.st_size);
183 for (i = 0; i < fst.st_size; i++) {
/linux-master/arch/s390/include/asm/
H A Dcompat.h75 u32 st_size; member in struct:compat_stat
/linux-master/arch/arm64/kernel/pi/
H A Drelacheck.c66 ehdr = mmap(0, stat.st_size, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0);
/linux-master/arch/sparc/vdso/
H A Dvma.c128 osym->st_size = nsym->st_size;
196 osym->st_size = nsym->st_size;
/linux-master/tools/firmware/
H A Dihex2fw.c111 data = mmap(NULL, st.st_size, PROT_READ, MAP_SHARED, infd, 0);
126 if (process_ihex(data, st.st_size))
/linux-master/arch/mips/vdso/
H A Dgenvdso.c129 addr = mmap(NULL, stat.st_size, PROT_READ | PROT_WRITE, MAP_SHARED, fd,
186 *_size = stat.st_size;
/linux-master/arch/mips/tools/
H A Dloongson3-llsc-check.c263 vmlinux = mmap(NULL, st.st_size, PROT_READ, MAP_PRIVATE, vmlinux_fd, 0);
302 munmap(vmlinux, st.st_size);
/linux-master/tools/testing/selftests/mm/
H A Dpagemap_ioctl.c1161 fmem = mmap(NULL, sbuf.st_size, PROT_READ, MAP_PRIVATE, fd, 0);
1165 tmp_buf = malloc(sbuf.st_size);
1166 memcpy(tmp_buf, fmem, sbuf.st_size);
1168 ret = pagemap_ioctl(fmem, sbuf.st_size, vec, vec_size, 0, 0,
1172 LEN(vec[0]) == ceilf((float)sbuf.st_size/page_size) &&
1176 munmap(fmem, sbuf.st_size);
1600 fmem = mmap(NULL, sbuf.st_size, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0);
1604 wp_init(fmem, sbuf.st_size);
1605 wp_addr_range(fmem, sbuf.st_size);
1607 base_tests("File memory testing:", fmem, sbuf.st_size,
[all...]

Completed in 205 milliseconds

12345