Home
last modified time | relevance | path

Searched refs:block_device (Results 1 – 25 of 278) sorted by relevance

12345678910>>...12

/aosp12/system/core/fs_mgr/
H A Dfs_mgr_dm_linear.cpp56 const LpMetadataBlockDevice& block_device, in GetPhysicalPartitionDevicePath() argument
61 std::string name = GetBlockDevicePartitionName(block_device); in GetPhysicalPartitionDevicePath()
74 if (GetMetadataSuperBlockDevice(*params.metadata) == &block_device) { in GetPhysicalPartitionDevicePath()
93 const auto& super_device = params.block_device; in CreateDmTableInternal()
139 bool CreateLogicalPartitions(const std::string& block_device) { in CreateLogicalPartitions() argument
141 auto metadata = ReadMetadata(block_device.c_str(), slot); in CreateLogicalPartitions()
146 return CreateLogicalPartitions(*metadata.get(), block_device); in CreateLogicalPartitions()
151 return ReadMetadata(block_device.c_str(), slot); in ReadCurrentMetadata()
156 .block_device = super_device, in CreateLogicalPartitions()
181 if (block_device.empty()) { in InitDefaults()
[all …]
H A Dfs_mgr.cpp652 std::string block_device; in SetReadAheadSize() local
687 block_device = *parent; in SetReadAheadSize()
1169 auto actual_block_device = block_device.empty() ? entry->blk_device : block_device; in UpdateCheckpointPartition()
1321 const auto& block_device = local
1707 std::string block_device; in fs_mgr_unmount_all_data_mounts() local
1749 std::string current = block_device; in UnwindDmDeviceStack()
1776 std::string block_device; in fs_mgr_get_mounted_entry_for_userdata() local
1782 block_device = entry.blk_device; in fs_mgr_get_mounted_entry_for_userdata()
1785 block_device = entry.blk_device; in fs_mgr_get_mounted_entry_for_userdata()
1807 std::string block_device; in fs_mgr_remount_userdata_into_checkpointing() local
[all …]
/aosp12/system/core/fs_mgr/liblp/
H A Dpartition_opener.cpp65 bool GetBlockDeviceInfo(const std::string& block_device, BlockDeviceInfo* device_info) { in GetBlockDeviceInfo() argument
67 unique_fd fd = GetControlFileOrOpen(block_device.c_str(), O_RDONLY); in GetBlockDeviceInfo()
69 PERROR << __PRETTY_FUNCTION__ << "open '" << block_device << "' failed"; in GetBlockDeviceInfo()
76 PERROR << __PRETTY_FUNCTION__ << "BLKIOMIN failed on " << block_device; in GetBlockDeviceInfo()
82 PERROR << __PRETTY_FUNCTION__ << "BLKALIGNOFF failed on " << block_device; in GetBlockDeviceInfo()
93 PERROR << __PRETTY_FUNCTION__ << "BLKSSZGET failed on " << block_device; in GetBlockDeviceInfo()
99 device_info->partition_name = android::base::Basename(block_device); in GetBlockDeviceInfo()
102 (void)block_device; in GetBlockDeviceInfo()
H A Dwriter.cpp116 for (const auto& block_device : metadata.block_devices) { variable
117 std::string partition_name = GetBlockDevicePartitionName(block_device);
118 if (block_device.flags & LP_BLOCK_DEVICE_SLOT_SUFFIXED) {
127 if ((block_device.first_logical_sector + 1) * LP_SECTOR_SIZE > block_device.size) {
129 << block_device.first_logical_sector << " for size " << block_device.size;
141 if (info.size != block_device.size) {
143 << block_device.size << ", got " << info.size << ")";
H A Dbuilder.cpp635 const auto& block_device = block_devices_[i]; in GetFreeRegions() local
885 for (const auto& block_device : block_devices_) { in Export() local
886 metadata->block_devices.emplace_back(block_device); in Export()
972 for (const auto& block_device : block_devices_) { in AllocatableSpace() local
973 total_size += block_device.size - (block_device.first_logical_sector * LP_SECTOR_SIZE); in AllocatableSpace()
991 if (!AlignTo(lba, block_device.alignment, out)) { in AlignSector()
1045 LpMetadataBlockDevice& block_device = block_devices_[index]; in UpdateBlockDeviceInfo() local
1046 if (device_info.size != block_device.size) { in UpdateBlockDeviceInfo()
1048 << block_device.size << ")"; in UpdateBlockDeviceInfo()
1061 block_device.alignment = device_info.alignment; in UpdateBlockDeviceInfo()
[all …]
H A Dreader.cpp412 for (auto& block_device : metadata->block_devices) { in AdjustMetadataForSlot() local
413 if (!(block_device.flags & LP_BLOCK_DEVICE_SLOT_SUFFIXED)) { in AdjustMetadataForSlot()
416 std::string partition_name = GetBlockDevicePartitionName(block_device) + slot_suffix; in AdjustMetadataForSlot()
417 if (!UpdateBlockDevicePartitionName(&block_device, partition_name)) { in AdjustMetadataForSlot()
421 block_device.flags &= ~LP_BLOCK_DEVICE_SLOT_SUFFIXED; in AdjustMetadataForSlot()
499 std::string GetBlockDevicePartitionName(const LpMetadataBlockDevice& block_device) { in GetBlockDevicePartitionName() argument
500 return NameFromFixedArray(block_device.partition_name, sizeof(block_device.partition_name)); in GetBlockDevicePartitionName()
H A Dutility.cpp130 for (const auto& block_device : metadata.block_devices) { in GetTotalSuperPartitionSize() local
131 size += block_device.size; in GetTotalSuperPartitionSize()
138 for (const auto& block_device : metadata.block_devices) { in GetBlockDevicePartitionNames() local
139 list.emplace_back(GetBlockDevicePartitionName(block_device)); in GetBlockDevicePartitionNames()
/aosp12/system/extras/ioblame/
H A Dioblame.sh68 block_device=mmcblk0
74 block_device=mmcblk0
79 block_device=mmcblk0
84 block_device=sda
89block_device=`adb shell 'find /dev/block/platform -name by-name | xargs ls -l' | grep system | awk…
91 block_device=`echo $block_device | awk 'BEGIN { FS ="/" } ; { print $4 }' | sed 's/p.*//g' `
97 DISKSTATS=`adb shell 'cat /proc/diskstats' | fgrep -w $block_device `
113 DISKSTATS=`adb shell 'cat /proc/diskstats' | fgrep -w $block_device `
133 echo "Total (ALL) Read KB $block_device = "$READ_KB
136 echo "Total (ALL) Read IOs $block_device = "`expr $AFTER_RD_IOS - $BEFORE_RD_IOS`
[all …]
/aosp12/frameworks/base/tests/ApkVerityTest/block_device_writer/
H A Dblock_device_writer.cpp54 const char* block_device; member
81 ssize_t get_logical_block_size(const char* block_device) { in get_logical_block_size() argument
82 android::base::unique_fd fd(open(block_device, O_RDONLY)); in get_logical_block_size()
84 fprintf(stderr, "open %s failed\n", block_device); in get_logical_block_size()
195 args->block_device = *(arg++); in parse_args()
211 ssize_t block_size = get_logical_block_size(args->block_device); in main()
234 if (read_block_from_device(args->block_device, physical_block_offset, block_size, in main()
242 if (write_block_to_device(args->block_device, physical_block_offset, block_size, in main()
/aosp12/system/extras/verity/
H A Dbuild_verity_metadata.py63 def build_verity_table(block_device, data_blocks, root_hash, salt): argument
65 table %= ( block_device,
66 block_device,
76 block_device, signer_path, signing_key, signer_args=None, argument
79 verity_table = build_verity_table(block_device, data_blocks, root_hash, salt)
115 args.root_hash, args.salt, args.block_device,
/aosp12/system/core/fs_mgr/include/
H A Dfs_mgr_dm_linear.h43 std::unique_ptr<LpMetadata> ReadCurrentMetadata(const std::string& block_device);
47 bool CreateLogicalPartitions(const LpMetadata& metadata, const std::string& block_device);
51 bool CreateLogicalPartitions(const std::string& block_device);
55 std::string block_device; member
/aosp12/system/core/set-verity-state/
H A Dset-verity-state.cpp63 static bool set_verity_enabled_state(const char* block_device, const char* mount_point, in set_verity_enabled_state() argument
65 if (!make_block_device_writable(block_device)) { in set_verity_enabled_state()
66 printf("Could not make block device %s writable (%s).\n", block_device, strerror(errno)); in set_verity_enabled_state()
70 fec::io fh(block_device, O_RDWR); in set_verity_enabled_state()
73 printf("Could not open block device %s (%s).\n", block_device, strerror(errno)); in set_verity_enabled_state()
97 enable ? "enabled" : "disabled", block_device, strerror(errno)); in set_verity_enabled_state()
/aosp12/system/extras/partition_tools/
H A Dlpdump.cc163 for (const auto& block_device : metadata->block_devices) { in MergeMetadata() local
164 std::string name = GetBlockDevicePartitionName(block_device); in MergeMetadata()
301 const auto& block_device = pt.block_devices[extent.target_source]; in ParseLinearExtentData() local
302 std::string device_name = GetBlockDevicePartitionName(block_device); in ParseLinearExtentData()
332 const auto& block_device = pt.block_devices[extent.target_source]; in PrintMetadata() local
333 std::string device_name = GetBlockDevicePartitionName(block_device); in PrintMetadata()
355 auto&& [block_device, offset] = *data; in PrintMetadata()
363 for (const auto& block_device : pt.block_devices) { in PrintMetadata() local
364 std::string partition_name = GetBlockDevicePartitionName(block_device); in PrintMetadata()
366 cout << " First sector: " << block_device.first_logical_sector << "\n"; in PrintMetadata()
[all …]
/aosp12/system/core/fs_mgr/libfiemap/
H A Dimage_manager.cpp222 std::string block_device; in ZeroFillNewImage() local
224 if (!FiemapWriter::GetBlockDeviceForFile(data_path, &block_device, &can_use_devicemapper)) { in ZeroFillNewImage()
307 auto block_device = android::fs_mgr::GetBlockDevicePartitionName(*super); in MapWithDmLinear() local
310 .block_device = block_device, in MapWithDmLinear()
398 for (const auto& block_device : device_list) { in MapWithLoopDeviceList() local
402 unique_fd fd(open(block_device.c_str(), kOpenFlags)); in MapWithLoopDeviceList()
404 PLOG(ERROR) << "Open failed: " << block_device; in MapWithLoopDeviceList()
412 table.Emplace<DmTargetLinear>(start_sector, segment_size, block_device, 0); in MapWithLoopDeviceList()
430 for (const auto& block_device : device_list) { in MapWithLoopDeviceList() local
431 lines.emplace_back("loop:" + block_device); in MapWithLoopDeviceList()
[all …]
H A Dmetadata.cpp131 auto block_device = android::base::Basename(GetDevicePathForFile(file)); in FillPartitionExtents() local
154 if (!builder->AddLinearExtent(partition, block_device, num_sectors, physical_sector)) { in FillPartitionExtents()
/aosp12/system/vold/
H A Dsecdiscard.cpp172 auto block_device = android::vold::BlockDeviceForPath(path); in secdiscard_path() local
173 if (block_device.empty()) { in secdiscard_path()
177 TEMP_FAILURE_RETRY(open(block_device.c_str(), O_RDWR | O_LARGEFILE | O_CLOEXEC, 0))); in secdiscard_path()
179 PLOG(ERROR) << "Failed to open device " << block_device; in secdiscard_path()
/aosp12/system/core/fs_mgr/libdm/include/libdm/
H A Ddm_target.h106 DmTargetLinear(uint64_t start, uint64_t length, const std::string& block_device, in DmTargetLinear() argument
108 : DmTarget(start, length), block_device_(block_device), physical_sector_(physical_sector) {} in DmTargetLinear()
112 const std::string& block_device() const { return block_device_; } in block_device() function
122 const std::string& block_device, const std::string& hash_device,
143 DmTargetAndroidVerity(uint64_t start, uint64_t length, const std::string& block_device, in DmTargetAndroidVerity() argument
145 : DmTarget(start, length), keyid_(keyid), block_device_(block_device) {} in DmTargetAndroidVerity()
/aosp12/system/sepolicy/prebuilts/api/27.0/public/
H A De2fs.te4 allow e2fs block_device:blk_file getattr;
5 allow e2fs block_device:dir search;
/aosp12/system/core/fs_mgr/tools/
H A Ddmctl.cpp98 std::string block_device = NextArg(); in Next() local
104 return std::make_unique<DmTargetLinear>(start_sector, num_sectors, block_device, in Next()
113 std::string block_device = NextArg(); in Next() local
115 block_device); in Next()
121 std::string block_device = NextArg(); in Next() local
122 return std::make_unique<DmTargetBow>(start_sector, num_sectors, block_device); in Next()
128 std::string block_device = NextArg(); in Next() local
130 block_device); in Next()
/aosp12/system/update_engine/payload_consumer/
H A Dpartition_update_generator_android.cc156 const std::string& block_device, int64_t partition_size) { in CalculateHashForPartition() argument
164 if (HashCalculator::RawHashOfFile(block_device, partition_size, &raw_hash) != in CalculateHashForPartition()
166 LOG(ERROR) << "Failed to calculate hash for " << block_device; in CalculateHashForPartition()
/aosp12/bootable/recovery/updater/include/updater/
H A Dbuild_info.h31 FakeBlockDevice(std::string block_device, std::string mount_point, std::string temp_file_path) in FakeBlockDevice() argument
32 : blockdev_name(std::move(block_device)), in FakeBlockDevice()
/aosp12/system/sepolicy/prebuilts/api/31.0/private/
H A Dkernel.te21 allow kernel block_device:blk_file relabelto;
22 allow kernel block_device:lnk_file relabelto;
/aosp12/system/sepolicy/prebuilts/api/32.0/private/
H A Dkernel.te21 allow kernel block_device:blk_file relabelto;
22 allow kernel block_device:lnk_file relabelto;
/aosp12/system/sepolicy/private/
H A Dkernel.te21 allow kernel block_device:blk_file relabelto;
22 allow kernel block_device:lnk_file relabelto;
/aosp12/system/core/fs_mgr/libsnapshot/
H A Dsnapshot_fuzz.cpp154 params.block_device = GetSnapshotFuzzEnv()->super(); in SNAPSHOT_FUZZ_FUNCTION()
156 params.block_device = params_proto.block_device(); in SNAPSHOT_FUZZ_FUNCTION()

12345678910>>...12