/bootable/recovery/tests/unit/ |
D | screen_ui_test.cpp | 81 for (size_t i = 0; i < menu.ItemsCount(); i++) { in TEST_F() local 82 ASSERT_EQ(ITEMS[i], menu.TextItem(i)); in TEST_F() 96 for (size_t i = 0; i < menu.ItemsCount() - 1; i++) { in TEST_F() local 97 ASSERT_EQ(ITEMS[i], menu.TextItem(i)); in TEST_F() 111 for (size_t i = 0; i < menu.ItemsCount(); i++) { in TEST_F() local 112 ASSERT_EQ(ITEMS[i], menu.TextItem(i)); in TEST_F() 128 for (size_t i = 0; i < menu.ItemsCount(); i++) { in TEST_F() local 129 ASSERT_EQ(ITEMS[i], menu.TextItem(i)); in TEST_F() 140 for (int i = 0; i < 10; i++) { in TEST_F() local 145 int expected = (i + 1) % 5; in TEST_F() [all …]
|
D | resources_test.cpp | 33 for (auto i = 0; i < frame_count; i++) { in TEST() local 34 free(frames[i]); in TEST()
|
D | minui_test.cpp | 47 for (auto i = 0; i < image->data_size(); i++) { in TEST() local 48 image->data()[i] = rand() % 128; in TEST()
|
/bootable/recovery/otautil/ |
D | mounts.cpp | 42 for (size_t i = 0; i < g_mounts_state.size(); ++i) { in scan_mounted_volumes() local 43 delete g_mounts_state[i]; in scan_mounted_volumes() 66 for (size_t i = 0; i < g_mounts_state.size(); ++i) { in find_mounted_volume_by_mount_point() local 67 if (g_mounts_state[i]->mount_point == mount_point) return g_mounts_state[i]; in find_mounted_volume_by_mount_point()
|
D | logging.cpp | 121 size_t i; in logrotate() local 122 if (!android::base::ParseUint(number, &i)) { in logrotate() 126 name = sub + "." + std::to_string(i + 1); in logrotate() 144 for (int i = KEEP_LOG_COUNT - 1; i >= 0; --i) { in rotate_logs() local 146 if (i > 0) { in rotate_logs() 147 old_log += "." + std::to_string(i); in rotate_logs() 149 std::string new_log = android::base::StringPrintf("%s.%d", last_log_file, i + 1); in rotate_logs() 154 if (i > 0) { in rotate_logs() 155 old_kmsg += "." + std::to_string(i); in rotate_logs() 157 std::string new_kmsg = android::base::StringPrintf("%s.%d", last_kmsg_file, i + 1); in rotate_logs()
|
D | sysutil.cpp | 81 for (size_t i = 0; i < range_count; ++i) { in ParseBlockMapFile() local 82 const std::string& line = lines[i + 3]; in ParseBlockMapFile() 85 LOG(ERROR) << "failed to parse range " << i << ": " << line; in ParseBlockMapFile()
|
/bootable/recovery/minui/ |
D | resources.cpp | 235 for (int i = 0; i < num_text; ++i) { in res_create_multi_display_surface() local 236 if (text[i].key && strcmp(text[i].key, "Frames") == 0 && text[i].text) { in res_create_multi_display_surface() 237 *frames = atoi(text[i].text); in res_create_multi_display_surface() 238 } else if (text[i].key && strcmp(text[i].key, "FPS") == 0 && text[i].text) { in res_create_multi_display_surface() 239 *fps = atoi(text[i].text); in res_create_multi_display_surface() 265 for (int i = 0; i < *frames; ++i) { in res_create_multi_display_surface() local 271 surface[i] = created_surface.release(); in res_create_multi_display_surface() 291 for (int i = 0; i < *frames; ++i) { in res_create_multi_display_surface() local 292 free(surface[i]); in res_create_multi_display_surface() 382 for (int i = 0; i < h; ++i, ++y) { in get_locales_in_png() local [all …]
|
D | graphics_drm.cpp | 187 for (int i = 0; i < connector->count_encoders; i++) { in find_crtc_for_connector() local 188 encoder = drmModeGetEncoder(fd, connector->encoders[i]); in find_crtc_for_connector() 207 for (int i = 0; i < resources->count_connectors; i++) { in find_used_connector_by_type() local 208 drmModeConnector* connector = drmModeGetConnector(fd, resources->connectors[i]); in find_used_connector_by_type() 221 for (int i = 0; i < resources->count_connectors; i++) { in find_first_connected_connector() local 224 connector = drmModeGetConnector(fd, resources->connectors[i]); in find_first_connected_connector() 245 unsigned i = 0; in FindMainMonitor() local 247 main_monitor_connector = find_used_connector_by_type(fd, resources, kConnectorPriority[i]); in FindMainMonitor() 248 i++; in FindMainMonitor() 249 } while (!main_monitor_connector && i < arraysize(kConnectorPriority)); in FindMainMonitor() [all …]
|
D | events.cpp | 187 for (size_t i = 0; i < g_ev_dev_count; ++i) { in ev_sync_key_state() local 191 if (ioctl(ev_fdinfo[i].fd, EVIOCGBIT(0, sizeof(ev_bits)), ev_bits) == -1) { in ev_sync_key_state() 197 if (ioctl(ev_fdinfo[i].fd, EVIOCGKEY(sizeof(key_bits)), key_bits) == -1) { in ev_sync_key_state() 216 for (size_t i = 0; i < g_ev_dev_count; ++i) { in ev_iterate_available_keys() local 221 if (ioctl(ev_fdinfo[i].fd, EVIOCGBIT(0, sizeof(ev_bits)), ev_bits) == -1) { in ev_iterate_available_keys() 228 if (ioctl(ev_fdinfo[i].fd, EVIOCGBIT(EV_KEY, KEY_MAX), key_bits) == -1) { in ev_iterate_available_keys() 241 for (size_t i = 0; i < g_ev_dev_count; ++i) { in ev_iterate_touch_inputs() local 244 if (ioctl(ev_fdinfo[i].fd, EVIOCGBIT(0, sizeof(ev_bits)), ev_bits) == -1) { in ev_iterate_touch_inputs() 252 if (ioctl(ev_fdinfo[i].fd, EVIOCGBIT(EV_ABS, KEY_MAX), key_bits) == -1) { in ev_iterate_touch_inputs()
|
D | graphics_adf.cpp | 139 for (ssize_t i = 0; i < n_dev_ids && intf_fd < 0; i++) { in Init() local 140 int err = adf_device_open(dev_ids[i], O_RDWR, &dev); in Init() 142 fprintf(stderr, "opening adf device %u failed: %s\n", dev_ids[i], strerror(-err)); in Init() 148 fprintf(stderr, "initializing adf device %u failed: %s\n", dev_ids[i], strerror(-err)); in Init()
|
/bootable/recovery/otautil/include/otautil/ |
D | print_sha1.h | 28 for (size_t i = 0; i < len; ++i) { in print_sha1() local 29 result.push_back(hex[(sha1[i] >> 4) & 0xf]); in print_sha1() 30 result.push_back(hex[sha1[i] & 0xf]); in print_sha1()
|
/bootable/recovery/applypatch/ |
D | imgdiff.cpp | 563 for (size_t i = 0; i < patch_chunks.size(); ++i) { in WritePatchDataToFd() local 564 offset = patch_chunks[i].WriteHeaderToFd(patch_fd, offset, i); in WritePatchDataToFd() 581 ImageChunk& Image::operator[](size_t i) { in operator []() argument 582 CHECK_LT(i, chunks_.size()); in operator []() 583 return chunks_[i]; in operator []() 586 const ImageChunk& Image::operator[](size_t i) const { in operator []() 587 CHECK_LT(i, chunks_.size()); in operator []() 588 return chunks_[i]; in operator []() 616 for (size_t i = 0; i < chunks_.size(); ++i) { in DumpChunks() local 617 chunks_[i].Dump(i); in DumpChunks() [all …]
|
D | imgpatch.cpp | 159 for (int i = 0; i < num_chunks; ++i) { in ApplyImagePatch() local 162 printf("failed to read chunk %d record\n", i); in ApplyImagePatch() 172 printf("failed to read chunk %d normal header data\n", i); in ApplyImagePatch() 194 printf("failed to read chunk %d raw header data\n", i); in ApplyImagePatch() 201 printf("failed to read chunk %d raw data\n", i); in ApplyImagePatch() 205 printf("failed to write chunk %d raw data\n", i); in ApplyImagePatch() 216 printf("failed to read chunk %d deflate header data\n", i); in ApplyImagePatch() 236 size_t bonus_size = (i == 1 && bonus_data != nullptr) ? bonus_data->data.size() : 0; in ApplyImagePatch() 287 printf("patch chunk %d is unknown type %d\n", i, type); in ApplyImagePatch()
|
/bootable/recovery/edify/ |
D | expr.cpp | 83 for (size_t i = 0; i < argv.size(); ++i) { in ConcatFn() local 85 if (!Evaluate(state, argv[i], &str)) { in ConcatFn() 125 for (size_t i = 0; i < argv.size(); ++i) { in AssertFn() local 127 if (!Evaluate(state, argv[i], &result)) { in AssertFn() 131 int len = argv[i]->end - argv[i]->start; in AssertFn() 132 state->errmsg = "assert failed: " + state->script.substr(argv[i]->start, len); in AssertFn() 155 for (size_t i = 0; i < argv.size(); ++i) { in StdoutFn() local 157 if (!Evaluate(state, argv[i], &v)) { in StdoutFn() 365 for (size_t i = start; i < start + len; ++i) { in ReadArgs() local 367 if (!Evaluate(state, argv[i], &var)) { in ReadArgs() [all …]
|
/bootable/recovery/boot_control/ |
D | boot_control.cpp | 69 for (uint32_t i = 0; i < 256; ++i) { in CRC32() local 70 uint32_t crc = i; in CRC32() 75 crc_table[i] = crc; in CRC32() 80 for (size_t i = 0; i < size; ++i) { in CRC32() local 81 ret = (ret >> 8) ^ crc_table[(ret ^ buf[i]) & 0xFF]; in CRC32() 285 for (unsigned int i = 0; i < bootctrl_module->num_slots; ++i) { in BootControl_setActiveBootSlot() local 286 if (i != slot) { in BootControl_setActiveBootSlot() 287 if (bootctrl.slot_info[i].priority >= kActivePriority) in BootControl_setActiveBootSlot() 288 bootctrl.slot_info[i].priority = kActivePriority - 1; in BootControl_setActiveBootSlot()
|
/bootable/recovery/misc_writer/ |
D | misc_writer.cpp | 41 for (size_t i = 0; i < length / 2; i++) { in ParseHexString() local 42 auto sub = "0x" + std::string(hex_string.substr(i * 2, 2)); in ParseHexString() 43 if (!android::base::ParseUint(sub, &result[i])) { in ParseHexString()
|
/bootable/recovery/ |
D | interlace-frames.py | 49 for i in range(w): 51 out.putpixel((i, j*N+fn), f.getpixel((i, j))) 86 for i in range(width): 88 out.putpixel((i, j), img.getpixel((i, j * num_frames + k)))
|
/bootable/recovery/install/ |
D | verifier.cpp | 187 for (size_t i = 4; i < eocd_size - 3; ++i) { in verify_file() local 188 if (eocd[i] == 0x50 && eocd[i + 1] == 0x4b && eocd[i + 2] == 0x05 && eocd[i + 3] == 0x06) { in verify_file() 260 size_t i = 0; in verify_file() local 282 LOG(INFO) << "failed to verify against RSA key " << i; in verify_file() 286 LOG(INFO) << "whole-file signature verified against RSA key " << i; in verify_file() 290 LOG(INFO) << "failed to verify against EC key " << i; in verify_file() 294 LOG(INFO) << "whole-file signature verified against EC key " << i; in verify_file() 299 i++; in verify_file()
|
D | asn1_decoder.cpp | 60 for (int i = 0; i < num_octets; ++i) { in decode_length() local
|
D | fuse_sdcard_install.cpp | 167 for (int i = 0; i < SDCARD_INSTALL_TIMEOUT; ++i) { in ApplyFromSdcard() local 176 if (errno == ENOENT && i < SDCARD_INSTALL_TIMEOUT - 1) { in ApplyFromSdcard()
|
/bootable/recovery/tests/component/ |
D | sideload_test.cpp | 82 for (int i = 0; i < kSideloadInstallTimeout; ++i) { in TEST() local 90 if (errno == ENOENT && i < kSideloadInstallTimeout - 1) { in TEST()
|
D | resources_test.cpp | 110 for (int i = 0; i < h; ++i, ++y) { in TEST_P() local
|
/bootable/recovery/recovery_ui/ |
D | screen_ui.cpp | 78 for (size_t i = 0; i < items_count; ++i) { in TextMenu() local 79 text_items_.emplace_back(items[i].substr(0, max_item_length_)); in TextMenu() 178 for (size_t i = MenuStart(); i < MenuEnd(); ++i) { in DrawItems() local 180 if (i == selection()) { in DrawItems() 191 offset += draw_funcs_.DrawTextLine(x, y + offset, TextItem(i), bold); in DrawItems() 239 for (size_t i = 0; i < graphic_items_.size(); i++) { in DrawItems() local 240 auto& item = graphic_items_[i]; in DrawItems() 241 if (i == selection_) { in DrawItems() 427 for (int i = 0; i < max_stage; ++i) { in draw_background_locked() local 428 const auto& stage_surface = (i < stage) ? stage_marker_fill_ : stage_marker_empty_; in draw_background_locked() [all …]
|
/bootable/recovery/updater_sample/src/com/example/android/systemupdatersample/ |
D | UpdateConfig.java | 79 for (int i = 0; i < propertyFilesJson.length(); i++) { in fromJson() 80 JSONObject p = propertyFilesJson.getJSONObject(i); in fromJson()
|
/bootable/recovery/updater/ |
D | commands.cpp | 364 for (size_t i = 0; i < ranges_.blocks(); i++) { in DumpBuffer() local 365 size_t block_num = ranges_.GetBlockNumber(i); in DumpBuffer() 366 size_t buffer_index = location.GetBlockNumber(i); in DumpBuffer() 438 for (size_t i = kTransferListHeaderLines; i < lines.size(); i++) { in Parse() local 439 const std::string& line = lines[i]; in Parse() 442 size_t cmdindex = i - kTransferListHeaderLines; in Parse()
|