Home
last modified time | relevance | path

Searched refs:blk_device (Results 1 – 25 of 37) sorted by relevance

12

/system/core/fs_mgr/
Dfs_mgr.cpp137 static void log_fs_stat(const std::string& blk_device, int fs_stat) { in log_fs_stat() argument
139 android::base::StringPrintf("\nfs_stat,%s,0x%x\n", blk_device.c_str(), fs_stat); in log_fs_stat()
155 static std::string realpath(const std::string& blk_device) { in realpath() argument
157 if (!Realpath(blk_device, &real_path)) { in realpath()
158 real_path = blk_device; in realpath()
187 static void check_fs(const std::string& blk_device, const std::string& fs_type, in check_fs() argument
193 const char* e2fsck_argv[] = {E2FSCK_BIN, "-y", blk_device.c_str()}; in check_fs()
194 const char* e2fsck_forced_argv[] = {E2FSCK_BIN, "-f", "-y", blk_device.c_str()}; in check_fs()
222 ret = mount(blk_device.c_str(), target.c_str(), fs_type.c_str(), tmpmnt_flags, in check_fs()
224 PINFO << __FUNCTION__ << "(): mount(" << blk_device << "," << target << "," << fs_type in check_fs()
[all …]
Dfs_mgr_remount.cpp354 auto blk_device = entry.blk_device; in RemountPartition() local
361 blk_device = rentry.blk_device; in RemountPartition()
368 blk_device = rentry.blk_device; in RemountPartition()
375 PLOG(INFO) << "skip unmounted partition dev:" << blk_device << " mnt:" << mount_point; in RemountPartition()
378 if (blk_device == "/dev/root") { in RemountPartition()
380 if (from_fstab) blk_device = from_fstab->blk_device; in RemountPartition()
382 fs_mgr_set_blk_ro(blk_device, false); in RemountPartition()
392 if (::mount(blk_device.c_str(), mnt_point.c_str(), entry.fs_type.c_str(), MS_REMOUNT, in RemountPartition()
402 PLOG(ERROR) << "failed to remount partition dev:" << blk_device << " mnt:" << mount_point; in RemountPartition()
Dfs_mgr_slotselect.cpp72 entry.blk_device = entry.blk_device + update_suffix; in fs_mgr_update_for_slotselect()
Dfs_mgr_fstab.cpp459 std::string blk_device = entry.blk_device; in ExtraBootDevices() local
461 if (!android::base::StartsWith(blk_device, "/dev/block") || in ExtraBootDevices()
462 android::base::StartsWith(blk_device, "/dev/block/by-name") || in ExtraBootDevices()
463 android::base::StartsWith(blk_device, "/dev/block/bootdevice/by-name")) { in ExtraBootDevices()
469 auto slash_by_name = blk_device.find("/by-name"); in ExtraBootDevices()
471 blk_device.erase(slash_by_name); // erases /by-name/<partition> in ExtraBootDevices()
474 blk_device.erase(0, std::string("/dev/block/").size()); in ExtraBootDevices()
478 auto first_slash = blk_device.find('/'); in ExtraBootDevices()
481 auto boot_device = blk_device.substr(first_slash + 1); in ExtraBootDevices()
562 entry.blk_device = std::move(*it++); in ParseFstabFromString()
[all …]
Dfs_mgr_priv.h97 bool fs_mgr_is_ext4(const std::string& blk_device);
98 bool fs_mgr_is_f2fs(const std::string& blk_device);
Dfs_mgr_format.cpp163 LERROR << __FUNCTION__ << ": Format " << entry.blk_device << " as '" << entry.fs_type << "'"; in fs_mgr_do_format()
173 return format_f2fs(entry.blk_device, entry.length, needs_projid, needs_casefold, in fs_mgr_do_format()
176 return format_ext4(entry.blk_device, entry.mount_point, needs_projid, in fs_mgr_do_format()
Dfs_mgr_overlayfs.cpp177 if (fs_mgr_access(entry->blk_device)) { in fs_mgr_update_blk_device()
180 if (entry->blk_device != "/dev/root") { in fs_mgr_update_blk_device()
185 auto blk_device = kPhysicalDevice + "system"; in fs_mgr_update_blk_device() local
186 if (!fs_mgr_access(blk_device)) { in fs_mgr_update_blk_device()
187 blk_device += fs_mgr_get_slot_suffix(); in fs_mgr_update_blk_device()
188 if (!fs_mgr_access(blk_device)) { in fs_mgr_update_blk_device()
192 entry->blk_device = blk_device; in fs_mgr_update_blk_device()
251 if (fs_mgr_is_read_only_f2fs(entry->blk_device)) { in fs_mgr_overlayfs_enabled()
256 auto has_shared_blocks = fs_mgr_has_shared_blocks(entry->mount_point, entry->blk_device); in fs_mgr_overlayfs_enabled()
258 has_shared_blocks = fs_mgr_has_shared_blocks("/", entry->blk_device); in fs_mgr_overlayfs_enabled()
[all …]
/system/core/init/
Dmount_handler.cpp63 fields[0] = entry->blk_device; in ParseMount()
108 if (!android::base::StartsWith(entry.blk_device, devblock)) return; in SetMountProperty()
109 auto target = entry.blk_device.substr(strlen(devblock)); in SetMountProperty()
155 MountHandlerEntry::MountHandlerEntry(const std::string& blk_device, const std::string& mount_point, in MountHandlerEntry() argument
157 : blk_device(blk_device), mount_point(mount_point), fs_type(fs_type) {} in MountHandlerEntry()
160 if (blk_device < r.blk_device) return true; in operator <()
161 if (blk_device > r.blk_device) return false; in operator <()
Dmount_handler.h31 MountHandlerEntry(const std::string& blk_device, const std::string& mount_point,
36 const std::string blk_device; member
Dfirst_stage_mount.cpp418 if (!block_dev_init_.InitDmDevice(begin->blk_device)) { in MountPartition()
435 current->blk_device = begin->blk_device; in MountPartition()
700 logical_partitions.emplace(basename(fstab_entry.blk_device.c_str())); in GetDmVerityDevices()
702 devices->emplace(basename(fstab_entry.blk_device.c_str())); in GetDmVerityDevices()
776 return block_dev_init_.InitDmDevice(fstab_entry->blk_device); in SetUpDmVerity()
/system/vold/
DMetadataCrypt.cpp98 static bool mount_via_fs_mgr(const char* mount_point, const char* blk_device, bool needs_encrypt) { in mount_via_fs_mgr() argument
106 const_cast<char*>(blk_device), nullptr, in mount_via_fs_mgr()
156 static bool create_crypto_blk_dev(const std::string& dm_name, const std::string& blk_device, in create_crypto_blk_dev() argument
159 if (!get_number_of_sectors(blk_device, nr_sec)) return false; in create_crypto_blk_dev()
182 hex_key, blk_device, 0); in create_crypto_blk_dev()
242 bool fscrypt_mount_metadata_encrypted(const std::string& blk_device, const std::string& mount_point, in fscrypt_mount_metadata_encrypted() argument
247 << fs_type << " block device: " << blk_device in fscrypt_mount_metadata_encrypted()
300 if (!create_crypto_blk_dev(kDmNameUserdata, blk_device, key, options, &crypto_blkdev, in fscrypt_mount_metadata_encrypted()
346 if (!encrypt_inplace(crypto_blkdev, blk_device, nr_sec)) { in fscrypt_mount_metadata_encrypted()
375 bool defaultkey_setup_ext_volume(const std::string& label, const std::string& blk_device, in defaultkey_setup_ext_volume() argument
[all …]
DMetadataCrypt.h36 bool defaultkey_setup_ext_volume(const std::string& label, const std::string& blk_device,
DCheckpoint.cpp207 if (mount(mount_rec.blk_device.c_str(), mount_rec.mount_point.c_str(), "none", in cp_commitChanges()
213 if (!setBowState(mount_rec.blk_device, "2")) in cp_commitChanges()
322 static void cp_healthDaemon(std::string mnt_pnt, std::string blk_device, bool is_fs_cp) { in cp_healthDaemon() argument
339 std::string bow_device = fs_mgr_find_bow_device(blk_device); in cp_healthDaemon()
400 isBow &= setBowState(mount_rec.blk_device, "1"); in cp_prepareCheckpoint()
404 std::string(mount_rec.blk_device), in cp_prepareCheckpoint()
Dmain.cpp254 PLOG(FATAL) << "could not find logical partition " << entry.blk_device; in process_config()
268 std::string sysPattern(entry.blk_device); in process_config()
/system/extras/boot_control_copy/
Dbootinfo.cpp76 path = strdup(record->blk_device.c_str()); in boot_info_open_partition()
79 const char* end_slash = strrchr(record->blk_device.c_str(), '/'); in boot_info_open_partition()
83 trimmed_len = end_slash - record->blk_device.c_str() + 1; in boot_info_open_partition()
86 strncpy(path, record->blk_device.c_str(), trimmed_len); in boot_info_open_partition()
/system/vold/model/
DVolumeEncryption.cpp79 bool setup_ext_volume(const std::string& label, const std::string& blk_device, in setup_ext_volume() argument
86 return cryptfs_setup_ext_volume(label.c_str(), blk_device.c_str(), key, in setup_ext_volume()
89 return defaultkey_setup_ext_volume(label, blk_device, key, out_crypto_blkdev); in setup_ext_volume()
DVolumeEncryption.h28 bool setup_ext_volume(const std::string& label, const std::string& blk_device,
/system/core/fs_mgr/libfs_avb/
Dfs_avb_util.cpp50 std::string device_path = fstab_entry.blk_device; in LoadAndVerifyVbmeta()
52 !android::base::StartsWith(fstab_entry.blk_device, "/")) { in LoadAndVerifyVbmeta()
54 if (!dm.GetDmDevicePathByName(fstab_entry.blk_device, &device_path)) { in LoadAndVerifyVbmeta()
55 LERROR << "Failed to resolve logical device path for: " << fstab_entry.blk_device; in LoadAndVerifyVbmeta()
Davb_util.cpp42 const std::string& blk_device, android::dm::DmTable* table) { in ConstructVerityTable() argument
66 0, hashtree_desc.image_size / 512, hashtree_desc.dm_verity_version, blk_device, in ConstructVerityTable()
67 blk_device, hashtree_desc.data_block_size, hashtree_desc.hash_block_size, in ConstructVerityTable()
72 target.UseFec(blk_device, hashtree_desc.fec_num_roots, in ConstructVerityTable()
94 if (!ConstructVerityTable(hashtree_desc, fstab_entry->blk_device, &table) || !table.valid()) { in HashtreeDmVeritySetup()
112 SetBlockDeviceReadOnly(fstab_entry->blk_device); in HashtreeDmVeritySetup()
115 fstab_entry->blk_device = dev_path; in HashtreeDmVeritySetup()
238 partition_name = Basename(fstab_entry.blk_device); in DeriveAvbPartitionName()
Davb_ops.cpp161 if (!dm.GetDmDevicePathByName(fstab_entry->blk_device, &device_path)) { in GetLogicalPath()
162 LERROR << "Failed to resolve logical device path for: " << fstab_entry->blk_device; in GetLogicalPath()
/system/extras/squashfs_utils/
Dsquashfs_utils.c60 int squashfs_parse_sb(const char *blk_device, struct squashfs_info *info) in squashfs_parse_sb() argument
66 data_device = TEMP_FAILURE_RETRY(open(blk_device, O_RDONLY | O_CLOEXEC)); in squashfs_parse_sb()
Dsquashfs_utils.h36 int squashfs_parse_sb(const char *blk_device, struct squashfs_info *info);
/system/core/fs_mgr/tests/
Dfs_mgr_test.cpp269 EXPECT_EQ(mentry->mnt_fsname, entry.blk_device); in TEST()
1047 ASSERT_TRUE(android::base::Realpath(mounted_entry->blk_device, &block_device)); in TEST()
1131 EXPECT_EQ("userdata_gsi", entry->blk_device); in TEST()
1135 EXPECT_EQ("system_gsi", entry->blk_device); in TEST()
1140 EXPECT_EQ("system_gsi", entry->blk_device); in TEST()
1145 EXPECT_EQ("vendor", entry->blk_device); in TEST()
1168 EXPECT_EQ("system_gsi", entry->blk_device); in TEST()
1173 EXPECT_EQ("system_gsi", entry->blk_device); in TEST()
1178 EXPECT_EQ("vendor", entry->blk_device); in TEST()
1182 EXPECT_EQ("userdata_gsi", entry->blk_device); in TEST()
[all …]
/system/gsid/tests/
Dboot_tests.cpp62 unique_fd fd(open(entry->blk_device.c_str(), O_RDONLY | O_CLOEXEC)); in TEST()
/system/core/fs_mgr/include_fstab/fstab/
Dfstab.h33 std::string blk_device; member

12