Author: akhaldi
Date: Mon Feb 3 10:46:48 2014
New Revision: 61948
URL:
http://svn.reactos.org/svn/reactos?rev=61948&view=rev
Log:
[FLOPPY]
* Do not include debug.h into the main header.
* Remove one time inclusions from the main header and put them back where they belong.
* Improve header inclusions.
CORE-7716
Modified:
trunk/reactos/drivers/storage/floppy/csqrtns.c
trunk/reactos/drivers/storage/floppy/csqrtns.h
trunk/reactos/drivers/storage/floppy/floppy.c
trunk/reactos/drivers/storage/floppy/floppy.h
trunk/reactos/drivers/storage/floppy/hardware.c
trunk/reactos/drivers/storage/floppy/hardware.h
trunk/reactos/drivers/storage/floppy/ioctl.c
trunk/reactos/drivers/storage/floppy/ioctl.h
trunk/reactos/drivers/storage/floppy/precomp.h
trunk/reactos/drivers/storage/floppy/readwrite.c
trunk/reactos/drivers/storage/floppy/readwrite.h
Modified: trunk/reactos/drivers/storage/floppy/csqrtns.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/csq…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/csqrtns.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/csqrtns.c [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -39,6 +39,8 @@
*/
#include "precomp.h"
+
+#include <debug.h>
/* Global CSQ struct that the CSQ functions initialize and use */
IO_CSQ Csq;
@@ -171,4 +173,3 @@
InsertTailList(&IrpQueue, &Irp->Tail.Overlay.ListEntry);
KeReleaseSemaphore(&QueueSemaphore, 0, 1, FALSE);
}
-
Modified: trunk/reactos/drivers/storage/floppy/csqrtns.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/csq…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/csqrtns.h [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/csqrtns.h [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -23,6 +23,8 @@
* REVISIONS:
* 15-Feb-2004 vizzini - Created
*/
+
+#pragma once
#include <csq.h>
@@ -51,4 +53,3 @@
VOID NTAPI
CsqCompleteCanceledIrp(PIO_CSQ Csq, PIRP Irp);
-
Modified: trunk/reactos/drivers/storage/floppy/floppy.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/flo…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/floppy.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/floppy.c [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -42,6 +42,12 @@
#include "precomp.h"
+#include <ntddk.h>
+#include <debug.h>
+
+#include "ioctl.h"
+#include "readwrite.h"
+
/*
* Global controller info structures. Each controller gets one. Since the system
* will probably have only one, with four being a very unlikely maximum, a static
@@ -1192,4 +1198,3 @@
return STATUS_SUCCESS;
}
-
Modified: trunk/reactos/drivers/storage/floppy/floppy.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/flo…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/floppy.h [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/floppy.h [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -23,6 +23,8 @@
* REVISIONS:
* 15-Feb-2004 vizzini - Created
*/
+
+#pragma once
#define MAX_DEVICE_NAME 255
#define MAX_ARC_PATH_LEN 255
@@ -123,4 +125,3 @@
#define GEOMETRY_144_TRACKSPERCYLINDER 2
#define GEOMETRY_144_SECTORSPERTRACK 18
#define GEOMETRY_144_BYTESPERSECTOR 512
-
Modified: trunk/reactos/drivers/storage/floppy/hardware.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/har…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/hardware.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/hardware.c [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -49,10 +49,11 @@
#include "precomp.h"
+#include <debug.h>
+
/*
* Hardware Support Routines
*/
-
static BOOLEAN NTAPI
ReadyForWrite(PCONTROLLER_INFO ControllerInfo)
@@ -1041,4 +1042,3 @@
INFO_(FLOPPY, "MAIN_STATUS_REGISTER =0x%x\n",
READ_PORT_UCHAR(ControllerInfo->BaseAddress + MAIN_STATUS_REGISTER));
INFO_(FLOPPY, "DIGITAL_INPUT_REGISTER = 0x%x\n",
READ_PORT_UCHAR(ControllerInfo->BaseAddress + DIGITAL_INPUT_REGISTER));
}
-
Modified: trunk/reactos/drivers/storage/floppy/hardware.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/har…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/hardware.h [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/hardware.h [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -33,6 +33,8 @@
* - Convert these numbers to 100% absolute values; eliminate bit positions
* in favor of shifts or bitfields
*/
+
+#pragma once
#define FLOPPY_DEFAULT_IRQ 0x6
#define FDC_PORT_BYTES 0x8
@@ -350,4 +352,3 @@
NTSTATUS NTAPI
HwTurnOffMotor(PCONTROLLER_INFO ControllerInfo);
-
Modified: trunk/reactos/drivers/storage/floppy/ioctl.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/ioc…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/ioctl.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/ioctl.c [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -33,6 +33,7 @@
#include "precomp.h"
+#include <debug.h>
NTSTATUS NTAPI
DeviceIoctl(PDEVICE_OBJECT DeviceObject, PIRP Irp)
@@ -267,4 +268,3 @@
StopMotor(DriveInfo->ControllerInfo);
return;
}
-
Modified: trunk/reactos/drivers/storage/floppy/ioctl.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/ioc…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/ioctl.h [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/ioctl.h [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -24,6 +24,8 @@
* 15-Feb-2004 vizzini - Created
*/
+#pragma once
+
DRIVER_DISPATCH DeviceIoctl;
NTSTATUS NTAPI
@@ -31,4 +33,3 @@
VOID NTAPI
DeviceIoctlPassive(PDRIVE_INFO DriveInfo, PIRP Irp);
-
Modified: trunk/reactos/drivers/storage/floppy/precomp.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/pre…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/precomp.h [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/precomp.h [iso-8859-1] Mon Feb 3 10:46:48 2014
@@ -1,9 +1,5 @@
-#include <ntddk.h>
-#include <debug.h>
+#include <wdm.h>
#include "floppy.h"
#include "csqrtns.h"
#include "hardware.h"
-#include "csqrtns.h"
-#include "ioctl.h"
-#include "readwrite.h"
Modified: trunk/reactos/drivers/storage/floppy/readwrite.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/rea…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/readwrite.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/readwrite.c [iso-8859-1] Mon Feb 3 10:46:48
2014
@@ -54,6 +54,7 @@
#include "precomp.h"
+#include <debug.h>
static IO_ALLOCATION_ACTION NTAPI
MapRegisterCallback(PDEVICE_OBJECT DeviceObject,
@@ -759,4 +760,3 @@
IoCompleteRequest(Irp, IO_DISK_INCREMENT);
StopMotor(DriveInfo->ControllerInfo);
}
-
Modified: trunk/reactos/drivers/storage/floppy/readwrite.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/rea…
==============================================================================
--- trunk/reactos/drivers/storage/floppy/readwrite.h [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/floppy/readwrite.h [iso-8859-1] Mon Feb 3 10:46:48
2014
@@ -24,6 +24,8 @@
* 15-Feb-2004 vizzini - Created
*/
+#pragma once
+
DRIVER_DISPATCH ReadWrite;
NTSTATUS NTAPI
@@ -31,4 +33,3 @@
VOID NTAPI
ReadWritePassive(PDRIVE_INFO DriveInfo, PIRP Irp);
-