Home
last modified time | relevance | path

Searched refs:drive (Results 1 – 25 of 122) sorted by relevance

12345

/external/vboot_reference/cgpt/
Dcgpt_common.c54 int CheckValid(const struct drive *drive) { in CheckValid() argument
55 if ((drive->gpt.valid_headers != MASK_BOTH) || in CheckValid()
56 (drive->gpt.valid_entries != MASK_BOTH)) { in CheckValid()
63 int Load(struct drive *drive, uint8_t **buf, in Load() argument
86 if (-1 == lseek(drive->fd, sector * sector_bytes, SEEK_SET)) { in Load()
91 nread = read(drive->fd, *buf, count); in Load()
106 int ReadPMBR(struct drive *drive) { in ReadPMBR() argument
107 if (-1 == lseek(drive->fd, 0, SEEK_SET)) in ReadPMBR()
110 int nread = read(drive->fd, &drive->pmbr, sizeof(struct pmbr)); in ReadPMBR()
117 int WritePMBR(struct drive *drive) { in WritePMBR() argument
[all …]
Dcgpt_boot.c16 struct drive drive; in CgptGetBootPartitionNumber() local
23 if (CGPT_OK != DriveOpen(params->drive_name, &drive, O_RDONLY, in CgptGetBootPartitionNumber()
27 if (GPT_SUCCESS != (gpt_retval = GptSanityCheck(&drive.gpt))) { in CgptGetBootPartitionNumber()
34 if (CGPT_OK != ReadPMBR(&drive)) { in CgptGetBootPartitionNumber()
41 GuidToStr(&drive.pmbr.boot_guid, buf, sizeof(buf)); in CgptGetBootPartitionNumber()
43 int numEntries = GetNumberOfEntries(&drive); in CgptGetBootPartitionNumber()
46 GptEntry *entry = GetEntry(&drive.gpt, ANY_VALID, i); in CgptGetBootPartitionNumber()
48 if (GuidEqual(&entry->unique, &drive.pmbr.boot_guid)) { in CgptGetBootPartitionNumber()
60 (void) DriveClose(&drive, 1); in CgptGetBootPartitionNumber()
66 struct drive drive; in CgptBoot() local
[all …]
Dcgpt_add.c68 static int GptSetEntryAttributes(struct drive *drive, in GptSetEntryAttributes() argument
73 entry = GetEntry(&drive->gpt, PRIMARY, index); in GptSetEntryAttributes()
100 static int SetEntryAttributes(struct drive *drive, in SetEntryAttributes() argument
104 SetRaw(drive, PRIMARY, index, params->raw_value); in SetEntryAttributes()
107 SetSuccessful(drive, PRIMARY, index, params->successful); in SetEntryAttributes()
109 SetTries(drive, PRIMARY, index, params->tries); in SetEntryAttributes()
111 SetPriority(drive, PRIMARY, index, params->priority); in SetEntryAttributes()
115 if (IsUnused(drive, PRIMARY, index)) { in SetEntryAttributes()
129 static int CgptCheckAddValidity(struct drive *drive) { in CgptCheckAddValidity() argument
131 if (GPT_SUCCESS != (gpt_retval = GptSanityCheck(&drive->gpt))) { in CgptCheckAddValidity()
[all …]
Dcgpt.h45 struct drive { struct
61 int DriveOpen(const char *drive_path, struct drive *drive, int mode,
63 int DriveClose(struct drive *drive, int update_as_needed);
64 int CheckValid(const struct drive *drive);
78 int Load(struct drive *drive, uint8_t **buf,
93 int Save(struct drive *drive, const uint8_t *buf,
121 int ReadPMBR(struct drive *drive);
122 int WritePMBR(struct drive *drive);
149 uint32_t GetNumberOfEntries(const struct drive *drive);
152 void SetPriority(struct drive *drive, int secondary, uint32_t entry_index,
[all …]
Dcgpt_create.c24 static int GptCreate(struct drive *drive, CgptCreateParams *params) { in GptCreate() argument
28 AllocAndClear(&drive->gpt.primary_header, in GptCreate()
29 drive->gpt.sector_bytes * GPT_HEADER_SECTORS); in GptCreate()
30 AllocAndClear(&drive->gpt.secondary_header, in GptCreate()
31 drive->gpt.sector_bytes * GPT_HEADER_SECTORS); in GptCreate()
33 drive->gpt.modified |= (GPT_MODIFIED_HEADER1 | GPT_MODIFIED_ENTRIES1 | in GptCreate()
38 GptHeader *h = (GptHeader *)drive->gpt.primary_header; in GptCreate()
43 h->alternate_lba = drive->gpt.gpt_drive_sectors - GPT_HEADER_SECTORS; in GptCreate()
52 if (drive->gpt.flags & GPT_FLAG_EXTERNAL) { in GptCreate()
63 (GPT_PMBR_SECTORS + GPT_HEADER_SECTORS) * drive->gpt.sector_bytes; in GptCreate()
[all …]
Dcgpt_show.c144 void EntriesDetails(struct drive *drive, const int secondary, int raw) { in EntriesDetails() argument
147 for (i = 0; i < GetNumberOfEntries(drive); ++i) { in EntriesDetails()
149 entry = GetEntry(&drive->gpt, secondary, i); in EntriesDetails()
158 static int GptShow(struct drive *drive, CgptShowParams *params) { in GptShow() argument
160 if (GPT_SUCCESS != (gpt_retval = GptSanityCheck(&drive->gpt))) { in GptShow()
168 if (params->partition > GetNumberOfEntries(drive)) { in GptShow()
174 GptEntry *entry = GetEntry(&drive->gpt, ANY_VALID, index); in GptShow()
204 printf("%d\n", GetSuccessful(drive, ANY_VALID, index)); in GptShow()
207 printf("%d\n", GetTries(drive, ANY_VALID, index)); in GptShow()
210 printf("%d\n", GetPriority(drive, ANY_VALID, index)); in GptShow()
[all …]
Dcgpt_legacy.c12 struct drive drive; in CgptLegacy() local
18 if (CGPT_OK != DriveOpen(params->drive_name, &drive, O_RDWR, in CgptLegacy()
22 h1 = (GptHeader *)drive.gpt.primary_header; in CgptLegacy()
23 h2 = (GptHeader *)drive.gpt.secondary_header; in CgptLegacy()
27 RepairEntries(&drive.gpt, MASK_SECONDARY); in CgptLegacy()
28 drive.gpt.modified |= (GPT_MODIFIED_HEADER1 | GPT_MODIFIED_ENTRIES1 | in CgptLegacy()
33 memset(drive.gpt.primary_entries, 0, drive.gpt.sector_bytes); in CgptLegacy()
34 drive.gpt.modified |= (GPT_MODIFIED_HEADER1 | GPT_MODIFIED_ENTRIES1 | in CgptLegacy()
38 UpdateCrc(&drive.gpt); in CgptLegacy()
41 return DriveClose(&drive, 1); in CgptLegacy()
Dcgpt_repair.c13 struct drive drive; in CgptRepair() local
18 if (CGPT_OK != DriveOpen(params->drive_name, &drive, O_RDWR, in CgptRepair()
22 int gpt_retval = GptSanityCheck(&drive.gpt); in CgptRepair()
27 GptRepair(&drive.gpt); in CgptRepair()
28 if (drive.gpt.modified & GPT_MODIFIED_HEADER1) in CgptRepair()
30 if (drive.gpt.modified & GPT_MODIFIED_ENTRIES1) in CgptRepair()
32 if (drive.gpt.modified & GPT_MODIFIED_ENTRIES2) in CgptRepair()
34 if (drive.gpt.modified & GPT_MODIFIED_HEADER2) in CgptRepair()
37 return DriveClose(&drive, 1); in CgptRepair()
Dcgpt_find.c42 static int match_content(CgptFindParams *params, struct drive *drive, in match_content() argument
57 drive->fd, in match_content()
110 static int gpt_search(CgptFindParams *params, struct drive *drive, in gpt_search() argument
117 if (GPT_SUCCESS != GptSanityCheck(&drive->gpt)) { in gpt_search()
121 for (i = 0; i < GetNumberOfEntries(drive); ++i) { in gpt_search()
122 entry = GetEntry(&drive->gpt, ANY_VALID, i); in gpt_search()
141 if (found && match_content(params, drive, entry)) { in gpt_search()
155 struct drive drive; in do_search() local
157 if (CGPT_OK != DriveOpen(fileName, &drive, O_RDONLY, params->drive_size)) in do_search()
160 retval = gpt_search(params, &drive, fileName); in do_search()
[all …]
Dcgpt_prioritize.c95 struct drive drive; in CgptPrioritize() local
109 if (CGPT_OK != DriveOpen(params->drive_name, &drive, O_RDWR, in CgptPrioritize()
113 if (GPT_SUCCESS != (gpt_retval = GptSanityCheck(&drive.gpt))) { in CgptPrioritize()
119 max_part = GetNumberOfEntries(&drive); in CgptPrioritize()
129 if (!IsKernel(&drive, PRIMARY, index)) { in CgptPrioritize()
138 if (IsKernel(&drive, PRIMARY, i)) in CgptPrioritize()
146 if (!IsKernel(&drive, PRIMARY, i)) in CgptPrioritize()
149 priority = GetPriority(&drive, PRIMARY, i); in CgptPrioritize()
194 SetPriority(&drive, PRIMARY, in CgptPrioritize()
201 UpdateAllEntries(&drive); in CgptPrioritize()
[all …]
/external/chromium-trace/catapult/third_party/py_vulcanize/third_party/rcssmin/_setup/py2/
Ddata.py37 drive, path = '', _os.path.normpath(path)
43 drive, path = splitunc(path)
44 if not drive:
45 drive, path = _os.path.splitdrive(path)
55 drive = _os.path.join(drive, prefix)
59 return drive, elems
/external/chromium-trace/catapult/third_party/py_vulcanize/third_party/rcssmin/_setup/py3/
Ddata.py37 drive, path = '', _os.path.normpath(path)
43 drive, path = splitunc(path)
44 if not drive:
45 drive, path = _os.path.splitdrive(path)
55 drive = _os.path.join(drive, prefix)
59 return drive, elems
/external/chromium-trace/catapult/third_party/py_vulcanize/third_party/rjsmin/_setup/py3/
Ddata.py37 drive, path = '', _os.path.normpath(path)
43 drive, path = splitunc(path)
44 if not drive:
45 drive, path = _os.path.splitdrive(path)
55 drive = _os.path.join(drive, prefix)
59 return drive, elems
/external/chromium-trace/catapult/third_party/py_vulcanize/third_party/rjsmin/_setup/py2/
Ddata.py37 drive, path = '', _os.path.normpath(path)
43 drive, path = splitunc(path)
44 if not drive:
45 drive, path = _os.path.splitdrive(path)
55 drive = _os.path.join(drive, prefix)
59 return drive, elems
/external/webrtc/webrtc/base/
Dpathutils.cc228 bool Pathname::GetDrive(char* drive, uint32_t bytes) const { in GetDrive() argument
229 return GetDrive(drive, bytes, folder_); in GetDrive()
233 bool Pathname::GetDrive(char* drive, in GetDrive() argument
241 memcpy(drive, pathname.c_str(), 3); in GetDrive()
242 drive[3] = 0; in GetDrive()
244 return (isalpha(drive[0]) && in GetDrive()
245 drive[1] == ':' && in GetDrive()
246 drive[2] == '\\'); in GetDrive()
Dwin32filesystem.cc387 char drive[4]; in GetDiskFreeSpace() local
390 if (path.GetDrive(drive, sizeof(drive))) { in GetDiskFreeSpace()
391 drive16 = ToUtf16(drive); in GetDiskFreeSpace()
405 LOG(LS_VERBOSE) << "Remote or unknown drive: " << drive; in GetDiskFreeSpace()
Dpathutils.h95 bool GetDrive(char* drive, uint32_t bytes) const;
96 static bool GetDrive(char* drive,
/external/autotest/client/site_tests/hardware_StorageFio/
Dcontrol.vendor14 - Trim the drive
21 - Trim the drive
28 - Trim the drive
32 - Trim the drive
Dvendor_perf_fill_device6 ; - Trim the drive
13 ; - Trim the drive
20 ; - Trim the drive
24 ; - Trim the drive
/external/autotest/client/site_tests/hardware_UsbMount/
Dcontrol9 PURPOSE = "Verify a USB drive can mount/umount"
25 This test requires a USB drive inserted before the test begins.
26 This test will prepare the USB drive formatting its partition before starting
/external/autotest/client/site_tests/hardware_UsbBasicFileOperations/
Dcontrol7 PURPOSE = "Test USB drive file-based operations"
18 This test requires a USB drive inserted before the test begins.
19 It also needs a single partition on the drive, the file system type is not
/external/valgrind/docs/internals/
Dqemu-aarch64-linux-HOWTO.txt33 -drive file=disk6G.img,if=none,id=blk -device virtio-blk-device,drive=blk \
88 -cpu cortex-a57 -m 1024 -drive file=disk6G.img,if=none,id=blk \
89 -device virtio-blk-device,drive=blk -net user,hostfwd=tcp::5555-:22 \
/external/skia/site/dev/testing/
Dskialab.md181 9. Unplug the flash drive and plug in the external hard drive labeled, "Disk
184 10. Select the external drive to use for /home/partimag, something like,
191 16. Choose the hard drive in the machine. It should be the only option.
213 10. Unplug the flash drive and plug in the external hard drive labeled, "Disk
216 11. Select the external drive to use for /home/partimag, something like,
223 12. Choose the hard drive in the machine. It should be the only option.
/external/sonivox/arm-wt-22k/lib_src/
Deas_math.h304 #define MULT_AUDIO_DRIVE(audio,drive) /*lint -e(702) <avoid divide for performance>*/ \ argument
307 ((int32_t)(audio)) * ((int32_t)(drive)) \
/external/gtest/test/
Dgtest-filepath_test.cc386 for (char drive = 'Z'; drive >= 'A'; drive--) in TEST() local
387 if (_chdrive(drive - 'A' + 1) == -1) { in TEST()
389 non_drive[0] = drive; in TEST()

12345