Author: hpoussin
Date: Wed Oct 31 12:45:15 2007
New Revision: 30005
URL:
http://svn.reactos.org/svn/reactos?rev=30005&view=rev
Log:
Clean some header mess
Modified:
trunk/reactos/drivers/video/displays/vga/main/enable.c
trunk/reactos/drivers/video/displays/vga/objects/bitblt.c
trunk/reactos/drivers/video/displays/vga/objects/copybits.c
trunk/reactos/drivers/video/displays/vga/objects/lineto.c
trunk/reactos/drivers/video/displays/vga/objects/offscreen.c
trunk/reactos/drivers/video/displays/vga/objects/paint.c
trunk/reactos/drivers/video/displays/vga/objects/pointer.c
trunk/reactos/drivers/video/displays/vga/objects/screen.c
trunk/reactos/drivers/video/displays/vga/objects/transblt.c
trunk/reactos/drivers/video/displays/vga/vgaddi.h
trunk/reactos/drivers/video/displays/vga/vgavideo/vgavideo.c
Modified: trunk/reactos/drivers/video/displays/vga/main/enable.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/main/enable.c (original)
+++ trunk/reactos/drivers/video/displays/vga/main/enable.c Wed Oct 31 12:45:15 2007
@@ -6,12 +6,7 @@
* PROGRAMMERS:
*/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
-#define NDEBUG
-#include <debug.h>
-
-#define DBG_PREFIX "VGADDI: "
+#include <vgaddi.h>
static BOOL VGAInitialized = FALSE;
@@ -183,7 +178,7 @@
IN ULONG SizeOfDED,
OUT PDRVENABLEDATA DriveEnableData)
{
- /* EngDebugPrint("VGADDI", "DrvEnableDriver called...\n", 0); */
+ DPRINT("DrvEnableDriver called...\n");
vgaPreCalc();
@@ -251,7 +246,7 @@
PDev = EngAllocMem(FL_ZERO_MEMORY, sizeof(PDEV), ALLOC_TAG);
if (PDev == NULL)
{
- EngDebugPrint(DBG_PREFIX, "EngAllocMem failed for PDEV\n", 0);
+ DPRINT1("EngAllocMem failed for PDEV\n");
return NULL;
}
PDev->KMDriver = Driver;
@@ -579,4 +574,13 @@
return OutputSize;
}
+ULONG DbgPrint(PCCH Format,...)
+{
+ va_list ap;
+ va_start(ap, Format);
+ EngDebugPrint("VGADDI", (PCHAR)Format, ap);
+ va_end(ap);
+ return 0;
+}
+
/* EOF */
Modified: trunk/reactos/drivers/video/displays/vga/objects/bitblt.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/objects/bitblt.c (original)
+++ trunk/reactos/drivers/video/displays/vga/objects/bitblt.c Wed Oct 31 12:45:15 2007
@@ -6,13 +6,7 @@
* PROGRAMMERS:
*/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
-#include "brush.h"
-#include "bitblt.h"
-
-#define NDEBUG
-#include <debug.h>
+#include <vgaddi.h>
typedef BOOL (*PFN_VGABlt)(SURFOBJ*, SURFOBJ*, XLATEOBJ*, RECTL*, POINTL*);
typedef BOOL (APIENTRY *PBLTRECTFUNC)(SURFOBJ* OutputObj,
Modified: trunk/reactos/drivers/video/displays/vga/objects/copybits.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/objects/copybits.c (original)
+++ trunk/reactos/drivers/video/displays/vga/objects/copybits.c Wed Oct 31 12:45:15 2007
@@ -6,9 +6,7 @@
* PROGRAMMERS:
*/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
-#include <debug.h>
+#include <vgaddi.h>
BOOL APIENTRY
DrvCopyBits(
Modified: trunk/reactos/drivers/video/displays/vga/objects/lineto.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/objects/lineto.c (original)
+++ trunk/reactos/drivers/video/displays/vga/objects/lineto.c Wed Oct 31 12:45:15 2007
@@ -6,8 +6,7 @@
* PROGRAMMERS: Copyright (C) 1998-2003 ReactOS Team
*/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
+#include <vgaddi.h>
/*
* Draw a line from top-left to bottom-right
Modified: trunk/reactos/drivers/video/displays/vga/objects/offscreen.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/objects/offscreen.c (original)
+++ trunk/reactos/drivers/video/displays/vga/objects/offscreen.c Wed Oct 31 12:45:15 2007
@@ -8,9 +8,7 @@
/* INCLUDES ******************************************************************/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
-#include <debug.h>
+#include <vgaddi.h>
/* GLOBALS *******************************************************************/
Modified: trunk/reactos/drivers/video/displays/vga/objects/paint.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/objects/paint.c (original)
+++ trunk/reactos/drivers/video/displays/vga/objects/paint.c Wed Oct 31 12:45:15 2007
@@ -6,11 +6,7 @@
* PROGRAMMERS:
*/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
-#include "brush.h"
-
-#include <debug.h>
+#include <vgaddi.h>
BOOL VGADDIFillSolid(SURFOBJ *Surface, RECTL Dimensions, ULONG iColor)
{
Modified: trunk/reactos/drivers/video/displays/vga/objects/pointer.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/objects/pointer.c (original)
+++ trunk/reactos/drivers/video/displays/vga/objects/pointer.c Wed Oct 31 12:45:15 2007
@@ -8,11 +8,7 @@
/* INCLUDES ******************************************************************/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
-
-#define NDEBUG
-#include <debug.h>
+#include <vgaddi.h>
/* GLOBALS *******************************************************************/
Modified: trunk/reactos/drivers/video/displays/vga/objects/screen.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/objects/screen.c (original)
+++ trunk/reactos/drivers/video/displays/vga/objects/screen.c Wed Oct 31 12:45:15 2007
@@ -6,8 +6,7 @@
* PROGRAMMERS:
*/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
+#include <vgaddi.h>
static WORD PaletteBuffer[] = {
16, 0, // 16 entries, start with 0
@@ -125,8 +124,8 @@
0,
&ReturnedDataLength))
{
- //DPRINT1("Failed to unmap video memory.\n");
- DbgBreakPoint();
+ DPRINT1("Failed to unmap video memory.\n");
+ EngDebugBreak();
return FALSE;
}
return TRUE;
Modified: trunk/reactos/drivers/video/displays/vga/objects/transblt.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/objects/transblt.c (original)
+++ trunk/reactos/drivers/video/displays/vga/objects/transblt.c Wed Oct 31 12:45:15 2007
@@ -6,13 +6,7 @@
* PROGRAMMERS:
*/
-#include "../vgaddi.h"
-#include "../vgavideo/vgavideo.h"
-#include "brush.h"
-#include "bitblt.h"
-
-#define NDEBUG
-#include <debug.h>
+#include <vgaddi.h>
BOOL APIENTRY
DrvTransparentBlt(
Modified: trunk/reactos/drivers/video/displays/vga/vgaddi.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/vgaddi.h (original)
+++ trunk/reactos/drivers/video/displays/vga/vgaddi.h Wed Oct 31 12:45:15 2007
@@ -11,6 +11,17 @@
#include <winioctl.h>
#include <ntddvdeo.h>
+#include "vgavideo/vgavideo.h"
+#include "objects/brush.h"
+#include "objects/bitblt.h"
+
+#ifndef NDEBUG
+#define DPRINT DbgPrint
+#else
+#define DPRINT
+#endif
+#define DPRINT1 DbgPrint
+
/* FIXME - what a headers mess.... */
#define DDKAPI __stdcall
@@ -19,10 +30,10 @@
#define DDKCDECLAPI __cdecl
ULONG DbgPrint(PCCH Format,...);
-VOID DDKAPI DbgBreakPoint(VOID);
-VOID DDKAPI WRITE_PORT_UCHAR(IN PUCHAR Port, IN UCHAR Value);
-VOID DDKAPI WRITE_REGISTER_UCHAR(IN PUCHAR Register, IN UCHAR Value);
-UCHAR DDKAPI READ_REGISTER_UCHAR(IN PUCHAR Register);
+VOID DDKAPI WRITE_PORT_UCHAR(IN PUCHAR Port, IN UCHAR Value);
+VOID DDKAPI WRITE_PORT_USHORT(IN PUSHORT Port, IN USHORT Value);
+VOID DDKAPI WRITE_REGISTER_UCHAR(IN PUCHAR Register, IN UCHAR Value);
+UCHAR DDKAPI READ_REGISTER_UCHAR(IN PUCHAR Register);
static __inline BOOLEAN
RemoveEntryList(
Modified: trunk/reactos/drivers/video/displays/vga/vgavideo/vgavideo.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/displays/vga…
==============================================================================
--- trunk/reactos/drivers/video/displays/vga/vgavideo/vgavideo.c (original)
+++ trunk/reactos/drivers/video/displays/vga/vgavideo/vgavideo.c Wed Oct 31 12:45:15 2007
@@ -6,25 +6,7 @@
* PROGRAMMERS:
*/
-#define _WINBASE_
-#define _WINDOWS_H
-#include <stdarg.h>
-#include <windef.h>
-#include <guiddef.h>
-#include <wingdi.h>
-#include <winddi.h>
-#include <winioctl.h>
-#include <ntddvdeo.h>
-#include <stdlib.h>
-#include "vgavideo.h"
-
-#define DDKAPI __stdcall
-#define DDKFASTAPI __fastcall
-#define FASTCALL __fastcall
-#define DDKCDECLAPI __cdecl
-
-VOID DDKAPI WRITE_PORT_UCHAR(IN PUCHAR Port, IN UCHAR Value);
-VOID DDKAPI WRITE_PORT_USHORT(IN PUSHORT Port, IN USHORT Value);
+#include <vgaddi.h>
UCHAR PreCalcReverseByte[256];
int maskbit[640];
@@ -40,9 +22,6 @@
static int byteCounter;
static unsigned char rightMask;
-#define READ_REGISTER_UCHAR(p) (*((volatile UCHAR *)(p)))
-#define WRITE_REGISTER_UCHAR(p,c) (*((volatile CHAR *)(p))) = (c)
-
UCHAR bytesPerPixel(ULONG Format)
{
/* This function is taken from /subsys/win32k/eng/surface.c
@@ -460,7 +439,7 @@
c1 = (vgaGetPixel(x + i, y + j) << 4) | (vgaGetPixel(x + i + 1, y +
j));
c2 = ((PUCHAR)b)[(j * Dest_lDelta) + (i >> 1)];
if ((c1 & mask) != (c2 & mask))
- DbgBreakPoint();
+ EngDebugBreak();
}
}
#endif /* VGA_VERIFY */