• Home
  • Raw
  • Download

Lines Matching refs:path

46 bool secdiscard_path(const std::string &path);
47 std::unique_ptr<struct fiemap> path_fiemap(const std::string &path, uint32_t extent_count);
48 bool check_fiemap(const struct fiemap &fiemap, const std::string &path);
50 std::string block_device_for_path(const std::string &path);
101 bool secdiscard_path(const std::string &path) { in secdiscard_path() argument
102 auto fiemap = path_fiemap(path, max_extents); in secdiscard_path()
103 if (!fiemap || !check_fiemap(*fiemap, path)) { in secdiscard_path()
106 auto block_device = block_device_for_path(path); in secdiscard_path()
120 PLOG(ERROR) << "Unable to BLKSECDISCARD " << path; in secdiscard_path()
129 std::unique_ptr<struct fiemap> path_fiemap(const std::string &path, uint32_t extent_count) in path_fiemap() argument
131 AutoCloseFD fd(path); in path_fiemap()
134 PLOG(DEBUG) << "Unable to open " << path; in path_fiemap()
136 PLOG(ERROR) << "Unable to open " << path; in path_fiemap()
142 PLOG(ERROR) << "Unable to FIEMAP " << path; in path_fiemap()
148 << " in " << path; in path_fiemap()
155 bool check_fiemap(const struct fiemap &fiemap, const std::string &path) { in check_fiemap() argument
158 LOG(ERROR) << "Extent " << mapped -1 << " was not the last in " << path; in check_fiemap()
164 LOG(ERROR) << "Extent " << i << " has unexpected flags " << flags << ": " << path; in check_fiemap()
185 std::string block_device_for_path(const std::string &path) in block_device_for_path() argument
198 path.size() > l && in block_device_for_path()
199 path[l] == '/' && in block_device_for_path()
200 path.compare(0, l, mnt->mnt_dir) == 0) { in block_device_for_path()
206 LOG(ERROR) <<"Didn't find a mountpoint to match path " << path; in block_device_for_path()
209 LOG(DEBUG) << "For path " << path << " block device is " << result; in block_device_for_path()