/system/bt/osi/test/ |
D | wakelock_test.cc | 101 CHECK(lock_stat.st_size >= unlock_stat.st_size); in IsFileWakeLockAcquired() 104 mmap(nullptr, lock_stat.st_size, PROT_READ, MAP_PRIVATE, lock_fd, 0); in IsFileWakeLockAcquired() 106 void* unlock_file = mmap(nullptr, unlock_stat.st_size, PROT_READ, in IsFileWakeLockAcquired() 109 if (memcmp(lock_file, unlock_file, unlock_stat.st_size) == 0) { in IsFileWakeLockAcquired() 110 acquired = lock_stat.st_size > unlock_stat.st_size; in IsFileWakeLockAcquired() 117 munmap(lock_file, lock_stat.st_size); in IsFileWakeLockAcquired() 118 munmap(unlock_file, unlock_stat.st_size); in IsFileWakeLockAcquired()
|
/system/extras/pagecache/ |
D | dumpcache.c | 84 void* mapped_addr = mmap(NULL, sb->st_size, PROT_NONE, MAP_SHARED, fd, 0); in store_num_cached() 88 size_t num_file_pages = (sb->st_size + g_page_size - 1) / g_page_size; in store_num_cached() 90 ret = mincore(mapped_addr, sb->st_size, mincore_data); in store_num_cached() 98 struct file_info *info = get_file_info(fpath, sb->st_size); in store_num_cached() 103 munmap(mapped_addr, sb->st_size); in store_num_cached()
|
/system/sepolicy/tools/sepolicy-analyze/ |
D | utils.c | 41 map = mmap(NULL, sb.st_size, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in load_policy() 50 pf->len = sb.st_size; in load_policy() 64 munmap(map, sb.st_size); in load_policy()
|
/system/core/cpio/ |
D | mkbootfs.c | 251 tmp = (char*) malloc(s.st_size); in _archive() 252 if(tmp == 0) die("cannot allocate %d bytes", s.st_size); in _archive() 254 if(read(fd, tmp, s.st_size) != s.st_size) { in _archive() 255 die("cannot read %d bytes", s.st_size); in _archive() 258 _eject(&s, out, olen, tmp, s.st_size); in _archive()
|
/system/nvram/hal/ |
D | fake_nvram_storage.cpp | 95 if (data_file_stat.st_size > kMaxFileSize) { in LoadFile() 96 LOG(ERROR) << "Bad size for " << name << ":" << data_file_stat.st_size; in LoadFile() 100 if (!blob->Resize(data_file_stat.st_size)) { in LoadFile()
|
/system/sepolicy/tools/ |
D | sepolicy-check.c | 204 map = mmap(NULL, sb.st_size, PROT_READ | PROT_WRITE, MAP_PRIVATE, fd, 0); in load_policy() 214 pf->len = sb.st_size; in load_policy() 218 munmap(map, sb.st_size); in load_policy() 225 munmap(map, sb.st_size); in load_policy()
|
/system/core/fs_mgr/libsnapshot/ |
D | power_test.cpp | 191 while (written < s.st_size) { in Create() 192 uint64_t remaining = s.st_size - written; in Create() 268 uint64_t s1_size = (s1.st_size + 4095) & ~uint64_t(4095); in SetupImages() 269 uint64_t s2_size = (s2.st_size + 4095) & ~uint64_t(4095); in SetupImages() 292 while (written < s1.st_size) { in SetupImages() 293 uint64_t remaining = s1.st_size - written; in SetupImages() 496 uint64_t canonical_size = s.st_size; in Check()
|
/system/core/fs_mgr/libvbmeta/ |
D | utility.cpp | 37 return sb.st_size; in GetFileSize()
|
/system/incremental_delivery/incfs/ |
D | path.cpp | 128 if (::lstat(fdNameBuffer, &st) || st.st_size == 0) { in fromFd() 129 st.st_size = PATH_MAX; in fromFd() 131 auto bufSize = st.st_size; in fromFd()
|
/system/core/libcutils/ |
D | ashmem-host.cpp | 95 return buf.st_size; in ashmem_get_size_region()
|
D | ashmem-dev.cpp | 462 ALOGD("ashmem_get_size_region(%d): %d\n", fd, static_cast<int>(sb.st_size)); in ashmem_get_size_region() 465 return sb.st_size; in ashmem_get_size_region()
|
/system/core/libunwindstack/tests/ |
D | SymbolsTest.cpp | 47 void InitSym(TypeParam* sym, uint32_t st_value, uint32_t st_size, uint32_t st_name) { in InitSym() argument 51 sym->st_size = st_size; in InitSym() 329 sym.st_size = 0x100; in TYPED_TEST_P() 347 sym.st_size = 0x100; in TYPED_TEST_P()
|
/system/core/adb/client/ |
D | incremental.cpp | 124 auto [signature_fd, signature] = read_and_encode_signature(st.st_size, file, silent); in start_install() 130 (long long)st.st_size, i, signature.c_str()); in start_install() 156 auto [fd, _] = read_signature(st.st_size, file, /*silent=*/true); in can_install()
|
D | commandline.cpp | 896 static_cast<int64_t>(sb.st_size), SIDELOAD_HOST_BLOCK_SIZE); in adb_sideload_install() 908 if (sb.st_size > INT_MAX) { in adb_sideload_install() 912 return adb_sideload_legacy(filename, package_fd.get(), static_cast<int>(sb.st_size)); in adb_sideload_install() 932 static_cast<double>(xfer) / (sb.st_size ? sb.st_size : 1), in adb_sideload_install() 942 if (offset >= static_cast<int64_t>(sb.st_size)) { in adb_sideload_install() 946 block, offset, static_cast<int64_t>(sb.st_size)); in adb_sideload_install() 951 if ((offset + SIDELOAD_HOST_BLOCK_SIZE) > static_cast<int64_t>(sb.st_size)) { in adb_sideload_install() 952 to_write = sb.st_size - offset; in adb_sideload_install() 977 int percent = static_cast<int>(xfer * 47LL / (sb.st_size ? sb.st_size : 1)); in adb_sideload_install()
|
D | file_sync_client.cpp | 492 st->st_size = msg.stat_v2.size; in FinishStat() 514 st->st_size = msg.stat_v1.size; in FinishStat() 634 uint64_t total_size = st.st_size; in SendLargeFile() 736 uint64_t total_size = st.st_size; in SendLargeFileLegacy() 1015 st->st_size = 0; in sync_stat_fallback() 1065 if (st.st_size < SYNC_DATA_MAX) { in sync_send() 1305 ci.size = st.st_size; in local_build_list() 1401 if (st.st_size == static_cast<off_t>(ci.size) && st.st_mtime == ci.time) { in copy_local_dir_remote() 1518 sc.SetExpectedTotalBytes(st.st_size); in do_sync_push() 1746 sc.SetExpectedTotalBytes(src_st.st_size); in do_sync_pull() [all …]
|
/system/extras/ioshark/ |
D | dump_ioshark_filenames.c | 50 filename_cache_num_entries = st.st_size / in main()
|
/system/core/property_service/libpropertyinfoparser/ |
D | property_info_parser.cpp | 210 (fd_stat.st_size < static_cast<off_t>(sizeof(PropertyInfoArea)))) { in LoadPath() 215 auto mmap_size = fd_stat.st_size; in LoadPath()
|
/system/core/libprocessgroup/cgrouprc/ |
D | cgroup_file.cpp | 50 size_t file_size = sb.st_size; in LoadRcFile()
|
/system/core/libunwindstack/ |
D | Memory.cpp | 261 if (offset >= static_cast<uint64_t>(buf.st_size)) { in Init() 267 if (aligned_offset > static_cast<uint64_t>(buf.st_size) || in Init() 268 offset > static_cast<uint64_t>(buf.st_size)) { in Init() 272 size_ = buf.st_size - aligned_offset; in Init()
|
D | Symbols.cpp | 58 sym.st_size = 0; in ReadFuncInfo() 60 Info info{.addr = sym.st_value, .size = static_cast<uint32_t>(sym.st_size), .name = sym.st_name}; in ReadFuncInfo()
|
/system/sepolicy/tests/ |
D | sepol_wrap.cpp | 221 auto unmap = [=](void *ptr) { munmap(ptr, sb.st_size); }; in load_policy() 223 mmap(nullptr, sb.st_size, PROT_READ, MAP_PRIVATE, fileno(fp), 0), unmap); in load_policy() 235 pf.len = sb.st_size; in load_policy()
|
/system/extras/verity/fec/tests/ |
D | fec.py | 34 size = os.stat(image).st_size
|
/system/extras/kexec_tools/ |
D | kexecload.c | 33 return st.st_size; in get_file_size()
|
/system/security/identity/ |
D | Util.cpp | 64 data.resize(statbuf.st_size); in fileGetContents()
|
/system/core/libutils/ |
D | Tokenizer.cpp | 62 size_t length = size_t(stat.st_size); in open()
|