Lines Matching defs:fd

288 seekCluster(int fd, int32_t clusterNum)
295 if (lseek64(fd, seekto, SEEK_SET) != seekto) {
316 getCluster(int fd, int32_t clusterNum, uchar_t **data, int32_t *datasize)
335 if (!seekCluster(fd, clusterNum))
337 if ((*datasize = read(fd, clusterBuffer, BytesPerCluster)) ==
357 writeCachedCluster(int fd, CachedCluster *clustInfo)
369 if (seekCluster(fd, clustInfo->clusterNum) == NULL)
372 if ((bytesWritten = write(fd, clustInfo->clusterData.bytes,
382 (void) close(fd);
528 markOrphan(int fd, int32_t clusterNum, struct pcdir *dp)
534 (void) markInUse(fd, clusterNum, dp, NULL, 0, VISIBLE, NULL);
649 summarizeFAT(int fd)
657 (void) markInUse(fd, c, &BlankPCDIR, NULL, 0, VISIBLE,
664 getReadyToSearch(int fd)
666 getFAT(fd);
668 getRootDirectory(fd);
675 summarize(int fd, int includeFAT)
698 getReadyToSearch(fd);
707 traverseFromRoot(fd, 0, PCFS_VISIT_SUBDIRS, PCFS_TRAVERSE_ALL,
712 traverseDir(fd, TheBIOSParameterBlock.bpb32.root_dir_clust,
718 summarizeFAT(fd);
749 orphanChain(int fd, int32_t c, struct pcdir *ndp)
757 markOrphan(fd, c, ndp);
762 (void) markInUse(fd, c, ndp, NULL, 0, VISIBLE, &tmpl);
796 emergencyEndOfDirectory(int fd, int32_t secondToLast)
801 if (readCluster(fd, secondToLast, &(dirdata.bytes), &dirdatasize,
811 (void) close(fd);
844 createNewEndOfDirectory(int fd, struct pcdir *entry, int32_t secondToLast)
851 if (readCluster(fd, freeCluster, &(dirdata.bytes),
879 (void) close(fd);
882 emergencyEndOfDirectory(fd, secondToLast);
895 truncAtCluster(int fd, struct pcdir *entry, int32_t cluster)
934 createNewEndOfDirectory(fd, entry, prev);
964 updateOrphanedChainMetadata(int fd, struct pcdir *dp, int32_t endCluster,
978 remainder = truncAtCluster(fd, dp, endCluster);
1036 splitChain(int fd, struct pcdir *dp, int32_t problemCluster,
1042 ndp = updateOrphanedChainMetadata(fd, dp, problemCluster, isBad);
1048 orphanChain(fd, *orphanStart, ndp);
1052 orphanChain(fd, problemCluster, ndp);
1089 redoInUse(int fd, int32_t c, struct pcdir *ndp, int32_t stopAtCluster)
1093 (void) markInUse(fd, c, ndp, NULL, 0, VISIBLE, NULL);
1133 linkOrphan(int fd, int32_t start)
1139 newEnt = addRootDirEnt(fd, dp);
1149 redoInUse(fd, start, newEnt, 0);
1162 relinkCreatedOrphans(int fd)
1169 linkOrphan(fd, c);
1190 relinkFATOrphans(int fd)
1216 orphanChain(fd, c, ndp);
1218 relinkCreatedOrphans(fd);
1222 relinkOrphans(int fd)
1224 relinkCreatedOrphans(fd);
1225 relinkFATOrphans(fd);
1255 sharedChainError(int fd, int32_t clusterNum, struct pcdir *badEntry)
1275 (void) truncAtCluster(fd, badEntry, clusterNum);
1280 truncChainWithBadCluster(int fd, struct pcdir *dp, int32_t startCluster)
1295 splitChain(fd, dp, c,
1369 writeClusterMods(int fd)
1375 writeCachedCluster(fd, loop);
1392 markInUse(int fd, int32_t clusterNum, struct pcdir *referencer, struct
1406 sharedChainError(fd, clusterNum, referencer);
1470 readCluster(int fd, int32_t clusterNum, uchar_t **data, int32_t *datasize,
1482 rv = getCluster(fd, clusterNum, &newBuf, datasize);
1506 findBadClusters(int fd)
1517 if (readCluster(fd, clusterCount,
1538 scanAndFixMetadata(int fd)
1544 getReadyToSearch(fd);
1545 createCHKNameList(fd);
1556 summarize(fd, NO_FAT_IN_SUMMARY);
1560 relinkCreatedOrphans(fd);
1569 summarize(fd, INCLUDE_FAT_IN_SUMMARY);
1570 relinkOrphans(fd);