Moved allocation location of reserve vds from immediately following

primary vds to immediately preceding the anchor at block 256, since
this puts more distance between the two vdses.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@5578 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Tyler Dauwalder
2003-12-05 06:28:33 +00:00
parent 076a53fcd3
commit 37e1ff91ea
+8 -1
View File
@@ -186,9 +186,16 @@ UdfBuilder::Build()
_PrintUpdate(VERBOSITY_HIGH, "udf: <location: %ld, length: %ld>",
primaryExtent.location(), primaryExtent.length());
}
// reserve reserve vds
// reserve reserve vds. try to grab the 16 blocks preceding block 256. if
// that fails, just grab any 16. most commercial discs just put the reserve
// vds immediately following the primary vds, which seems a bit stupid to me,
// now that I think about it...
if (!error) {
_PrintUpdate(VERBOSITY_MEDIUM, "udf: Reserving space for reserve vds");
reserveExtent.set_location(256-16);
reserveExtent.set_length(16 << _BlockShift());
error = _Allocator().GetExtent(reserveExtent);
if (error)
error = _Allocator().GetNextExtent(16 << _BlockShift(), true, reserveExtent);
if (!error)
_PrintUpdate(VERBOSITY_HIGH, "udf: <location: %ld, length: %ld>",