• Home
  • Raw
  • Download

Lines Matching refs:tempMBR

141    TempMBR tempMBR;  in ReadMBRData()  local
154 if (myDisk->Read(&tempMBR, 512)) in ReadMBRData()
160 code[i] = tempMBR.code[i]; in ReadMBRData()
161 diskSignature = tempMBR.diskSignature; in ReadMBRData()
162 nulls = tempMBR.nulls; in ReadMBRData()
164 partitions[i] = tempMBR.partitions[i]; in ReadMBRData()
168 MBRSignature = tempMBR.MBRSignature; in ReadMBRData()
345 TempMBR tempMBR; in WriteMBRData() local
350 memcpy(tempMBR.code, code, 440); in WriteMBRData()
351 tempMBR.diskSignature = diskSignature; in WriteMBRData()
352 tempMBR.nulls = nulls; in WriteMBRData()
353 tempMBR.MBRSignature = MBRSignature; in WriteMBRData()
355 partitions[i].StoreInStruct(&tempMBR.partitions[i]); in WriteMBRData()
362 allOK = allOK && WriteMBRData(tempMBR, theDisk, 0); in WriteMBRData()
365 tempMBR.diskSignature = 0; in WriteMBRData()
367 tempMBR.partitions[i].firstLBA = tempMBR.partitions[i].lengthLBA = 0; in WriteMBRData()
368 tempMBR.partitions[i].partitionType = 0x00; in WriteMBRData()
370 tempMBR.partitions[i].firstSector[j] = 0; in WriteMBRData()
371 tempMBR.partitions[i].lastSector[j] = 0; in WriteMBRData()
379 partitions[partNum].StoreInStruct(&tempMBR.partitions[0]); in WriteMBRData()
380 tempMBR.partitions[0].firstLBA = 1; in WriteMBRData()
384 tempMBR.partitions[1].partitionType = 0x0f; in WriteMBRData()
385tempMBR.partitions[1].firstLBA = (uint32_t) (partitions[next].GetStartLBA() - extFirstLBA - 1); in WriteMBRData()
386 tempMBR.partitions[1].lengthLBA = (uint32_t) (partitions[next].GetLengthLBA() + 1); in WriteMBRData()
387 LBAtoCHS((uint64_t) tempMBR.partitions[1].firstLBA, in WriteMBRData()
388 (uint8_t *) &tempMBR.partitions[1].firstSector); in WriteMBRData()
389 LBAtoCHS(tempMBR.partitions[1].lengthLBA - extFirstLBA, in WriteMBRData()
390 (uint8_t *) &tempMBR.partitions[1].lastSector); in WriteMBRData()
392 tempMBR.partitions[1].partitionType = 0x00; in WriteMBRData()
393 tempMBR.partitions[1].firstLBA = 0; in WriteMBRData()
394 tempMBR.partitions[1].lengthLBA = 0; in WriteMBRData()
397 allOK = WriteMBRData(tempMBR, theDisk, writeEbrTo); in WriteMBRData()
398 writeEbrTo = (uint64_t) tempMBR.partitions[1].firstLBA + (uint64_t) extFirstLBA; in WriteMBRData()