bootloader: Use the already-detected filesystem module...
...rather than enumerating again. Solves a TODO (all filesystems save tarfs and packagefs, which require special parameters and of course will not be on standard "partitions", have implemented the required function.)
This commit is contained in:
parent
450dd5db3a
commit
1fef0f0fa8
@ -357,7 +357,7 @@ Partition::Scan(bool mountFileSystems, bool isBootDevice)
|
||||
}
|
||||
|
||||
// find the best FS module
|
||||
const file_system_module_info *bestFSModule = NULL;
|
||||
file_system_module_info *bestFSModule = NULL;
|
||||
float bestFSPriority = -1;
|
||||
for (int32 i = 0; i < sNumFileSystemModules; i++) {
|
||||
if (sFileSystemModules[i]->identify_file_system == NULL)
|
||||
@ -426,12 +426,8 @@ Partition::Scan(bool mountFileSystems, bool isBootDevice)
|
||||
}
|
||||
|
||||
// scan for file systems
|
||||
|
||||
if (mountFileSystems) {
|
||||
// TODO: Use the FS module we've got, if any. Requires to implement the
|
||||
// identify_file_system() hook in every FS.
|
||||
return Mount();
|
||||
}
|
||||
if (mountFileSystems)
|
||||
return _Mount(bestFSModule, NULL);
|
||||
|
||||
return B_ENTRY_NOT_FOUND;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user