Changeset f4a47e52 in mainline
- Timestamp:
- 2013-12-02T15:10:20Z (11 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 0773396
- Parents:
- 8c95dff
- Location:
- uspace
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/hdisk/func_mbr.c
r8c95dff rf4a47e52 198 198 } 199 199 200 printf("ST_LOGIC: %d, %hd\n", mbr_get_flag(p, ST_LOGIC), p->status);201 202 200 printf("Set type (0-255): "); 203 201 type = get_input_uint8(in); -
uspace/lib/gpt/libgpt.c
r8c95dff rf4a47e52 310 310 goto fini_fail; 311 311 312 //size_t bufpos = 0;313 //size_t buflen = 0;314 312 aoff64_t pos = ent_lba * block_size; 315 313 … … 387 385 } 388 386 389 printf("test1.0\n");390 387 uint32_t e_size = uint32_t_le2host(label->gpt->header->entry_size); 391 printf("test1.025\n");392 388 size_t fillries = label->parts->fill > GPT_MIN_PART_NUM ? label->parts->fill : GPT_MIN_PART_NUM; 393 printf("test1.05\n");389 394 390 if (e_size != sizeof(gpt_entry_t)) 395 391 return ENOTSUP; … … 400 396 label->gpt->header->first_usable_lba = host2uint64_t_le(gpt_space); 401 397 label->gpt->header->last_usable_lba = host2uint64_t_le(n_blocks - gpt_space - 1); 402 printf("test1.5\n");398 403 399 /* Perform checks */ 404 400 gpt_part_foreach (label, p) { … … 408 404 if (!check_encaps(p, n_blocks, gpt_space)) { 409 405 rc = ERANGE; 410 printf("encaps with: %" PRIuOFF64 ", %" PRIu64 ", %" PRIu64 "\n",411 n_blocks, gpt_space, gpt_get_end_lba(p));412 406 goto fail; 413 407 } … … 419 413 if (gpt_get_part_type(p) != GPT_PTE_UNUSED) { 420 414 if (check_overlap(p, q)) { 421 printf("overlap with: %" PRIu64 ", %" PRIu64 "\n",422 gpt_get_start_lba(p), gpt_get_start_lba(q));423 415 rc = ERANGE; 424 416 goto fail; … … 427 419 } 428 420 } 429 printf("test1.6\n");421 430 422 label->gpt->header->pe_array_crc32 = host2uint32_t_le(compute_crc32( 431 423 (uint8_t *) label->parts->part_array, 432 424 fillries * e_size)); 433 425 434 printf("test1.7\n");426 435 427 /* Write to backup GPT partition array location */ 436 428 rc = block_write_direct(dev_handle, n_blocks - arr_blocks - 1, … … 438 430 if (rc != EOK) 439 431 goto fail; 440 printf("test1.8\n");432 441 433 /* Write to main GPT partition array location */ 442 434 rc = block_write_direct(dev_handle, uint64_t_le2host(label->gpt->header->entry_lba), … … 444 436 if (rc != EOK) 445 437 goto fail; 446 printf("test1.9\n");438 447 439 return gpt_write_header(label, dev_handle); 448 440 … … 626 618 627 619 for (i = 0; gpt_ptypes[i].guid != NULL; i++) { 628 //printf("%x =?= %x\n", p->part_type[3], get_byte(gpt_ptypes[i].guid +0));629 //printf("%x =?= %x\n", p->part_type[2], get_byte(gpt_ptypes[i].guid +2));630 //printf("%x =?= %x\n", p->part_type[1], get_byte(gpt_ptypes[i].guid +4));631 //printf("%x =?= %x\n", p->part_type[0], get_byte(gpt_ptypes[i].guid +6));632 //getchar();633 620 if (p->part_type[3] == get_byte(gpt_ptypes[i].guid +0) && 634 621 p->part_type[2] == get_byte(gpt_ptypes[i].guid +2) &&
Note:
See TracChangeset
for help on using the changeset viewer.