/base/update/updater/services/updater_binary/ |
H A D | update_image_block.h | 36 bool ExecReadBlockInfo(const std::string &devPath, Uscript::UScriptContext &context,
52 int ExecReadShaInfo(Uscript::UScriptEnv &env, const std::string &devPath, const ShaInfo &shaInfo,
54 int32_t DoBlocksVerify(Uscript::UScriptEnv &env, const std::string &partitionName, const std::string &devPath);
55 void PrintAbnormalBlockHash(const std::string &devPath, const std::string &blockPairs);
56 std::string CalculateBlockSha(const std::string &devPath, const std::string &blockPairs);
58 bool IsTargetShaDiff(const std::string &devPath, const ShaInfo &shaInfo);
|
H A D | update_image_block.cpp | 141 std::string devPath;
member 179 infos.devPath = GetBlockDeviceByMountPoint(infos.partitionName);
in GetUpdateBlockInfo() 180 LOG(INFO) << "ExecuteUpdateBlock::updating dev path : " << infos.devPath;
in GetUpdateBlockInfo() 181 if (infos.devPath.empty()) {
in GetUpdateBlockInfo() 196 transferParams->devPath = infos.devPath;
in ExecuteTransferCommand() 286 int fd = open(infos.devPath.c_str(), O_RDWR | O_LARGEFILE);
in DoExecuteUpdateBlock() 397 bool UScriptInstructionBlockCheck::ExecReadBlockInfo(const std::string &devPath, Uscript::UScriptContext &context,
in ExecReadBlockInfo() argument 401 int fd = open(devPath.c_str(), O_RDWR | O_LARGEFILE);
in ExecReadBlockInfo() 453 auto devPath in Execute() local 484 DoBlocksVerify(Uscript::UScriptEnv &env, const std::string &partitionName, const std::string &devPath) DoBlocksVerify() argument 536 IsTargetShaDiff(const std::string &devPath, const ShaInfo &shaInfo) IsTargetShaDiff() argument 547 ExecReadShaInfo(Uscript::UScriptEnv &env, const std::string &devPath, const ShaInfo &shaInfo, const std::string &partitionName) ExecReadShaInfo() argument 567 PrintAbnormalBlockHash(const std::string &devPath, const std::string &blockPairs) PrintAbnormalBlockHash() argument 603 CalculateBlockSha(const std::string &devPath, const std::string &blockPairs) CalculateBlockSha() argument 704 auto devPath = GetBlockDeviceByMountPoint(partitionName); Execute() local [all...] |
H A D | update_image_patch.cpp | 72 para.devPath = GetBlockDeviceByMountPoint(para.partName);
in GetParam() 73 if (para.devPath.empty()) {
in GetParam() 100 std::unique_ptr<DataWriter> writer = DataWriter::CreateDataWriter(WRITE_RAW, para.devPath);
in ApplyPatch() 167 if (!Utils::CopyFile(para.devPath, srcFile)) {
in GetSourceFile() 168 LOG(ERROR) << "copy " << para.devPath << " to " << srcFile << " failed";
in GetSourceFile() 253 para.devPath = GetBlockDeviceByMountPoint(para.partName);
in GetParam() 254 if (para.devPath.empty()) {
in GetParam() 258 LOG(INFO) << "dev path: " << para.devPath;
in GetParam() 265 if (PatchMapFile(para.devPath, mapBuffer) != UpdatePatch::PATCH_SUCCESS) {
in CheckHash()
|
H A D | update_image_patch.h | 29 std::string devPath {};
54 std::string devPath {};
|
/base/update/sys_installer/services/module_update/src/ |
H A D | module_dm.cpp | 58 char *devPath = nullptr; in CreateDmDevice() local 77 ret = FsDmCreateDevice(&devPath, devName.c_str(), &target); in CreateDmDevice() 82 ret = FsDmInitDmDev(devPath, true); in CreateDmDevice() 87 deviceName = std::string(devPath); in CreateDmDevice() 89 free(devPath); in CreateDmDevice()
|
/base/startup/init/ueventd/ |
H A D | ueventd_device_handler.c | 428 char *devPath = NULL; in GetDeviceBasePath() local 430 return devPath; in GetDeviceBasePath() 434 devPath = "/dev/block"; in GetDeviceBasePath() 436 devPath = "/dev/input"; in GetDeviceBasePath() 438 devPath = "/dev/dri"; in GetDeviceBasePath() 440 devPath = "/dev/graphics"; in GetDeviceBasePath() 442 devPath = "/dev/snd"; in GetDeviceBasePath() 444 devPath = "/dev/functionfs"; in GetDeviceBasePath() 446 devPath = "/dev/dma_heap"; in GetDeviceBasePath() 448 devPath in GetDeviceBasePath() 472 const char *devPath = GetDeviceBasePath(uevent->subsystem); HandleBlockDeviceEvent() local 514 const char *devPath = GetDeviceBasePath(uevent->subsystem); HandleOtherDeviceEvent() local [all...] |
/base/update/updater/services/fs_manager/ |
H A D | partitions.cpp | 31 if (!stat (dev.devPath.c_str(), &devStat)) { in DeviceStat() 34 if (stat (dev.devPath.c_str(), &devStat) != EOK) { in DeviceStat() 91 LastComponent(dev.devPath).c_str(), file.c_str()) == -1) { in ReadDeviceSysfsFile() 125 specific->fd = open(dev.devPath.c_str(), RW_MODE); in SetBlockDeviceMode() 127 LOG(WARNING) << "Open " << dev.devPath << " with read-write failed, try read-only mode"; in SetBlockDeviceMode() 128 specific->fd = open(dev.devPath.c_str(), RD_MODE); in SetBlockDeviceMode() 132 LOG(ERROR) << "Open " << dev.devPath << " with read-only mode failed: " << errno; in SetBlockDeviceMode() 156 std::string devPath; in ReadPartitionFromSys() local 158 devPath = "/sys/block/" + devname + "/" + partn + "/" + type; in ReadPartitionFromSys() 160 devPath in ReadPartitionFromSys() [all...] |
H A D | mount.cpp | 221 void ErasePartition(const std::string &devPath) in ErasePartition() argument 224 if (!Utils::PathToRealPath(devPath, realPath)) { in ErasePartition() 225 LOG(ERROR) << "realpath failed:" << devPath; in ErasePartition()
|
/base/update/updater/test/unittest/applypatch_test/ |
H A D | applypatch_unittest.cpp | 62 auto devPath = GetBlockDeviceByMountPoint(partitionName); in TearDown() local 63 unlink(devPath.c_str()); in TearDown() 88 auto devPath = GetBlockDeviceByMountPoint(partitionName); in HWTEST_F() local 91 close(open(devPath.c_str(), O_CREAT | O_WRONLY | O_EXCL, 0664)); in HWTEST_F() 95 int fd = open(devPath.c_str(), O_RDONLY); in HWTEST_F()
|
/base/msdp/device_status/intention/services/device_manager/src/ |
H A D | device_manager.cpp | 151 std::shared_ptr<IDevice> DeviceManager::FindDevice(const std::string &devPath) in FindDevice() argument 154 [devPath](const auto &item) { in FindDevice() 155 return ((item.second != nullptr) && (item.second->GetDevPath() == devPath)); in FindDevice() 177 const std::string devPath { DEV_INPUT_PATH + devNode }; in AddDevice() 180 if (stat(devPath.c_str(), &statbuf) != 0) { in AddDevice() 181 FI_HILOGD("Invalid device path:%{private}s", devPath.c_str()); in AddDevice() 185 FI_HILOGD("Not character device:%{public}s", devPath.c_str()); in AddDevice() 195 std::shared_ptr<IDevice> dev = FindDevice(devPath); in AddDevice() 197 FI_HILOGD("Already exists:%{public}s", devPath.c_str()); in AddDevice() 209 dev->SetDevPath(devPath); in AddDevice() [all...] |
H A D | enumerator.cpp | 55 const std::string devPath { DEV_INPUT_PATH + devNode }; in ScanAndAddDevices() 58 if (stat(devPath.c_str(), &statbuf) != 0) { in ScanAndAddDevices()
|
/base/startup/init/interfaces/innerkits/fs_manager/libfs_hvb/ |
H A D | fs_hvb.c | 364 static int FsHvbVerityTargetAddFecArgs(struct hvb_cert *cert, char *devPath, char **str, char *end) in FsHvbVerityTargetAddFecArgs() argument 367 FS_HVB_RETURN_ERR_IF_NULL(devPath); in FsHvbVerityTargetAddFecArgs() 373 RETURN_ERR_IF_APPEND_STRING_ERR(str, end, &devPath[0], strlen(devPath)); in FsHvbVerityTargetAddFecArgs() 409 char devPath[FS_HVB_DEVPATH_MAX_LEN] = {0}; in FsHvbConstructVerityTarget() local 423 if (snprintf_s(&devPath[0], sizeof(devPath), sizeof(devPath) - 1, "%s%s", in FsHvbConstructVerityTarget() 425 BEGET_LOGE("error, snprintf_s devPath"); in FsHvbConstructVerityTarget() 435 RETURN_ERR_IF_APPEND_STRING_ERR(&p, end, &devPath[ in FsHvbConstructVerityTarget() [all...] |
/base/update/updater/test/unittest/updater_binary/ |
H A D | update_processor_unittest.cpp | 49 string devPath = GetBlockDeviceByMountPoint(UT_MISC_PARTITION_NAME);
in SetUp() local 51 auto ret = Store::WriteDataToStore("/", devPath, buffer, UT_MISC_BUFFER_SIZE);
in SetUp() 60 string devPath = GetBlockDeviceByMountPoint(UT_MISC_PARTITION_NAME);
in TearDown() local 61 auto ret = Store::FreeStore("/", devPath);
in TearDown()
|
/base/startup/init/interfaces/innerkits/fs_manager/libfs_dm/include/ |
H A D | fs_dm.h | 37 int FsDmInitDmDev(char *devPath, bool useSocket);
|
/base/powermgr/battery_manager/charger/src/dev/ |
H A D | fbdev_driver.cpp | 108 void FbdevDriver::SetDevPath(const std::string& devPath) in SetDevPath() argument 110 devPath_ = devPath; in SetDevPath()
|
/base/powermgr/battery_manager/charger/include/dev/ |
H A D | fbdev_driver.h | 46 static void SetDevPath(const std::string& devPath);
|
/base/update/updater/services/ui/driver/ |
H A D | fbdev_driver.h | 45 static void SetDevPath(const std::string &devPath);
|
H A D | fbdev_driver.cpp | 145 void FbdevDriver::SetDevPath(const std::string &devPath) in SetDevPath() argument 147 devPath_ = devPath; in SetDevPath()
|
/base/update/updater/services/diffpatch/patch_shared/ |
H A D | patch_shared.cpp | 62 std::string devPath; member 111 infos.devPath = srcImage; in GetUpdateBlockInfo() 318 if (!Updater::Utils::CopyFile(infos.devPath, filename)) { in CreateFixedSizeEmptyFile() 319 LOG(ERROR) << "copy " << infos.devPath << " to " << filename << " failed"; in CreateFixedSizeEmptyFile() 322 size_t fileSize = Updater::Utils::GetFileSize(infos.devPath); in CreateFixedSizeEmptyFile() 447 (void)Utils::DeleteFile(infos.devPath); in RestoreOriginalFile()
|
/base/msdp/device_status/intention/services/device_manager/include/ |
H A D | device.h | 69 void SetDevPath(const std::string &devPath) override; 161 inline void Device::SetDevPath(const std::string &devPath) in SetDevPath() argument 163 devPath_ = devPath; in SetDevPath()
|
/base/startup/init/interfaces/innerkits/fs_manager/libfs_dm/ |
H A D | fs_dm.c | 272 int FsDmInitDmDev(char *devPath, bool useSocket) in FsDmInitDmDev() argument 278 if (devPath == NULL) { in FsDmInitDmDev() 279 BEGET_LOGE("error, devPath is NULL"); in FsDmInitDmDev() 283 devName = basename(devPath); in FsDmInitDmDev()
|
/base/msdp/device_status/intention/prototype/include/ |
H A D | i_device.h | 57 virtual void SetDevPath(const std::string &devPath) = 0;
|
/base/update/updater/services/include/fs_manager/ |
H A D | partitions.h | 71 std::string devPath; member
|
/base/update/updater/services/include/applypatch/ |
H A D | transfer_manager.h | 54 std::string devPath;
member
|
/base/startup/init/interfaces/innerkits/fs_manager/ |
H A D | fstab_mount.c | 195 int DoFormat(const char *devPath, const char *fsType) in DoFormat() argument 197 if (devPath == NULL || fsType == NULL) { in DoFormat() 213 "/bin/mke2fs", "-F", "-t", (char *)fsType, "-b", blockSizeBuffer, (char *)devPath, NULL in DoFormat() 222 "-O", "sb_checksum", (char *)devPath, NULL in DoFormat() 227 "-O", "sb_checksum", (char *)devPath, NULL in DoFormat()
|