ReactOS  0.4.15-dev-2979-gfd8baca
fmifs.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  TEXTOUTPUT
 

Typedefs

typedef struct TEXTOUTPUTPTEXTOUTPUT
 
typedef BOOLEAN(NTAPIPFMIFSCALLBACK) (IN CALLBACKCOMMAND Command, IN ULONG SubAction, IN PVOID ActionInfo)
 
typedef BOOLEAN(NTAPIPULIB_CHKDSK) (IN PUNICODE_STRING DriveRoot, IN PFMIFSCALLBACK Callback, IN BOOLEAN FixErrors, IN BOOLEAN Verbose, IN BOOLEAN CheckOnlyIfDirty, IN BOOLEAN ScanDrive, IN PVOID pUnknown1, IN PVOID pUnknown2, IN PVOID pUnknown3, IN PVOID pUnknown4, IN PULONG ExitStatus)
 
typedef BOOLEAN(NTAPIPULIB_FORMAT) (IN PUNICODE_STRING DriveRoot, IN PFMIFSCALLBACK Callback, IN BOOLEAN QuickFormat, IN BOOLEAN BackwardCompatible, IN MEDIA_TYPE MediaType, IN PUNICODE_STRING Label, IN ULONG ClusterSize)
 

Enumerations

enum  FMIFS_MEDIA_FLAG {
  FMIFS_UNKNOWN0, FMIFS_UNKNOWN1, FMIFS_UNKNOWN2, FMIFS_UNKNOWN3,
  FMIFS_UNKNOWN4, FMIFS_UNKNOWN5, FMIFS_UNKNOWN6, FMIFS_UNKNOWN7,
  FMIFS_FLOPPY, FMIFS_UNKNOWN9, FMIFS_UNKNOWN10, FMIFS_REMOVABLE,
  FMIFS_HARDDISK, FMIFS_UNKNOWN13, FMIFS_UNKNOWN14, FMIFS_UNKNOWN15,
  FMIFS_UNKNOWN16, FMIFS_UNKNOWN17, FMIFS_UNKNOWN18, FMIFS_UNKNOWN19,
  FMIFS_UNKNOWN20, FMIFS_UNKNOWN21, FMIFS_UNKNOWN22, FMIFS_UNKNOWN23,
  FMIFS_UNKNOWN0, FMIFS_UNKNOWN1, FMIFS_UNKNOWN2, FMIFS_UNKNOWN3,
  FMIFS_UNKNOWN4, FMIFS_UNKNOWN5, FMIFS_UNKNOWN6, FMIFS_UNKNOWN7,
  FMIFS_FLOPPY, FMIFS_UNKNOWN9, FMIFS_UNKNOWN10, FMIFS_REMOVABLE,
  FMIFS_HARDDISK, FMIFS_UNKNOWN13, FMIFS_UNKNOWN14, FMIFS_UNKNOWN15,
  FMIFS_UNKNOWN16, FMIFS_UNKNOWN17, FMIFS_UNKNOWN18, FMIFS_UNKNOWN19,
  FMIFS_UNKNOWN20, FMIFS_UNKNOWN21, FMIFS_UNKNOWN22, FMIFS_UNKNOWN23
}
 
enum  CALLBACKCOMMAND {
  PROGRESS, DONEWITHSTRUCTURE, UNKNOWN2, UNKNOWN3,
  UNKNOWN4, UNKNOWN5, INSUFFICIENTRIGHTS, FSNOTSUPPORTED,
  VOLUMEINUSE, UNKNOWN9, UNKNOWNA, DONE,
  UNKNOWNC, UNKNOWND, OUTPUT, STRUCTUREPROGRESS,
  CLUSTERSIZETOOSMALL, PROGRESS, DONEWITHSTRUCTURE, UNKNOWN2,
  UNKNOWN3, UNKNOWN4, UNKNOWN5, INSUFFICIENTRIGHTS,
  FSNOTSUPPORTED, VOLUMEINUSE, UNKNOWN9, UNKNOWNA,
  DONE, UNKNOWNC, UNKNOWND, OUTPUT,
  STRUCTUREPROGRESS, CLUSTERSIZETOOSMALL
}
 

Functions

VOID NTAPI Chkdsk (IN PWCHAR DriveRoot, IN PWCHAR Format, IN BOOLEAN CorrectErrors, IN BOOLEAN Verbose, IN BOOLEAN CheckOnlyIfDirty, IN BOOLEAN ScanDrive, IN PVOID Unused2, IN PVOID Unused3, IN PFMIFSCALLBACK Callback)
 
VOID NTAPI ChkdskEx (IN PWCHAR DriveRoot, IN PWCHAR Format, IN BOOLEAN CorrectErrors, IN BOOLEAN Verbose, IN BOOLEAN CheckOnlyIfDirty, IN BOOLEAN ScanDrive, IN PVOID Unused2, IN PVOID Unused3, IN PFMIFSCALLBACK Callback)
 
FMIFS_MEDIA_FLAG NTAPI ComputeFmMediaType (IN ULONG MediaType)
 
VOID NTAPI DiskCopy (VOID)
 
BOOLEAN NTAPI EnableVolumeCompression (IN PWCHAR DriveRoot, IN USHORT Compression)
 
VOID NTAPI Format (IN PWCHAR DriveRoot, IN FMIFS_MEDIA_FLAG MediaFlag, IN PWCHAR Format, IN PWCHAR Label, IN BOOLEAN QuickFormat, IN PFMIFSCALLBACK Callback)
 
VOID NTAPI FormatEx (IN PWCHAR DriveRoot, IN FMIFS_MEDIA_FLAG MediaFlag, IN PWCHAR Format, IN PWCHAR Label, IN BOOLEAN QuickFormat, IN ULONG ClusterSize, IN PFMIFSCALLBACK Callback)
 
BOOLEAN NTAPI QueryAvailableFileSystemFormat (IN DWORD Index, IN OUT PWCHAR FileSystem, OUT UCHAR *Major, OUT UCHAR *Minor, OUT BOOLEAN *LatestVersion)
 
BOOL NTAPI QueryDeviceInformation (IN PWCHAR DriveRoot, OUT ULONG *Buffer, IN ULONG BufferSize)
 
BOOL NTAPI QueryFileSystemName (IN PWCHAR DriveRoot, OUT PWCHAR FileSystem OPTIONAL, OUT UCHAR *Unknown2 OPTIONAL, OUT UCHAR *Unknown3 OPTIONAL, OUT ULONG *Unknown4 OPTIONAL)
 
BOOLEAN NTAPI QueryLatestFileSystemVersion (IN PWCHAR FileSystem, OUT UCHAR *Major OPTIONAL, OUT UCHAR *Minor OPTIONAL)
 
BOOL NTAPI QuerySupportedMedia (IN PWCHAR DriveRoot, OUT FMIFS_MEDIA_FLAG *CurrentMedia OPTIONAL, IN ULONG Unknown3, OUT PULONG Unknown4)
 
BOOL NTAPI SetLabel (IN PWCHAR DriveRoot, IN PWCHAR Label)
 

Typedef Documentation

◆ PFMIFSCALLBACK

typedef BOOLEAN(NTAPI* PFMIFSCALLBACK) (IN CALLBACKCOMMAND Command, IN ULONG SubAction, IN PVOID ActionInfo)

Definition at line 89 of file fmifs.h.

◆ PTEXTOUTPUT

◆ PULIB_CHKDSK

typedef BOOLEAN(NTAPI * PULIB_CHKDSK) (IN PUNICODE_STRING DriveRoot, IN PFMIFSCALLBACK Callback, IN BOOLEAN FixErrors, IN BOOLEAN Verbose, IN BOOLEAN CheckOnlyIfDirty, IN BOOLEAN ScanDrive, IN PVOID pUnknown1, IN PVOID pUnknown2, IN PVOID pUnknown3, IN PVOID pUnknown4, IN PULONG ExitStatus)

Definition at line 201 of file fmifs.h.

◆ PULIB_FORMAT

typedef BOOLEAN(NTAPI * PULIB_FORMAT) (IN PUNICODE_STRING DriveRoot, IN PFMIFSCALLBACK Callback, IN BOOLEAN QuickFormat, IN BOOLEAN BackwardCompatible, IN MEDIA_TYPE MediaType, IN PUNICODE_STRING Label, IN ULONG ClusterSize)

Definition at line 217 of file fmifs.h.

Enumeration Type Documentation

◆ CALLBACKCOMMAND

Enumerator
PROGRESS 
DONEWITHSTRUCTURE 
UNKNOWN2 
UNKNOWN3 
UNKNOWN4 
UNKNOWN5 
INSUFFICIENTRIGHTS 
FSNOTSUPPORTED 
VOLUMEINUSE 
UNKNOWN9 
UNKNOWNA 
DONE 
UNKNOWNC 
UNKNOWND 
OUTPUT 
STRUCTUREPROGRESS 
CLUSTERSIZETOOSMALL 
PROGRESS 
DONEWITHSTRUCTURE 
UNKNOWN2 
UNKNOWN3 
UNKNOWN4 
UNKNOWN5 
INSUFFICIENTRIGHTS 
FSNOTSUPPORTED 
VOLUMEINUSE 
UNKNOWN9 
UNKNOWNA 
DONE 
UNKNOWNC 
UNKNOWND 
OUTPUT 
STRUCTUREPROGRESS 
CLUSTERSIZETOOSMALL 

Definition at line 66 of file fmifs.h.

67 {
68  PROGRESS,
70  UNKNOWN2,
71  UNKNOWN3,
72  UNKNOWN4,
73  UNKNOWN5,
77  UNKNOWN9,
78  UNKNOWNA,
79  DONE,
80  UNKNOWNC,
81  UNKNOWND,
82  OUTPUT,
Definition: fmifs.h:71
Definition: fmifs.h:72
Definition: fmifs.h:70
Definition: fmifs.h:68
Definition: fmifs.h:78
Definition: fmifs.h:73
CALLBACKCOMMAND
Definition: fmifs.h:66
Definition: fmifs.h:77
Definition: fmifs.h:80
Definition: fmifs.h:79
Definition: fmifs.h:81
Definition: fmifs.h:82

◆ FMIFS_MEDIA_FLAG

Enumerator
FMIFS_UNKNOWN0 
FMIFS_UNKNOWN1 
FMIFS_UNKNOWN2 
FMIFS_UNKNOWN3 
FMIFS_UNKNOWN4 
FMIFS_UNKNOWN5 
FMIFS_UNKNOWN6 
FMIFS_UNKNOWN7 
FMIFS_FLOPPY 
FMIFS_UNKNOWN9 
FMIFS_UNKNOWN10 
FMIFS_REMOVABLE 
FMIFS_HARDDISK 
FMIFS_UNKNOWN13 
FMIFS_UNKNOWN14 
FMIFS_UNKNOWN15 
FMIFS_UNKNOWN16 
FMIFS_UNKNOWN17 
FMIFS_UNKNOWN18 
FMIFS_UNKNOWN19 
FMIFS_UNKNOWN20 
FMIFS_UNKNOWN21 
FMIFS_UNKNOWN22 
FMIFS_UNKNOWN23 
FMIFS_UNKNOWN0 
FMIFS_UNKNOWN1 
FMIFS_UNKNOWN2 
FMIFS_UNKNOWN3 
FMIFS_UNKNOWN4 
FMIFS_UNKNOWN5 
FMIFS_UNKNOWN6 
FMIFS_UNKNOWN7 
FMIFS_FLOPPY 
FMIFS_UNKNOWN9 
FMIFS_UNKNOWN10 
FMIFS_REMOVABLE 
FMIFS_HARDDISK 
FMIFS_UNKNOWN13 
FMIFS_UNKNOWN14 
FMIFS_UNKNOWN15 
FMIFS_UNKNOWN16 
FMIFS_UNKNOWN17 
FMIFS_UNKNOWN18 
FMIFS_UNKNOWN19 
FMIFS_UNKNOWN20 
FMIFS_UNKNOWN21 
FMIFS_UNKNOWN22 
FMIFS_UNKNOWN23 

Definition at line 37 of file fmifs.h.

Function Documentation

◆ Chkdsk()

VOID NTAPI Chkdsk ( IN PWCHAR  DriveRoot,
IN PWCHAR  Format,
IN BOOLEAN  CorrectErrors,
IN BOOLEAN  Verbose,
IN BOOLEAN  CheckOnlyIfDirty,
IN BOOLEAN  ScanDrive,
IN PVOID  Unused2,
IN PVOID  Unused3,
IN PFMIFSCALLBACK  Callback 
)

Definition at line 18 of file chkdsk.c.

28 {
30  UNICODE_STRING usDriveRoot;
34  //CURDIR CurDir;
35 
37  if (!Provider)
38  {
39  /* Unknown file system */
40  Callback(DONE, 0, &Success);
41  return;
42  }
43 
44 #if 1
45  DPRINT1("Warning: use GetVolumeNameForVolumeMountPointW() instead!\n");
46  swprintf(VolumeName, L"\\??\\%c:", towupper(DriveRoot[0]));
47  RtlCreateUnicodeString(&usDriveRoot, VolumeName);
48  /* Code disabled as long as our storage stack doesn't understand IOCTL_MOUNTDEV_QUERY_DEVICE_NAME */
49 #else
51  !RtlDosPathNameToNtPathName_U(VolumeName, &usDriveRoot, NULL, &CurDir))
52  {
53  /* Report an error */
54  Callback(DONE, 0, &Success);
55  return;
56  }
57 #endif
58 
59  DPRINT("Chkdsk() - %S\n", Format);
61  Success = Provider->Chkdsk(&usDriveRoot,
62  Callback,
63  CorrectErrors,
64  Verbose,
65  CheckOnlyIfDirty,
66  ScanDrive,
67  NULL,
68  NULL,
69  NULL,
70  NULL,
71  (PULONG)&Status);
72  if (!Success)
73  DPRINT1("Chkdsk() failed with Status 0x%lx\n", Status);
74 
75  /* Report success */
76  Callback(DONE, 0, &Success);
77 
78  RtlFreeUnicodeString(&usDriveRoot);
79 }
BOOL Verbose
Definition: chkdsk.c:72
LONG NTSTATUS
Definition: precomp.h:26
#define swprintf
Definition: precomp.h:40
#define FALSE
Definition: types.h:117
unsigned char BOOLEAN
Status
Definition: gdiplustypes.h:24
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define MAX_PATH
Definition: compat.h:34
NTSYSAPI VOID NTAPI RtlFreeUnicodeString(PUNICODE_STRING UnicodeString)
NTSYSAPI BOOLEAN NTAPI RtlCreateUnicodeString(PUNICODE_STRING DestinationString, PCWSTR SourceString)
static const WCHAR L[]
Definition: oid.c:1250
_In_ WDFINTERRUPT _In_ PFN_WDF_INTERRUPT_SYNCHRONIZE Callback
Definition: wdfinterrupt.h:456
#define RTL_NUMBER_OF(x)
Definition: RtlRegistry.c:12
unsigned int * PULONG
Definition: retypes.h:1
#define NULL
Definition: types.h:112
#define DPRINT1
Definition: precomp.h:8
_Must_inspect_result_ _Inout_opt_ PUNICODE_STRING VolumeName
Definition: fltkernel.h:1117
#define DONE
Definition: rnr20lib.h:14
#define STATUS_SUCCESS
Definition: shellext.h:65
#define towupper(c)
Definition: wctype.h:99
BOOL WINAPI GetVolumeNameForVolumeMountPointW(IN LPCWSTR VolumeMountPoint, OUT LPWSTR VolumeName, IN DWORD VolumeNameLength)
Definition: mntpoint.c:496
#define DPRINT
Definition: sndvol32.h:71
NTSYSAPI BOOLEAN NTAPI RtlDosPathNameToNtPathName_U(_In_opt_z_ PCWSTR DosPathName, _Out_ PUNICODE_STRING NtPathName, _Out_opt_ PCWSTR *NtFileNamePart, _Out_opt_ PRTL_RELATIVE_NAME_U DirectoryInfo)
PIFS_PROVIDER GetProvider(IN PWCHAR FileSystem)
Definition: init.c:23

Referenced by ChkDskNow(), and wmain().

◆ ChkdskEx()

VOID NTAPI ChkdskEx ( IN PWCHAR  DriveRoot,
IN PWCHAR  Format,
IN BOOLEAN  CorrectErrors,
IN BOOLEAN  Verbose,
IN BOOLEAN  CheckOnlyIfDirty,
IN BOOLEAN  ScanDrive,
IN PVOID  Unused2,
IN PVOID  Unused3,
IN PFMIFSCALLBACK  Callback 
)

◆ ComputeFmMediaType()

FMIFS_MEDIA_FLAG NTAPI ComputeFmMediaType ( IN ULONG  MediaType)

◆ DiskCopy()

VOID NTAPI DiskCopy ( VOID  )

Definition at line 15 of file diskcopy.c.

16 {
17 }

◆ EnableVolumeCompression()

BOOLEAN NTAPI EnableVolumeCompression ( IN PWCHAR  DriveRoot,
IN USHORT  Compression 
)

Definition at line 17 of file compress.c.

20 {
21  HANDLE hFile;
22  DWORD RetBytes;
23  BOOL Ret;
24 
25  hFile = CreateFileW(DriveRoot,
28  NULL,
31  NULL);
33  return FALSE;
34 
35  Ret = DeviceIoControl(hFile,
37  &Compression,
38  sizeof(USHORT),
39  NULL,
40  0,
41  &RetBytes,
42  NULL);
43 
45 
46  return (Ret != 0);
47 }
#define CloseHandle
Definition: compat.h:598
#define FSCTL_SET_COMPRESSION
Definition: nt_native.h:842
#define INVALID_HANDLE_VALUE
Definition: compat.h:590
#define FILE_SHARE_WRITE
Definition: nt_native.h:681
#define FILE_SHARE_READ
Definition: compat.h:136
#define FALSE
Definition: types.h:117
unsigned int BOOL
Definition: ntddk_ex.h:94
#define FILE_READ_DATA
Definition: nt_native.h:628
#define FILE_WRITE_DATA
Definition: nt_native.h:631
#define OPEN_EXISTING
Definition: compat.h:634
unsigned long DWORD
Definition: ntddk_ex.h:95
_In_ HANDLE hFile
Definition: mswsock.h:90
BOOL WINAPI DeviceIoControl(IN HANDLE hDevice, IN DWORD dwIoControlCode, IN LPVOID lpInBuffer OPTIONAL, IN DWORD nInBufferSize OPTIONAL, OUT LPVOID lpOutBuffer OPTIONAL, IN DWORD nOutBufferSize OPTIONAL, OUT LPDWORD lpBytesReturned OPTIONAL, IN LPOVERLAPPED lpOverlapped OPTIONAL)
Definition: deviceio.c:136
unsigned short USHORT
Definition: pedump.c:61
#define NULL
Definition: types.h:112
#define CreateFileW
Definition: compat.h:600
#define FILE_FLAG_BACKUP_SEMANTICS
Definition: disk.h:41

Referenced by wmain().

◆ Format()

VOID NTAPI Format ( IN PWCHAR  DriveRoot,
IN FMIFS_MEDIA_FLAG  MediaFlag,
IN PWCHAR  Format,
IN PWCHAR  Label,
IN BOOLEAN  QuickFormat,
IN PFMIFSCALLBACK  Callback 
)

Definition at line 18 of file format.c.

25 {
26  FormatEx(DriveRoot,
27  MediaFlag,
28  Format,
29  Label,
31  0,
32  Callback);
33 }
BOOL QuickFormat
Definition: format.c:66
VOID NTAPI FormatEx(IN PWCHAR DriveRoot, IN FMIFS_MEDIA_FLAG MediaFlag, IN PWCHAR Format, IN PWCHAR Label, IN BOOLEAN QuickFormat, IN ULONG ClusterSize, IN PFMIFSCALLBACK Callback)
Definition: format.c:38
_In_ WDFINTERRUPT _In_ PFN_WDF_INTERRUPT_SYNCHRONIZE Callback
Definition: wdfinterrupt.h:456
PWCHAR Label
Definition: format.c:70

◆ FormatEx()

VOID NTAPI FormatEx ( IN PWCHAR  DriveRoot,
IN FMIFS_MEDIA_FLAG  MediaFlag,
IN PWCHAR  Format,
IN PWCHAR  Label,
IN BOOLEAN  QuickFormat,
IN ULONG  ClusterSize,
IN PFMIFSCALLBACK  Callback 
)

Definition at line 38 of file format.c.

46 {
48  UNICODE_STRING usDriveRoot;
49  UNICODE_STRING usLabel;
51  BOOLEAN BackwardCompatible = FALSE; // Default to latest FS versions.
52  MEDIA_TYPE MediaType;
54  //CURDIR CurDir;
55 
56 //
57 // TODO: Convert filesystem Format into ULIB format string.
58 //
59 
61  if (!Provider)
62  {
63  /* Unknown file system */
64  Callback(DONE, 0, &Success);
65  return;
66  }
67 
68 #if 1
69  DPRINT1("Warning: use GetVolumeNameForVolumeMountPointW() instead!\n");
70  swprintf(VolumeName, L"\\??\\%c:", towupper(DriveRoot[0]));
71  RtlCreateUnicodeString(&usDriveRoot, VolumeName);
72  /* Code disabled as long as our storage stack doesn't understand IOCTL_MOUNTDEV_QUERY_DEVICE_NAME */
73 #else
75  !RtlDosPathNameToNtPathName_U(VolumeName, &usDriveRoot, NULL, &CurDir))
76  {
77  /* Report an error */
78  Callback(DONE, 0, &Success);
79  return;
80  }
81 #endif
82 
83  RtlInitUnicodeString(&usLabel, Label);
84 
85  /* Set the BackwardCompatible flag in case we format with older FAT12/16 */
86  if (wcsicmp(Format, L"FAT") == 0)
87  BackwardCompatible = TRUE;
88  // else if (wcsicmp(Format, L"FAT32") == 0)
89  // BackwardCompatible = FALSE;
90 
91  /* Convert the FMIFS MediaFlag to a NT MediaType */
92  // FIXME: Actually covert all the possible flags.
93  switch (MediaFlag)
94  {
95  case FMIFS_FLOPPY:
96  MediaType = F5_320_1024; // FIXME: This is hardfixed!
97  break;
98  case FMIFS_REMOVABLE:
99  MediaType = RemovableMedia;
100  break;
101  case FMIFS_HARDDISK:
102  MediaType = FixedMedia;
103  break;
104  default:
105  DPRINT1("Unknown FMIFS MediaFlag %d, converting 1-to-1 to NT MediaType\n",
106  MediaFlag);
107  MediaType = (MEDIA_TYPE)MediaFlag;
108  break;
109  }
110 
111  DPRINT("Format() - %S\n", Format);
112  Success = Provider->Format(&usDriveRoot,
113  Callback,
114  QuickFormat,
115  BackwardCompatible,
116  MediaType,
117  &usLabel,
118  ClusterSize);
119  if (!Success)
120  DPRINT1("Format() failed\n");
121 
122  /* Report success */
123  Callback(DONE, 0, &Success);
124 
125  RtlFreeUnicodeString(&usDriveRoot);
126 }
#define TRUE
Definition: types.h:120
enum _MEDIA_TYPE MEDIA_TYPE
#define swprintf
Definition: precomp.h:40
#define FALSE
Definition: types.h:117
unsigned char BOOLEAN
BOOL QuickFormat
Definition: format.c:66
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define MAX_PATH
Definition: compat.h:34
DWORD ClusterSize
Definition: format.c:67
NTSYSAPI VOID NTAPI RtlFreeUnicodeString(PUNICODE_STRING UnicodeString)
#define wcsicmp
Definition: compat.h:15
NTSYSAPI BOOLEAN NTAPI RtlCreateUnicodeString(PUNICODE_STRING DestinationString, PCWSTR SourceString)
static const WCHAR L[]
Definition: oid.c:1250
_In_ WDFINTERRUPT _In_ PFN_WDF_INTERRUPT_SYNCHRONIZE Callback
Definition: wdfinterrupt.h:456
#define RTL_NUMBER_OF(x)
Definition: RtlRegistry.c:12
#define NULL
Definition: types.h:112
#define DPRINT1
Definition: precomp.h:8
_Must_inspect_result_ _Inout_opt_ PUNICODE_STRING VolumeName
Definition: fltkernel.h:1117
NTSYSAPI VOID NTAPI RtlInitUnicodeString(PUNICODE_STRING DestinationString, PCWSTR SourceString)
PWCHAR Label
Definition: format.c:70
#define DONE
Definition: rnr20lib.h:14
#define towupper(c)
Definition: wctype.h:99
BOOL WINAPI GetVolumeNameForVolumeMountPointW(IN LPCWSTR VolumeMountPoint, OUT LPWSTR VolumeName, IN DWORD VolumeNameLength)
Definition: mntpoint.c:496
#define DPRINT
Definition: sndvol32.h:71
NTSYSAPI BOOLEAN NTAPI RtlDosPathNameToNtPathName_U(_In_opt_z_ PCWSTR DosPathName, _Out_ PUNICODE_STRING NtPathName, _Out_opt_ PCWSTR *NtFileNamePart, _Out_opt_ PRTL_RELATIVE_NAME_U DirectoryInfo)
PIFS_PROVIDER GetProvider(IN PWCHAR FileSystem)
Definition: init.c:23

Referenced by Format(), FormatDrive(), and wmain().

◆ QueryAvailableFileSystemFormat()

BOOLEAN NTAPI QueryAvailableFileSystemFormat ( IN DWORD  Index,
IN OUT PWCHAR  FileSystem,
OUT UCHAR Major,
OUT UCHAR Minor,
OUT BOOLEAN LatestVersion 
)

Definition at line 14 of file query.c.

20 {
21  PLIST_ENTRY ListEntry;
23 
24  if (!FileSystem || !Major ||!Minor ||!LatestVersion)
25  return FALSE;
26 
27  ListEntry = ProviderListHead.Flink;
28  while (TRUE)
29  {
30  if (ListEntry == &ProviderListHead)
31  return FALSE;
32  if (Index == 0)
33  break;
34  ListEntry = ListEntry->Flink;
35  Index--;
36  }
37 
38  Provider = CONTAINING_RECORD(ListEntry, IFS_PROVIDER, ListEntry);
39  wcscpy(FileSystem, Provider->Name);
40  *Major = 0; /* FIXME */
41  *Minor = 0; /* FIXME */
42  *LatestVersion = TRUE; /* FIXME */
43 
44  return TRUE;
45 }
_Out_opt_ PULONG Minor
Definition: cmfuncs.h:44
PWCHAR FileSystem
Definition: format.c:72
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
PFLT_MESSAGE_WAITER_QUEUE CONTAINING_RECORD(Csq, DEVICE_EXTENSION, IrpQueue)) -> WaiterQ.mLock) _IRQL_raises_(DISPATCH_LEVEL) VOID NTAPI FltpAcquireMessageWaiterLock(_In_ PIO_CSQ Csq, _Out_ PKIRQL Irql)
Definition: Messaging.c:560
struct _LIST_ENTRY * Flink
Definition: typedefs.h:121
_In_ WDFCOLLECTION _In_ ULONG Index
LIST_ENTRY ProviderListHead
Definition: init.c:20
_CRTIMP wchar_t *__cdecl wcscpy(_Out_writes_z_(_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
Definition: typedefs.h:119

Referenced by InitializeFormatDriveDlg(), and Usage().

◆ QueryDeviceInformation()

BOOL NTAPI QueryDeviceInformation ( IN PWCHAR  DriveRoot,
OUT ULONG Buffer,
IN ULONG  BufferSize 
)

◆ QueryFileSystemName()

BOOL NTAPI QueryFileSystemName ( IN PWCHAR  DriveRoot,
OUT PWCHAR FileSystem  OPTIONAL,
OUT UCHAR *Unknown2  OPTIONAL,
OUT UCHAR *Unknown3  OPTIONAL,
OUT ULONG *Unknown4  OPTIONAL 
)

◆ QueryLatestFileSystemVersion()

BOOLEAN NTAPI QueryLatestFileSystemVersion ( IN PWCHAR  FileSystem,
OUT UCHAR *Major  OPTIONAL,
OUT UCHAR *Minor  OPTIONAL 
)

◆ QuerySupportedMedia()

BOOL NTAPI QuerySupportedMedia ( IN PWCHAR  DriveRoot,
OUT FMIFS_MEDIA_FLAG *CurrentMedia  OPTIONAL,
IN ULONG  Unknown3,
OUT PULONG  Unknown4 
)

Definition at line 15 of file media.c.

20 {
21  return FALSE;
22 }
#define FALSE
Definition: types.h:117

◆ SetLabel()

BOOL NTAPI SetLabel ( IN PWCHAR  DriveRoot,
IN PWCHAR  Label 
)