ReactOS 0.4.16-dev-197-g92996da
|
#include "ntddk.h"
#include "scsi.h"
#include <wmidata.h>
#include "classpnp.h"
#include <wmistr.h>
#include "ntstrsafe.h"
#include <storswtr.h>
Go to the source code of this file.
Classes | |
struct | _DISK_GROUP_CONTEXT |
struct | _DISK_DATA |
struct | _DISK_MEDIA_TYPES_LIST |
struct | DISKREREGREQUEST |
struct | _DISK_VERIFY_WORKITEM_CONTEXT |
Typedefs | |
typedef struct _DISK_GROUP_CONTEXT | DISK_GROUP_CONTEXT |
typedef struct _DISK_GROUP_CONTEXT * | PDISK_GROUP_CONTEXT |
typedef enum _DISK_USER_WRITE_CACHE_SETTING | DISK_USER_WRITE_CACHE_SETTING |
typedef enum _DISK_USER_WRITE_CACHE_SETTING * | PDISK_USER_WRITE_CACHE_SETTING |
typedef struct _DISK_DATA | DISK_DATA |
typedef struct _DISK_DATA * | PDISK_DATA |
typedef struct _DISK_MEDIA_TYPES_LIST | DISK_MEDIA_TYPES_LIST |
typedef struct _DISK_MEDIA_TYPES_LIST * | PDISK_MEDIA_TYPES_LIST |
typedef struct DISKREREGREQUEST * | PDISKREREGREQUEST |
typedef struct _DISK_VERIFY_WORKITEM_CONTEXT | DISK_VERIFY_WORKITEM_CONTEXT |
typedef struct _DISK_VERIFY_WORKITEM_CONTEXT * | PDISK_VERIFY_WORKITEM_CONTEXT |
Enumerations | |
enum | _DISK_USER_WRITE_CACHE_SETTING { DiskWriteCacheDisable = 0 , DiskWriteCacheEnable = 1 , DiskWriteCacheDefault = -1 } |
Variables | |
CLASSPNP_SCAN_FOR_SPECIAL_INFO | DiskBadControllers [] |
const DISK_MEDIA_TYPES_LIST | DiskMediaTypes [] |
const DISK_MEDIA_TYPES_LIST | DiskMediaTypesExclude [] |
DRIVER_INITIALIZE | DriverEntry |
IO_WORKITEM_ROUTINE | DisableWriteCache |
IO_WORKITEM_ROUTINE | DiskIoctlVerifyThread |
IO_COMPLETION_ROUTINE | DiskFlushComplete |
GUIDREGINFO | DiskWmiFdoGuidList [] |
#define CHECK_IRQL | ( | ) |
#define DEBUG_COMP_ID DPFLTR_DISK_ID |
#define DiskDeviceCacheIsPowerProtected L"CacheIsPowerProtected" |
#define DiskDeviceUserWriteCacheSetting L"UserWriteCacheSetting" |
#define DiskGetDetectInfo | ( | FdoExtension, | |
DetectInfo | |||
) | (STATUS_UNSUCCESSFUL) |
#define DiskIsValidSmartSelfTest | ( | Subcommand | ) |
#define DiskReadDriveCapacity | ( | Fdo | ) | ClassReadDriveCapacity(Fdo) |
#define FUNCTIONAL_EXTENSION_SIZE sizeof(FUNCTIONAL_DEVICE_EXTENSION) + sizeof(DISK_DATA) |
#define WPP_CONTROL_GUIDS WPP_CONTROL_GUIDS_NORMAL_FLAGS(WPP_GUID_DISK) |
#define WPP_GUID_DISK (945186BF, 3DD6, 4f3f, 9C8E, 9EDD3FC9D558) |
typedef struct _DISK_DATA DISK_DATA |
typedef struct _DISK_DATA * PDISK_DATA |
typedef struct _DISK_GROUP_CONTEXT * PDISK_GROUP_CONTEXT |
typedef struct DISKREREGREQUEST * PDISKREREGREQUEST |
Enumerator | |
---|---|
DiskWriteCacheDisable | |
DiskWriteCacheEnable | |
DiskWriteCacheDefault |
Definition at line 177 of file disk.h.
NTSTATUS NTAPI DiskAddDevice | ( | IN PDRIVER_OBJECT | DriverObject, |
IN PDEVICE_OBJECT | Pdo | ||
) |
Definition at line 53 of file pnp.c.
Referenced by DriverEntry().
NTSTATUS DiskCreateFdo | ( | IN PDRIVER_OBJECT | DriverObject, |
IN PDEVICE_OBJECT | LowerDeviceObject, | ||
IN PULONG | DeviceCount, | ||
IN BOOLEAN | DasdAccessOnly | ||
) |
Definition at line 307 of file disk.c.
Referenced by DiskAddDevice().
VOID DiskCreateSymbolicLinks | ( | IN PDEVICE_OBJECT | DeviceObject | ) |
Definition at line 676 of file pnp.c.
Referenced by DiskInitFdo().
VOID DiskDeleteSymbolicLinks | ( | IN PDEVICE_OBJECT | DeviceObject | ) |
Definition at line 780 of file pnp.c.
Referenced by DiskRemoveDevice().
NTSTATUS DiskDetectFailurePrediction | ( | PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
PFAILURE_PREDICTION_METHOD | FailurePredictCapability, | ||
BOOLEAN | ScsiAddressAvailable | ||
) |
Definition at line 2230 of file diskwmi.c.
Referenced by DiskInitFdo().
NTSTATUS DiskDetermineMediaTypes | ( | IN PDEVICE_OBJECT | Fdo, |
IN PIRP | Irp, | ||
IN UCHAR | MediumType, | ||
IN UCHAR | DensityCode, | ||
IN BOOLEAN | MediaPresent, | ||
IN BOOLEAN | IsWritable | ||
) |
Definition at line 655 of file disk.c.
Referenced by DiskIoctlGetMediaTypesEx().
NTSTATUS DiskEnableDisableFailurePrediction | ( | PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
BOOLEAN | Enable | ||
) |
Definition at line 1126 of file diskwmi.c.
Referenced by DiskEnableDisableFailurePredictPolling(), DiskFdoExecuteWmiMethod(), DiskIoctlEnableFailurePrediction(), and DiskWmiFunctionControl().
NTSTATUS DiskEnableDisableFailurePredictPolling | ( | PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
BOOLEAN | Enable, | ||
ULONG | PollTimeInSeconds | ||
) |
Definition at line 1193 of file diskwmi.c.
Referenced by DiskFdoExecuteWmiMethod(), DiskInitFdo(), and DiskWmiFunctionControl().
NTSTATUS DiskEnableInfoExceptions | ( | _In_ PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
_In_ BOOLEAN | Enable | ||
) |
Definition at line 979 of file diskwmi.c.
Referenced by DiskIoctlEnableFailurePrediction().
NTSTATUS NTAPI DiskFdoExecuteWmiMethod | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp, | ||
IN ULONG | GuidIndex, | ||
IN ULONG | MethodId, | ||
IN ULONG | InBufferSize, | ||
IN ULONG | OutBufferSize, | ||
IN PUCHAR | Buffer | ||
) |
Definition at line 3045 of file diskwmi.c.
Referenced by DriverEntry().
VOID NTAPI DiskFdoProcessError | ( | PDEVICE_OBJECT | DeviceObject, |
PSCSI_REQUEST_BLOCK | Srb, | ||
NTSTATUS * | Status, | ||
BOOLEAN * | Retry | ||
) |
Definition at line 2276 of file disk.c.
Referenced by DriverEntry().
NTSTATUS NTAPI DiskFdoQueryWmiDataBlock | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp, | ||
IN ULONG | GuidIndex, | ||
IN ULONG | BufferAvail, | ||
OUT PUCHAR | Buffer | ||
) |
Definition at line 2638 of file diskwmi.c.
Referenced by DriverEntry().
NTSTATUS NTAPI DiskFdoQueryWmiRegInfo | ( | IN PDEVICE_OBJECT | DeviceObject, |
OUT ULONG * | RegFlags, | ||
OUT PUNICODE_STRING | InstanceName | ||
) |
Definition at line 2479 of file diskwmi.c.
Referenced by DiskFdoQueryWmiRegInfoEx(), and DriverEntry().
NTSTATUS NTAPI DiskFdoQueryWmiRegInfoEx | ( | IN PDEVICE_OBJECT | DeviceObject, |
OUT ULONG * | RegFlags, | ||
OUT PUNICODE_STRING | InstanceName, | ||
OUT PUNICODE_STRING | MofName | ||
) |
Definition at line 2577 of file diskwmi.c.
Referenced by DriverEntry().
NTSTATUS NTAPI DiskFdoSetWmiDataBlock | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp, | ||
IN ULONG | GuidIndex, | ||
IN ULONG | BufferSize, | ||
IN PUCHAR | Buffer | ||
) |
Definition at line 2869 of file diskwmi.c.
Referenced by DriverEntry().
NTSTATUS NTAPI DiskFdoSetWmiDataItem | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp, | ||
IN ULONG | GuidIndex, | ||
IN ULONG | DataItemId, | ||
IN ULONG | BufferSize, | ||
IN PUCHAR | Buffer | ||
) |
Definition at line 2975 of file diskwmi.c.
Referenced by DriverEntry().
VOID DiskFlushDispatch | ( | IN PDEVICE_OBJECT | Fdo, |
IN PDISK_GROUP_CONTEXT | FlushContext | ||
) |
Definition at line 1534 of file disk.c.
Referenced by DiskShutdownFlush().
Definition at line 612 of file pnp.c.
Referenced by DiskCreateFdo().
NTSTATUS NTAPI DiskGetCacheInformation | ( | IN PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
IN PDISK_CACHE_INFORMATION | CacheInfo | ||
) |
Definition at line 3019 of file disk.c.
Referenced by DiskIoctlGetCacheInformation(), and DiskStartFdo().
NTSTATUS DiskGetInfoExceptionInformation | ( | IN PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
OUT PMODE_INFO_EXCEPTIONS | ReturnPageData | ||
) |
NTSTATUS DiskGetModePage | ( | _In_ PDEVICE_OBJECT | Fdo, |
_In_ UCHAR | PageMode, | ||
_In_ UCHAR | PageControl, | ||
_In_ PMODE_PARAMETER_HEADER | ModeData, | ||
_Inout_ PULONG | ModeDataSize, | ||
_Out_ PVOID * | PageData | ||
) |
Definition at line 903 of file diskwmi.c.
Referenced by DiskEnableInfoExceptions().
NTSTATUS NTAPI DiskInitFdo | ( | IN PDEVICE_OBJECT | Fdo | ) |
Definition at line 202 of file pnp.c.
Referenced by DriverEntry().
Definition at line 1560 of file diskwmi.c.
Referenced by DriverEntry().
Definition at line 5313 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 4419 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 3840 of file disk.c.
Referenced by DiskDeviceControl().
NTSTATUS DiskIoctlGetCacheSetting | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp | ||
) |
Definition at line 3347 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 3582 of file disk.c.
Referenced by DiskDeviceControl().
NTSTATUS DiskIoctlGetDriveGeometryEx | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp | ||
) |
NTSTATUS DiskIoctlGetLengthInfo | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp | ||
) |
Definition at line 3994 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 5461 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 5063 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 4268 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 4648 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 4855 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 3917 of file disk.c.
Referenced by DiskDeviceControl().
NTSTATUS DiskIoctlSetCacheSetting | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp | ||
) |
Definition at line 3415 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 5264 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 5540 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 5663 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 5890 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 5362 of file disk.c.
Referenced by DiskDeviceControl().
Definition at line 4526 of file disk.c.
Referenced by DiskDeviceControl().
VOID DiskLogCacheInformation | ( | IN PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
IN PDISK_CACHE_INFORMATION | CacheInfo, | ||
IN NTSTATUS | Status | ||
) |
Definition at line 2856 of file disk.c.
Referenced by DiskIoctlSetCacheInformation().
NTSTATUS DiskModeSelect | ( | IN PDEVICE_OBJECT | DeviceObject, |
_In_reads_bytes_(Length) PCHAR | ModeSelectBuffer, | ||
IN ULONG | Length, | ||
IN BOOLEAN | SavePage | ||
) |
Definition at line 1802 of file disk.c.
Referenced by DiskSetCacheInformation(), and DiskSetInfoExceptionInformation().
NTSTATUS DiskPerformSmartCommand | ( | IN PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
IN ULONG | SrbControlCode, | ||
IN UCHAR | Command, | ||
IN UCHAR | Feature, | ||
IN UCHAR | SectorCount, | ||
IN UCHAR | SectorNumber, | ||
IN OUT PSRB_IO_CONTROL | SrbControl, | ||
OUT PULONG | BufferSize | ||
) |
Definition at line 476 of file diskwmi.c.
Referenced by DiskDisableSmart(), DiskDisableSmartAttributeAutosave(), DiskEnableSmart(), DiskEnableSmartAttributeAutosave(), DiskExecuteSmartDiagnostics(), DiskReadSmartLog(), and DiskWriteSmartLog().
NTSTATUS DiskReadFailurePredictData | ( | PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
PSTORAGE_FAILURE_PREDICT_DATA | DiskSmartData | ||
) |
Definition at line 1327 of file diskwmi.c.
Referenced by DiskIoctlPredictFailure().
NTSTATUS DiskReadFailurePredictStatus | ( | PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
PSTORAGE_FAILURE_PREDICT_STATUS | DiskSmartStatus | ||
) |
Definition at line 1251 of file diskwmi.c.
Referenced by DiskDetectFailurePrediction(), and DiskIoctlPredictFailure().
Definition at line 546 of file disk.c.
Referenced by DriverEntry().
Definition at line 843 of file pnp.c.
Referenced by DriverEntry().
NTSTATUS NTAPI DiskSetCacheInformation | ( | IN PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
IN PDISK_CACHE_INFORMATION | CacheInfo | ||
) |
Definition at line 3167 of file disk.c.
Referenced by DiskIoctlSetCacheInformation(), and DiskStartFdo().
NTSTATUS DiskSetInfoExceptionInformation | ( | IN PFUNCTIONAL_DEVICE_EXTENSION | FdoExtension, |
IN PMODE_INFO_EXCEPTIONS | PageData | ||
) |
Definition at line 2985 of file disk.c.
Referenced by DiskFdoExecuteWmiMethod(), and DiskFdoSetWmiDataBlock().
Definition at line 2602 of file disk.c.
Referenced by DiskInitFdo().
Definition at line 1122 of file disk.c.
Referenced by DriverEntry().
NTSTATUS NTAPI DiskStartFdo | ( | IN PDEVICE_OBJECT | Fdo | ) |
Definition at line 911 of file pnp.c.
Referenced by DriverEntry().
VOID NTAPI DiskUnload | ( | IN PDRIVER_OBJECT | DriverObject | ) |
Definition at line 281 of file disk.c.
Referenced by DriverEntry().
NTSTATUS NTAPI DiskWmiFunctionControl | ( | IN PDEVICE_OBJECT | DeviceObject, |
IN PIRP | Irp, | ||
IN ULONG | GuidIndex, | ||
IN CLASSENABLEDISABLEFUNCTION | Function, | ||
IN BOOLEAN | Enable | ||
) |
Definition at line 2366 of file diskwmi.c.
Referenced by DriverEntry().
FORCEINLINE PCDB GetSrbScsiData | ( | _In_ PSTORAGE_REQUEST_BLOCK | SrbEx, |
_In_opt_ PUCHAR | CdbLength8, | ||
_In_opt_ PULONG | CdbLength32, | ||
_In_opt_ PUCHAR | ScsiStatus, | ||
_In_opt_ PVOID * | SenseInfoBuffer, | ||
_In_opt_ PUCHAR | SenseInfoBufferLength | ||
) |
Definition at line 994 of file disk.h.
Referenced by DiskFdoProcessError(), and DiskInfoExceptionComplete().
VOID ResetBus | ( | IN PDEVICE_OBJECT | DeviceObject | ) |
Definition at line 2705 of file disk.c.
Referenced by DiskFdoProcessError().
FORCEINLINE VOID SetSrbScsiData | ( | _In_ PSTORAGE_REQUEST_BLOCK | SrbEx, |
_In_ UCHAR | CdbLength8, | ||
_In_ ULONG | CdbLength32, | ||
_In_ UCHAR | ScsiStatus, | ||
_In_opt_ PVOID | SenseInfoBuffer, | ||
_In_ UCHAR | SenseInfoBufferLength | ||
) |
Definition at line 1184 of file disk.h.
Referenced by DiskInfoExceptionComplete().
IO_WORKITEM_ROUTINE DisableWriteCache |
Definition at line 589 of file disk.h.
Referenced by DiskFdoProcessError().
|
extern |
Definition at line 42 of file data.c.
Referenced by DiskInitFdo().
IO_COMPLETION_ROUTINE DiskFlushComplete |
Definition at line 599 of file disk.h.
Referenced by DiskFlushDispatch().
IO_WORKITEM_ROUTINE DiskIoctlVerifyThread |
Definition at line 591 of file disk.h.
Referenced by DiskIoctlVerify().
|
extern |
Definition at line 82 of file data.c.
Referenced by DiskDetermineMediaTypes().
|
extern |
Definition at line 74 of file data.c.
Referenced by DiskDetermineMediaTypes().
|
extern |
Definition at line 92 of file diskwmi.c.
Referenced by DiskFdoQueryWmiRegInfo(), and DriverEntry().