// non-MMC-compliant devices also from sense codes.
//
- DBGTRACE(ClassDebugTrace, ("ClassSendEjectionNotification: media EJECT_REQUEST"));
+ DBGTRACE(ClassDebugTrace, ("ClassSendEjectionNotification: media EJECT_REQUEST"));
ClasspSendNotification(FdoExtension,
&GUID_IO_MEDIA_EJECT_REQUEST,
0,
The call to StartNextPacket may occur before this routine is completed.
the operational change notifications are informational in nature, and
- while useful, are not neccessary to ensure proper operation. For example,
+ while useful, are not necessary to ensure proper operation. For example,
if the device morphs to no longer supporting WRITE commands, all further
write commands will fail. There exists a small timing window wherein
IOCTL_IS_DISK_WRITABLE may be called and get an incorrect response. If
&GUID_IO_GENERIC_GESN_EVENT,
sizeof(NOTIFICATION_EVENT_STATUS_HEADER) + dataLength,
Header)
-*/
+*/
switch (Header->NotificationClass) {
KeQuerySystemTime(&(externalData.SystemTime));
externalData.SystemTime.QuadPart *= (LONGLONG)KeQueryTimeIncrement();
- DBGTRACE(ClassDebugTrace, ("ClasspInterpretGesnData: media DEVICE_EXTERNAL_REQUEST"));
+ DBGTRACE(ClassDebugTrace, ("ClasspInterpretGesnData: media DEVICE_EXTERNAL_REQUEST"));
ClasspSendNotification(FdoExtension,
&GUID_IO_DEVICE_EXTERNAL_REQUEST,
sizeof(DEVICE_EVENT_EXTERNAL_REQUEST),
busyData.Estimated100msToReady
));
- DBGTRACE(ClassDebugTrace, ("ClasspInterpretGesnData: media BECOMING_READY"));
+ DBGTRACE(ClassDebugTrace, ("ClasspInterpretGesnData: media BECOMING_READY"));
ClasspSendNotification(FdoExtension,
&GUID_IO_DEVICE_BECOMING_READY,
sizeof(DEVICE_EVENT_BECOMING_READY),
}
- } // end switch on notification class
+ } // end switch on notification class
return;
}
sizeof(ULONG),
&data);
- }
+ }
else if (NewState == MediaNotPresent) {
DBGTRACE(ClassDebugTrace, ("ClasspInternalSetMediaChangeState: media REMOVAL"));
PSENSE_DATA senseData = srb->SenseInfoBuffer;
- if ((senseData->SenseKey == SCSI_SENSE_NOT_READY) &&
+ if ((senseData->SenseKey == SCSI_SENSE_NOT_READY) &&
(senseData->AdditionalSenseCode == SCSI_ADSENSE_LUN_NOT_READY)){
srb->SrbStatus = SRB_STATUS_SUCCESS;
}
- }
-
+ }
+
//
// use ClassInterpretSenseInfo() to check for media state, and also
&status,
NULL);
- }
+ }
else {
fdoData->LoggedTURFailureSinceLastIO = FALSE;
status = STATUS_SUCCESS;
}
- if (!NT_SUCCESS(status)) {
+ if (!NT_SUCCESS(status)) {
DBGTRACE(ClassDebugMCN, ("ClasspMediaChangeDetectionCompletion: GESN failed with status %x", status));
} else {
if (status == REMOVE_COMPLETE) {
ASSERT(status != REMOVE_COMPLETE);
return NULL;
- }
+ }
else if (status == REMOVE_PENDING) {
ClassReleaseRemoveLock(FdoExtension->DeviceObject, irp);
return NULL;
key "Autorun" in the service key (for legacy reasons), and then look in
the device-specific key to potentially override that setting.
- If MCN is to be enabled, all neccessary structures and memory are
+ If MCN is to be enabled, all necessary structures and memory are
allocated and initialized.
This routine MUST be called only from the ClassInit() callback.
//
InterlockedExchange((PLONG)&info->CountDown, info->Period);
- workItem = InterlockedExchangePointer(&info->WorkQueueItem, NULL);
+ workItem = InterlockedExchangePointer((PVOID*)&info->WorkQueueItem, NULL);
if (ClasspCanSendPollingIrp(fdoExtension)) {