Author: cfinck
Date: Tue Aug 22 09:09:19 2017
New Revision: 75638
URL:
http://svn.reactos.org/svn/reactos?rev=75638&view=rev
Log:
[FS_REC]
Always register CDFS as a low-priority filesystem. This inserts it at the tail of the
filesystem queue instead of the head, meaning UDF always takes precedence and UDF/CDFS
hybrid media is properly detected as UDF.
Thanks to Pierre for the hint!
Should fix what's reported in
https://jira.reactos.org/browse/CORE-9816?focusedCommentId=78820&page=c…
Modified:
trunk/reactos/drivers/filesystems/fs_rec/fs_rec.c
Modified: trunk/reactos/drivers/filesystems/fs_rec/fs_rec.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/fs_rec…
==============================================================================
--- trunk/reactos/drivers/filesystems/fs_rec/fs_rec.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/filesystems/fs_rec/fs_rec.c [iso-8859-1] Tue Aug 22 09:09:19
2017
@@ -220,7 +220,8 @@
IN PCWSTR FsName,
IN PCWSTR RecognizerName,
IN ULONG FsType,
- IN DEVICE_TYPE DeviceType)
+ IN DEVICE_TYPE DeviceType,
+ IN ULONG AdditionalFlags)
{
OBJECT_ATTRIBUTES ObjectAttributes;
IO_STATUS_BLOCK IoStatus;
@@ -278,6 +279,9 @@
&DeviceObject);
if (NT_SUCCESS(Status))
{
+ /* Set additional flags in the device object */
+ DeviceObject->Flags |= AdditionalFlags;
+
/* Get the device extension and set it up */
DeviceExtension = DeviceObject->DeviceExtension;
DeviceExtension->FsType = FsType;
@@ -348,7 +352,8 @@
L"\\Cdfs",
L"\\FileSystem\\CdfsRecognizer",
FS_TYPE_CDFS,
- FILE_DEVICE_CD_ROM_FILE_SYSTEM);
+ FILE_DEVICE_CD_ROM_FILE_SYSTEM,
+ DO_LOW_PRIORITY_FILESYSTEM);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register CDFS for HDDs */
@@ -358,7 +363,8 @@
L"\\CdfsHdd",
L"\\FileSystem\\CdfsHddRecognizer",
FS_TYPE_CDFS,
- FILE_DEVICE_DISK_FILE_SYSTEM);
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ DO_LOW_PRIORITY_FILESYSTEM);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register UDFS for CDs */
@@ -368,7 +374,8 @@
L"\\UdfsCdRom",
L"\\FileSystem\\UdfsCdRomRecognizer",
FS_TYPE_UDFS,
- FILE_DEVICE_CD_ROM_FILE_SYSTEM);
+ FILE_DEVICE_CD_ROM_FILE_SYSTEM,
+ 0);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register UDFS for HDDs */
@@ -378,7 +385,8 @@
L"\\UdfsDisk",
L"\\FileSystem\\UdfsDiskRecognizer",
FS_TYPE_UDFS,
- FILE_DEVICE_DISK_FILE_SYSTEM);
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ 0);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register FAT */
@@ -388,7 +396,8 @@
L"\\Fat",
L"\\FileSystem\\FatRecognizer",
FS_TYPE_VFAT,
- FILE_DEVICE_DISK_FILE_SYSTEM);
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ 0);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register NTFS */
@@ -398,7 +407,8 @@
L"\\Ntfs",
L"\\FileSystem\\NtfsRecognizer",
FS_TYPE_NTFS,
- FILE_DEVICE_DISK_FILE_SYSTEM);
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ 0);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register EXT2 */
@@ -408,7 +418,8 @@
L"\\Ext2fs",
L"\\FileSystem\\Ext2Recognizer",
FS_TYPE_EXT2,
- FILE_DEVICE_DISK_FILE_SYSTEM);
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ 0);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register BTRFS */
@@ -418,7 +429,8 @@
L"\\Btrfs",
L"\\FileSystem\\BtrfsRecognizer",
FS_TYPE_BTRFS,
- FILE_DEVICE_DISK_FILE_SYSTEM);
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ 0);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register REISERFS */
@@ -428,7 +440,8 @@
L"\\Reiserfs",
L"\\FileSystem\\ReiserfsRecognizer",
FS_TYPE_REISERFS,
- FILE_DEVICE_DISK_FILE_SYSTEM);
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ 0);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Register FFS */
@@ -438,7 +451,8 @@
L"\\ffs",
L"\\FileSystem\\FfsRecognizer",
FS_TYPE_FFS,
- FILE_DEVICE_DISK_FILE_SYSTEM);
+ FILE_DEVICE_DISK_FILE_SYSTEM,
+ 0);
if (NT_SUCCESS(Status)) DeviceCount++;
/* Return appropriate Status */