Home
last modified time | relevance | path

Searched refs:file_fd (Results 1 – 9 of 9) sorted by relevance

/system/core/fs_mgr/libfiemap/
Dfiemap_writer.cpp265 static FiemapStatus FallocateFallback(int file_fd, uint64_t block_size, uint64_t file_size, in FallocateFallback() argument
280 auto rv = TEMP_FAILURE_RETRY(lseek(file_fd, cursor - 1, SEEK_SET)); in FallocateFallback()
290 if (!android::base::WriteFully(file_fd, buffer, 1)) { in FallocateFallback()
318 static bool IsFilePinned(int file_fd, const std::string& file_path, uint32_t fs_type) { in IsFilePinned() argument
327 int error = ioctl(file_fd, FS_IOC_GETFLAGS, &flags); in IsFilePinned()
342 error = ioctl(file_fd, F2FS_IOC_GET_PIN_FILE, &moved_blocks_nr); in IsFilePinned()
358 static bool PinFile(int file_fd, const std::string& file_path, uint32_t fs_type) { in PinFile() argument
359 if (IsFilePinned(file_fd, file_path, fs_type)) { in PinFile()
369 int error = ioctl(file_fd, F2FS_IOC_SET_PIN_FILE, &pin_status); in PinFile()
385 static FiemapStatus WriteZeroes(int file_fd, const std::string& file_path, size_t blocksz, in WriteZeroes() argument
[all …]
Dutility.h42 bool F2fsPinBeforeAllocate(int file_fd, bool* supported);
Dutility.cpp99 bool F2fsPinBeforeAllocate(int file_fd, bool* supported) { in F2fsPinBeforeAllocate() argument
101 if (fstat(file_fd, &st) < 0) { in F2fsPinBeforeAllocate()
Dimage_manager.cpp336 android::base::unique_fd file_fd(open(file.c_str(), kOpenFlags)); in CreateLoopDevice() local
337 if (file_fd < 0) { in CreateLoopDevice()
341 if (!control.Attach(file_fd, timeout_ms, path)) { in CreateLoopDevice()
/system/core/trusty/apploader/
Dapploader.cpp97 unique_fd file_fd(TEMP_FAILURE_RETRY(open(file_name, O_RDONLY))); in read_file() local
98 if (!file_fd.ok()) { in read_file()
103 rc = fstat64(file_fd, &st); in read_file()
137 pread(file_fd, (char*)shm + file_offset, file_size - file_offset, file_offset)); in read_file()
/system/core/fs_mgr/libdm/
Dloop_control.cpp42 bool LoopControl::Attach(int file_fd, const std::chrono::milliseconds& timeout_ms, in Attach() argument
65 if (int rc = ioctl(loop_fd, LOOP_SET_FD, file_fd); rc == 0) { in Attach()
/system/core/fs_mgr/libdm/include/libdm/
Dloop_control.h40 bool Attach(int file_fd, const std::chrono::milliseconds& timeout_ms,
/system/core/libsparse/
Doutput_file.cpp663 int file_fd = open(file, O_RDONLY | O_BINARY); in write_file_chunk() local
664 if (file_fd < 0) { in write_file_chunk()
668 ret = write_fd_chunk(out, len, file_fd, offset); in write_file_chunk()
670 close(file_fd); in write_file_chunk()
/system/core/fs_mgr/libsnapshot/
Dsnapshot_fuzz_utils.cpp396 android::base::unique_fd file_fd(open(file.c_str(), kOpenFlags)); in CheckCreateLoopDevice() local
397 PCHECK(file_fd >= 0) << "Could not open file: " << file; in CheckCreateLoopDevice()
398 CHECK(control->Attach(file_fd, timeout_ms, path)) in CheckCreateLoopDevice()