Lines Matching defs:volume

104 	Volume* volume = new(std::nothrow) Volume(_volume);
105 if (volume == NULL)
111 // but that requires us to export our volume data before calling it.
112 _volume->private_volume = volume;
115 status_t status = volume->Mount(device, flags);
117 ERROR("Failed mounting the volume. Error: %s\n", strerror(status));
118 delete volume;
122 *_rootID = volume->RootNode()->ID();
130 Volume* volume = (Volume *)_volume->private_volume;
132 status_t status = volume->Unmount();
133 delete volume;
142 Volume* volume = (Volume*)_volume->private_volume;
146 | (volume->IsReadOnly() ? B_FS_IS_READONLY : 0);
148 info->block_size = volume->BlockSize();
149 info->total_blocks = volume->NumBlocks();
150 info->free_blocks = volume->NumFreeBlocks();
153 strlcpy(info->volume_name, volume->Name(), sizeof(info->volume_name));
156 if (volume->HasExtentsFeature())
158 else if (volume->HasJournalFeature())
170 Volume* volume = (Volume*)_volume->private_volume;
172 if (volume->IsReadOnly())
175 MutexLocker locker(volume->Lock());
180 Transaction transaction(volume->GetJournal());
181 volume->SetName(info->volume_name);
182 status = volume->WriteSuperBlock(transaction);
192 Volume* volume = (Volume*)_volume->private_volume;
193 return volume->Sync();
204 Volume* volume = (Volume*)_volume->private_volume;
206 if (id < 2 || id > volume->NumInodes()) {
211 Inode* inode = new(std::nothrow) Inode(volume, id);
243 Volume* volume = (Volume*)_volume->private_volume;
251 Transaction transaction(volume->GetJournal());
261 status_t status = volume->RemoveOrphan(transaction, inode->ID());
273 status = volume->FreeInode(transaction, inode->ID(), inode->IsDirectory());
294 Volume* volume = (Volume*)_volume->private_volume;
319 status = read_file_io_vec_pages(volume->Device(), fileVecs,
338 Volume* volume = (Volume*)_volume->private_volume;
341 if (volume->IsReadOnly())
366 status = write_file_io_vec_pages(volume->Device(), fileVecs,
386 Volume* volume = (Volume*)_volume->private_volume;
397 if (block > volume->NumBlocks()) {
402 off_t blockOffset = block << volume->BlockShift();
403 uint32 blockLength = volume->BlockSize() * count;
452 Volume* volume = (Volume*)_volume->private_volume;
460 HTree htree(volume, directory);
472 entry_cache_add_missing(volume->ID(), directory->ID(), name);
475 entry_cache_add(volume->ID(), directory->ID(), name, *_vnodeID);
477 return get_vnode(volume->FSVolume(), *_vnodeID, NULL);
487 Volume* volume = (Volume*)_volume->private_volume;
494 Transaction transaction(volume->GetJournal());
496 CachedBlock cached(volume);
497 uint32 blocksPerGroup = volume->BlocksPerGroup();
498 uint32 blockSize = volume->BlockSize();
499 uint32 firstBlock = volume->FirstDataBlock();
509 while (volume->AllocateBlocks(transaction, 1, 2048, group, start,
524 transaction.Start(volume->GetJournal());
551 *offset += count * volume->BlockSize();
619 Volume* volume = (Volume*)_volume->private_volume;
621 if (volume->IsReadOnly())
634 Transaction transaction(volume->GetJournal());
717 notify_stat_changed(volume->ID(), -1, inode->ID(), mask);
727 Volume* volume = (Volume*)_volume->private_volume;
732 if (volume->IsReadOnly())
752 Transaction transaction(volume->GetJournal());
772 entry_cache_add(volume->ID(), directory->ID(), name, *_vnodeID);
776 entry_cache_remove(volume->ID(), directory->ID(), name);
784 notify_entry_created(volume->ID(), directory->ID(), name, *_vnodeID);
796 Volume* volume = (Volume*)_volume->private_volume;
799 if (volume->IsReadOnly())
810 Transaction transaction(volume->GetJournal());
843 publish_vnode(volume->FSVolume(), id, link, &gExt2VnodeOps,
845 put_vnode(volume->FSVolume(), id);
848 entry_cache_add(volume->ID(), directory->ID(), name, id);
852 notify_entry_created(volume->ID(), directory->ID(), name, id);
854 entry_cache_remove(volume->ID(), directory->ID(), name);
863 ext2_link(fs_volume* volume, fs_vnode* dir, const char* name, fs_vnode* node)
878 Volume* volume = (Volume*)_volume->private_volume;
886 Transaction transaction(volume->GetJournal());
891 HTree htree(volume, directory);
904 Vnode vnode(volume, id);
920 entry_cache_remove(volume->ID(), directory->ID(), name);
924 entry_cache_add(volume->ID(), directory->ID(), name, id);
926 notify_entry_removed(volume->ID(), directory->ID(), name, id);
938 Volume* volume = (Volume*)_volume->private_volume;
945 Transaction transaction(volume->GetJournal());
957 HTree oldHTree(volume, oldDirectory);
975 CachedBlock cached(volume);
981 Vnode vnode(volume, parentID);
1002 HTree newHTree(volume, newDirectory);
1013 Vnode vnode(volume, oldID);
1041 Vnode vnodeExistent(volume, existentID);
1061 entry_cache_remove(volume->ID(), newDirectory->ID(), newName);
1063 notify_entry_removed(volume->ID(), newDirectory->ID(), newName,
1122 entry_cache_remove(volume->ID(), oldDirectory->ID(), oldName);
1123 entry_cache_add(volume->ID(), newDirectory->ID(), newName, oldID);
1127 entry_cache_remove(volume->ID(), oldDirectory->ID(), newName);
1128 entry_cache_add(volume->ID(), newDirectory->ID(), oldName, oldID);
1133 notify_entry_moved(volume->ID(), oldDirectory->ID(), oldName,
1143 Volume* volume = (Volume*)_volume->private_volume;
1179 Transaction transaction(volume->GetJournal());
1221 Volume* volume = (Volume*)_volume->private_volume;
1224 if (volume->IsReadOnly())
1253 notify_stat_changed(volume->ID(), -1, inode->ID(),
1277 Volume* volume = (Volume*)_volume->private_volume;
1281 notify_stat_changed(volume->ID(), -1, inode->ID(), B_STAT_SIZE);
1333 Volume* volume = (Volume*)_volume->private_volume;
1336 if (volume->IsReadOnly())
1347 Transaction transaction(volume->GetJournal());
1355 put_vnode(volume->FSVolume(), id);
1357 entry_cache_add(volume->ID(), directory->ID(), name, id);
1361 entry_cache_remove(volume->ID(), directory->ID(), name);
1365 notify_entry_created(volume->ID(), directory->ID(), name, id);
1378 Volume* volume = (Volume*)_volume->private_volume;
1386 Transaction transaction(volume->GetJournal());
1391 HTree htree(volume, directory);
1403 Vnode vnode(volume, id);
1423 entry_cache_remove(volume->ID(), directory->ID(), name);
1424 entry_cache_remove(volume->ID(), id, "..");
1428 entry_cache_add(volume->ID(), directory->ID(), name, id);
1429 entry_cache_add(volume->ID(), id, "..", id);
1431 notify_entry_removed(volume->ID(), directory->ID(), name, id);
1462 Volume* volume = (Volume*)_volume->private_volume;
1490 dirent->d_dev = volume->ID();
1529 Volume* volume = (Volume*)_volume->private_volume;
1532 if (!(volume->SuperBlock().CompatibleFeatures() & EXT2_FEATURE_EXT_ATTR))
1586 Volume* volume = (Volume*)_volume->private_volume;
1588 dirent->d_dev = volume->ID();
1614 Volume* volume = (Volume*)_volume->private_volume;
1618 if (!(volume->SuperBlock().CompatibleFeatures() & EXT2_FEATURE_EXT_ATTR))