mirror of
https://github.com/reactos/reactos.git
synced 2025-02-23 17:05:46 +00:00
fix some issues found by prefast
svn path=/trunk/; revision=28830
This commit is contained in:
parent
9786ea3b93
commit
0c92f06002
4 changed files with 11 additions and 9 deletions
|
@ -70,7 +70,7 @@ VOID NTAPI CsqRemoveIrp(PIO_CSQ UnusedCsq,
|
|||
*/
|
||||
{
|
||||
UNREFERENCED_PARAMETER(UnusedCsq);
|
||||
DPRINT("CSQ: Removing IRP 0x%x\n", Irp);
|
||||
DPRINT("CSQ: Removing IRP 0x%p\n", Irp);
|
||||
RemoveEntryList(&Irp->Tail.Overlay.ListEntry);
|
||||
}
|
||||
|
||||
|
@ -148,7 +148,7 @@ VOID NTAPI CsqCompleteCanceledIrp(PIO_CSQ UnusedCsq,
|
|||
*/
|
||||
{
|
||||
UNREFERENCED_PARAMETER(UnusedCsq);
|
||||
DPRINT("CSQ: Canceling irp 0x%x\n", Irp);
|
||||
DPRINT("CSQ: Canceling irp 0x%p\n", Irp);
|
||||
Irp->IoStatus.Status = STATUS_CANCELLED;
|
||||
Irp->IoStatus.Information = 0;
|
||||
IoCompleteRequest(Irp, IO_NO_INCREMENT);
|
||||
|
@ -173,7 +173,7 @@ VOID NTAPI CsqInsertIrp(PIO_CSQ UnusedCsq,
|
|||
*/
|
||||
{
|
||||
UNREFERENCED_PARAMETER(UnusedCsq);
|
||||
DPRINT("CSQ: Inserting IRP 0x%x\n", Irp);
|
||||
DPRINT("CSQ: Inserting IRP 0x%p\n", Irp);
|
||||
InsertTailList(&IrpQueue, &Irp->Tail.Overlay.ListEntry);
|
||||
KeReleaseSemaphore(&QueueSemaphore, 0, 1, FALSE);
|
||||
}
|
||||
|
|
|
@ -674,7 +674,7 @@ static NTSTATUS NTAPI InitController(PCONTROLLER_INFO ControllerInfo)
|
|||
PAGED_CODE();
|
||||
ASSERT(ControllerInfo);
|
||||
|
||||
DPRINT("floppy: InitController called with Controller 0x%x\n", ControllerInfo);
|
||||
DPRINT("floppy: InitController called with Controller 0x%p\n", ControllerInfo);
|
||||
|
||||
KeClearEvent(&ControllerInfo->SynchEvent);
|
||||
|
||||
|
@ -785,7 +785,7 @@ static NTSTATUS NTAPI InitController(PCONTROLLER_INFO ControllerInfo)
|
|||
*/
|
||||
for(i = 0; i < ControllerInfo->NumberOfDrives; i++)
|
||||
{
|
||||
DPRINT("floppy: InitController: recalibrating drive 0x%x on controller 0x%x\n", i, ControllerInfo);
|
||||
DPRINT("floppy: InitController: recalibrating drive 0x%x on controller 0x%p\n", i, ControllerInfo);
|
||||
Recalibrate(&ControllerInfo->DriveInfo[i]);
|
||||
}
|
||||
|
||||
|
@ -849,7 +849,7 @@ static BOOLEAN NTAPI AddControllers(PDRIVER_OBJECT DriverObject)
|
|||
/* Must set up the DPC before we connect the interrupt */
|
||||
KeInitializeDpc(&gControllerInfo[i].Dpc, DpcForIsr, &gControllerInfo[i]);
|
||||
|
||||
DPRINT("floppy: Connecting interrupt %d to controller%d (object 0x%x)\n", gControllerInfo[i].MappedVector,
|
||||
DPRINT("floppy: Connecting interrupt %d to controller%d (object 0x%p)\n", gControllerInfo[i].MappedVector,
|
||||
i, &gControllerInfo[i]);
|
||||
|
||||
/* NOTE: We cannot share our interrupt, even on level-triggered buses. See Isr() for details. */
|
||||
|
@ -916,8 +916,10 @@ static BOOLEAN NTAPI AddControllers(PDRIVER_OBJECT DriverObject)
|
|||
* 14: 3,2
|
||||
* 15: 3,3
|
||||
*/
|
||||
|
||||
DriveNumber = (UCHAR)(i*4 + j); /* loss of precision is OK; there are only 16 of 'em */
|
||||
|
||||
RtlZeroMemory(&DeviceNameBuf, MAX_DEVICE_NAME * sizeof(WCHAR));
|
||||
swprintf(DeviceNameBuf, L"\\Device\\Floppy%d", DriveNumber);
|
||||
RtlInitUnicodeString(&DeviceName, DeviceNameBuf);
|
||||
|
||||
|
@ -930,7 +932,7 @@ static BOOLEAN NTAPI AddControllers(PDRIVER_OBJECT DriverObject)
|
|||
continue; /* continue on to next drive */
|
||||
}
|
||||
|
||||
DPRINT("floppy: AddControllers: New device: %S (0x%x)\n", DeviceNameBuf, gControllerInfo[i].DriveInfo[j].DeviceObject);
|
||||
DPRINT("floppy: AddControllers: New device: %S (0x%p)\n", DeviceNameBuf, gControllerInfo[i].DriveInfo[j].DeviceObject);
|
||||
|
||||
/* 3b.5: Create an ARC path in case we're booting from this drive */
|
||||
swprintf(gControllerInfo[i].DriveInfo[j].ArcPathBuffer,
|
||||
|
|
|
@ -1057,7 +1057,7 @@ NTSTATUS NTAPI HwPowerOff(PCONTROLLER_INFO ControllerInfo)
|
|||
* - Wake up with a hardware reset
|
||||
*/
|
||||
{
|
||||
DPRINT("floppy: HwPowerOff called on controller 0x%x\n", ControllerInfo);
|
||||
DPRINT("floppy: HwPowerOff called on controller 0x%p\n", ControllerInfo);
|
||||
|
||||
WRITE_PORT_UCHAR(ControllerInfo->BaseAddress + DATA_RATE_SELECT_REGISTER, DRSR_POWER_DOWN);
|
||||
|
||||
|
|
|
@ -291,7 +291,7 @@ static NTSTATUS NTAPI RWSeekToCylinder(PDRIVE_INFO DriveInfo,
|
|||
|
||||
PAGED_CODE();
|
||||
|
||||
DPRINT("floppy: RWSeekToCylinder called drive 0x%x cylinder %d\n", DriveInfo, Cylinder);
|
||||
DPRINT("floppy: RWSeekToCylinder called drive 0x%p cylinder %d\n", DriveInfo, Cylinder);
|
||||
|
||||
/* Clear any spurious interrupts */
|
||||
KeClearEvent(&DriveInfo->ControllerInfo->SynchEvent);
|
||||
|
|
Loading…
Reference in a new issue