Lines Matching refs:fd
48 kprintf("id: %" B_PRIdDEV ", fd: %d, device: %s, flags %" B_PRIu32 "\n",
49 vol->id, vol->fd, vol->device, vol->flags);
173 volume_init(int fd, uint8* buf,
189 vol->fd = fd;
337 if ((err = read_pos(vol->fd, vol->bytes_per_sector * (vol->reserved_sectors
357 if ((err = read_pos(vol->fd, vol->bytes_per_sector
401 vol->fBlockCache = block_cache_create(vol->fd, vol->total_sectors,
487 int fd;
493 if ((err = (fd = open(path, O_RDONLY | O_NOCACHE))) < 0) {
499 if (ioctl(fd, B_GET_GEOMETRY, &geo, sizeof(device_geometry)) < 0) {
501 if (fstat(fd, &st) >= 0 && S_ISREG(st.st_mode)) {
532 close(fd);
533 if ((err = (fd = open(path, O_RDWR | O_NOCACHE))) < 0) {
561 if ((err = read_pos(fd, 0, (void *)buf, 512)) != 512) {
566 vol = volume_init(fd, buf, vol_flags, fs_flags, &geo);
601 B_PRIu8 ")\n", vol->device, vol->id, vol->fd, vol->media_descriptor));
653 close(fd);
670 dosfs_identify_partition(int fd, partition_data *partition, void **_cookie)
682 if (read_pos(fd, 0, buf, 512) != 512)
730 vol = volume_init(fd, buf, 0, 0, NULL);
753 dosfs_scan_partition(int fd, partition_data *partition, void *_cookie)
953 result = close(vol->fd);
1115 dprintf("vol info: %s (device %x, media descriptor %x)\n", vol->device, vol->fd, vol->media_descriptor);