OSDN Git Service

* include/ddk/hidusage.h: Remove unneccessary #pragma pack's.
authordannysmith <dannysmith>
Thu, 19 Dec 2002 01:34:25 +0000 (01:34 +0000)
committerdannysmith <dannysmith>
Thu, 19 Dec 2002 01:34:25 +0000 (01:34 +0000)
* include/ddk/miniport.h (EMULATOR_PORT_ACCESS_TYPE): Define
before using.
(VIDEO_ACCESS_RANGE): Guard against prior definition.
* include/ddk/minitape.h (INQUIRYDATA): Guard against prior
definition.
* include/ddk/ndis.h (DECLARE_UNKNOWN_PROTOTYPE): Correct macro.
* include/ddk/ndisguid.h: Remove unneccessary #pragma pack's.
* include/ddk/scsi.h (INQUIRYDATA): Guard against prior
definition.
* include/ddk/scsiwmi.h (GUID): Define if not already done.
(LPCGUID): Likewise.
* include/ddk/tdi.h: Close "Listen flags" comment.
* include/ddk/tdistat.h: Remove unneccessary #pragma pack's.
* include/ddk/video.h: Add #pragma pack(push,4) to balance.
(VIDEO_ACCESS_RANGE): Guard against prior definition.
* include/ddk/videoagp.h:Add #pragma pack(push,4) to balance.
* include/ddk/win2k.h: Likewise.
* include/ddk/winddi.h: Likewise.
* include/ddk/winddk.h: Likewise.
* include/ddk/winnt4.h: Likewise.
* include/ddk/ws2san.h: Likewise.
* include/ddk/xfilter.h: Remove unbalanced #pragma pack(pop).
* include/ddk/video.h: Don't process rest of file ifdef
__WINDDI_H.
* include/ddk/winddi.h: Don't process rest of file ifdef
__VIDEO_H.
* include/ddk/usb.h: Don't process rest of file ifdef
__USBDI_H.
* include/ddk/usbdi.h: Don't process rest of file ifdef
__USB_H.
* include/ddk/usbcamdi.h: Don't process rest of file if
!defined(__USB_H) && !defined(__USBDI_H)

21 files changed:
winsup/w32api/ChangeLog
winsup/w32api/include/ddk/hidusage.h
winsup/w32api/include/ddk/miniport.h
winsup/w32api/include/ddk/minitape.h
winsup/w32api/include/ddk/ndis.h
winsup/w32api/include/ddk/ndisguid.h
winsup/w32api/include/ddk/scsi.h
winsup/w32api/include/ddk/scsiwmi.h
winsup/w32api/include/ddk/tdi.h
winsup/w32api/include/ddk/tdistat.h
winsup/w32api/include/ddk/usb.h
winsup/w32api/include/ddk/usbcamdi.h
winsup/w32api/include/ddk/usbdi.h
winsup/w32api/include/ddk/video.h
winsup/w32api/include/ddk/videoagp.h
winsup/w32api/include/ddk/win2k.h
winsup/w32api/include/ddk/winddi.h
winsup/w32api/include/ddk/winddk.h
winsup/w32api/include/ddk/winnt4.h
winsup/w32api/include/ddk/ws2san.h
winsup/w32api/include/ddk/xfilter.h

index fc237ca..edbea77 100644 (file)
@@ -1,3 +1,39 @@
+2002-12-19  Danny Smith  <dannysmith@users.sourceforge.net>
+
+       * include/ddk/hidusage.h: Remove unneccessary #pragma pack's.
+       * include/ddk/miniport.h (EMULATOR_PORT_ACCESS_TYPE): Define
+       before using.
+       (VIDEO_ACCESS_RANGE): Guard against prior definition.
+       * include/ddk/minitape.h (INQUIRYDATA): Guard against prior
+       definition.
+       * include/ddk/ndis.h (DECLARE_UNKNOWN_PROTOTYPE): Correct macro.
+       * include/ddk/ndisguid.h: Remove unneccessary #pragma pack's.
+       * include/ddk/scsi.h (INQUIRYDATA): Guard against prior
+       definition.
+       * include/ddk/scsiwmi.h (GUID): Define if not already done.
+       (LPCGUID): Likewise.
+       * include/ddk/tdi.h: Close "Listen flags" comment.
+       * include/ddk/tdistat.h: Remove unneccessary #pragma pack's.
+       * include/ddk/video.h:  Add #pragma pack(push,4) to balance.
+       (VIDEO_ACCESS_RANGE): Guard against prior definition.
+       * include/ddk/videoagp.h:Add #pragma pack(push,4) to balance.
+       * include/ddk/win2k.h: Likewise.
+       * include/ddk/winddi.h: Likewise.
+       * include/ddk/winddk.h: Likewise.
+       * include/ddk/winnt4.h: Likewise.
+       * include/ddk/ws2san.h: Likewise.
+       * include/ddk/xfilter.h: Remove unbalanced #pragma pack(pop).
+       * include/ddk/video.h: Don't process rest of file ifdef
+       __WINDDI_H.
+       * include/ddk/winddi.h: Don't process rest of file ifdef
+       __VIDEO_H.
+       * include/ddk/usb.h: Don't process rest of file ifdef
+       __USBDI_H.
+       * include/ddk/usbdi.h: Don't process rest of file ifdef
+       __USB_H.
+       * include/ddk/usbcamdi.h: Don't process rest of file if
+       !defined(__USB_H) && !defined(__USBDI_H)
+
 2002-12-18  James E. Lucas  <xelloss@users.sourceforge.net>
 
        * include/winnetwk.h (WNetResourceInformation[AW]): Correct
index a379e18..1f82af9 100644 (file)
@@ -31,8 +31,6 @@
 extern "C" {
 #endif
 
-#pragma pack(push,4)
-
 typedef USHORT USAGE, *PUSAGE;
 
 #define HID_USAGE_GENERIC_POINTER             ((USAGE) 0x01)
@@ -205,8 +203,6 @@ typedef USHORT USAGE, *PUSAGE;
 #define HID_USAGE_SIMULATION_RUDDER       ((USAGE) 0xBA)
 #define HID_USAGE_SIMULATION_THROTTLE     ((USAGE) 0xBB)
 
-#pragma pack(pop)
-
 #ifdef __cplusplus
 }
 #endif
index e2f1880..01bbd23 100644 (file)
@@ -39,6 +39,13 @@ extern "C" {
 #define EMULATOR_READ_ACCESS              0x01
 #define EMULATOR_WRITE_ACCESS             0x02
 
+typedef enum _EMULATOR_PORT_ACCESS_TYPE {
+       Uchar,
+       Ushort,
+       Ulong
+} EMULATOR_PORT_ACCESS_TYPE, *PEMULATOR_PORT_ACCESS_TYPE;
+
+
 typedef struct _EMULATOR_ACCESS_ENTRY {
   ULONG  BasePort;
   ULONG  NumConsecutivePorts;
@@ -48,12 +55,8 @@ typedef struct _EMULATOR_ACCESS_ENTRY {
   PVOID  Routine;
 } EMULATOR_ACCESS_ENTRY, *PEMULATOR_ACCESS_ENTRY;
 
-typedef enum _EMULATOR_PORT_ACCESS_TYPE {
-       Uchar,
-       Ushort,
-       Ulong
-} EMULATOR_PORT_ACCESS_TYPE, *PEMULATOR_PORT_ACCESS_TYPE;
-
+#ifndef VIDEO_ACCESS_RANGE_DEFINED /* also in video.h */
+#define VIDEO_ACCESS_RANGE_DEFINED
 typedef struct _VIDEO_ACCESS_RANGE {
   PHYSICAL_ADDRESS  RangeStart;
   ULONG  RangeLength;
@@ -62,6 +65,7 @@ typedef struct _VIDEO_ACCESS_RANGE {
   UCHAR  RangeShareable;
   UCHAR  RangePassive;
 } VIDEO_ACCESS_RANGE, *PVIDEO_ACCESS_RANGE;
+#endif
 
 typedef VOID DDKAPI
 (*PBANKED_SECTION_ROUTINE)(
index 55aff01..7540dea 100644 (file)
@@ -76,7 +76,8 @@ typedef enum _TAPE_STATUS {
 } TAPE_STATUS, *PTAPE_STATUS;
 
 #define INQUIRYDATABUFFERSIZE 36
-
+#ifndef _INQUIRYDATA_DEFINED /* also in scsi.h */
+#define _INQUIRYDATA_DEFINED
 typedef struct _INQUIRYDATA {
        UCHAR  DeviceType : 5;
        UCHAR  DeviceTypeQualifier : 3;
@@ -119,6 +120,7 @@ typedef struct _INQUIRYDATA {
        UCHAR  VendorSpecific[20];
        UCHAR  Reserved3[40];
 } INQUIRYDATA, *PINQUIRYDATA;
+#endif
 
 typedef struct _MODE_CAPABILITIES_PAGE {
        UCHAR PageCode : 6;
index 5a10a92..9e02dab 100644 (file)
@@ -3989,7 +3989,7 @@ typedef struct _NDIS_BIND_PATHS {
   typedef struct _##BaseName BaseName, *P##BaseName;
 
 #define DECLARE_UNKNOWN_PROTOTYPE(Name) \
-  typedef VOID (*##Name)(VOID);
+  typedef VOID (*(Name))(VOID);
 
 #define ETH_LENGTH_OF_ADDRESS 6
 
index 18a1fbc..27b8777 100644 (file)
@@ -31,8 +31,6 @@
 extern "C" {
 #endif
 
-#pragma pack(push,4)
-
 DEFINE_GUID(GUID_NDIS_LAN_CLASS,
   0xad498944, 0x762f, 0x11d0, 0x8d, 0xcb, 0x00, 0xc0, 0x4f, 0xc3, 0x35, 0x8c);
 
@@ -434,8 +432,6 @@ DEFINE_GUID(GUID_NDIS_STATUS_RESET_END,
 DEFINE_GUID(GUID_NDIS_STATUS_RESET_START,
   0x981f2d76, 0xb1f3, 0x11d0, 0x8d, 0xd7, 0x00, 0xc0, 0x4f, 0xc3, 0x35, 0x8c);
 
-#pragma pack(pop)
-
 #ifdef __cplusplus
 }
 #endif
index dccb610..e1af711 100644 (file)
@@ -892,6 +892,9 @@ typedef union _CDB {
     UCHAR  AsByte[16];
 } CDB, *PCDB;
 
+#ifndef _INQUIRYDATA_DEFINED /* also in minitape.h */
+#define _INQUIRYDATA_DEFINED
+
 #define INQUIRYDATABUFFERSIZE             36
 
 typedef struct _INQUIRYDATA {
@@ -936,6 +939,7 @@ typedef struct _INQUIRYDATA {
   UCHAR  VendorSpecific[20];
   UCHAR  Reserved3[40];
 } INQUIRYDATA, *PINQUIRYDATA;
+#endif
 
 /* INQUIRYDATA.DeviceType constants */
 #define DIRECT_ACCESS_DEVICE              0x00
index 53aaad0..9f3aebc 100644 (file)
@@ -46,6 +46,21 @@ typedef struct _SCSIWMI_REQUEST_CONTEXT {
   ULONG  ReturnSize;
 } SCSIWMI_REQUEST_CONTEXT, *PSCSIWMI_REQUEST_CONTEXT;
 
+#ifndef _GUID_DEFINED
+#define _GUID_DEFINED
+typedef struct _GUID {
+    unsigned long  Data1;
+    unsigned short Data2;
+    unsigned short Data3;
+    unsigned char  Data4[ 8 ];
+} GUID;
+#endif
+
+#ifndef _LPCGUID_DEFINED
+#define _LPCGUID_DEFINED
+typedef const GUID *LPCGUID;
+#endif
+
 typedef struct _SCSIWMIGUIDREGINFO {
   LPCGUID  Guid;
   ULONG  InstanceCount;
index 0bfe3dd..46d01a2 100644 (file)
@@ -311,7 +311,7 @@ typedef struct _TDI_REQUEST_SET_EVENT {
 #define TDI_RECEIVE_AT_DISPATCH_LEVEL     0x00000800
 #define TDI_RECEIVE_CONTROL_INFO          0x00001000
 
-/* Listen flags *
+/* Listen flags */
 #define TDI_QUERY_ACCEPT                  0x00000001
 
 /* Options used for both SendOptions and ReceiveIndicators */
index d459393..f0588d2 100644 (file)
@@ -31,8 +31,6 @@
 extern "C" {
 #endif
 
-#pragma pack(push,4)
-
 #define TDI_SUCCESS                       STATUS_SUCCESS
 #define TDI_NO_RESOURCES                  STATUS_INSUFFICIENT_RESOURCES
 #define TDI_ADDR_IN_USE                   STATUS_ADDRESS_ALREADY_EXISTS
@@ -78,8 +76,6 @@ extern "C" {
 #define        TDI_ADDRESS_OPTION_REUSE          1
 #define        TDI_ADDRESS_OPTION_DHCP           2
 
-#pragma pack(pop)
-
 #ifdef __cplusplus
 }
 #endif
index c1705d4..7e0145c 100644 (file)
 #pragma GCC system_header
 #endif
 
+#ifdef __USBDI_H
+#error usbdi.h cannot be included with usb.h
+#else
+
 #ifdef __cplusplus
 extern "C" {
 #endif
 
 #pragma pack(push,4)
 
-#ifdef __USBDI_H
-#error usbdi.h cannot be included with usb.h
-#endif
-
 #include "ntddk.h"
 #include "usb100.h"
 
@@ -470,4 +470,6 @@ typedef struct _OS_STRING {
 }
 #endif
 
+#endif /* defined __USBDI_H */
 #endif /* __USB_H */
index 67fa56c..8547522 100644 (file)
 #pragma GCC system_header
 #endif
 
+#if !defined(__USB_H) && !defined(__USBDI_H)
+#error include usb.h or usbdi.h before usbcamdi.h
+#else
+
 #ifdef __cplusplus
 extern "C" {
 #endif
 
 #pragma pack(push,4)
 
-#if !defined(__USB_H) && !defined(__USBDI_H)
-#error include usb.h or usbdi.h before usbcamdi.h
-#endif
-
 #include "ntddk.h"
 
 #if defined(_BATTERYCLASS_)
@@ -398,4 +398,7 @@ USBCAMD_Debug_LogEntry(
 }
 #endif
 
+#endif /* !defined(__USB_H) && !defined(__USBDI_H) */
+
+
 #endif /* __USBCAMDI_H */
index ffe0844..7caca07 100644 (file)
 #pragma GCC system_header
 #endif
 
+#ifdef __USB_H
+#error usb.h cannot be included with usbdi.h
+#else
+
 #ifdef __cplusplus
 extern "C" {
 #endif
 
 #pragma pack(push,4)
 
-#ifdef __USB_H
-#error usb.h cannot be included with usbdi.h
-#endif
-
 #include "ntddk.h"
 #include "usbioctl.h"
 
@@ -407,4 +407,6 @@ typedef struct _URB {
 }
 #endif
 
+#endif /* defined __USB_H */
+
 #endif /* __USBDI_H */
index 8367eb8..a614acd 100644 (file)
 #ifndef __VIDEO_H
 #define __VIDEO_H
 
-#ifdef __WINDDI_H
-#error winddi.h cannot be included with video.h
-#endif
 
 #if __GNUC__ >=3
 #pragma GCC system_header
 #endif
 
+#ifdef __WINDDI_H
+#error winddi.h cannot be included with video.h
+#else
+
 #ifdef __cplusplus
 extern "C" {
 #endif
 
+#pragma pack(push,4)
+
 #include "ntddk.h"
 
 #if defined(_VIDEOPORT_)
@@ -247,6 +250,8 @@ typedef BOOLEAN DDKAPI
 #define VIDEO_RANGE_PASSIVE_DECODE        1
 #define VIDEO_RANGE_10_BIT_DECODE         2
 
+#ifndef VIDEO_ACCESS_RANGE_DEFINED /* also in miniport.h */
+#define VIDEO_ACCESS_RANGE_DEFINED
 typedef struct _VIDEO_ACCESS_RANGE {
   PHYSICAL_ADDRESS  RangeStart;
   ULONG  RangeLength;
@@ -255,6 +260,7 @@ typedef struct _VIDEO_ACCESS_RANGE {
   UCHAR  RangeShareable;
   UCHAR  RangePassive;
 } VIDEO_ACCESS_RANGE, *PVIDEO_ACCESS_RANGE;
+#endif
 
 typedef VOID DDKAPI
 (*PVIDEO_HW_LEGACYRESOURCES)(
@@ -1559,4 +1565,6 @@ VideoPortZeroMemory(
 }
 #endif
 
+#endif /* defined __WINDDI_H */
+
 #endif /* __VIDEO_H */
index 518b985..89886f8 100644 (file)
@@ -31,6 +31,8 @@
 extern "C" {
 #endif
 
+#pragma pack(push,4)
+
 #include "ntddk.h"
 #include "video.h"
 
index 2b9befb..deba29b 100644 (file)
@@ -33,6 +33,7 @@ extern "C" {
 
 #include "ntddk.h"
 
+#pragma pack(push,4)
 
 typedef enum _BUS_DATA_TYPE {
   ConfigurationSpaceUndefined = -1,
index ad94f77..5659e6f 100644 (file)
 #ifndef __WINDDI_H
 #define __WINDDI_H
 
-#ifdef __VIDEO_H
-#error video.h cannot be included with winddi.h
-#endif
-
 #if __GNUC__ >=3
 #pragma GCC system_header
 #endif
 
+#ifdef __VIDEO_H
+#error video.h cannot be included with winddi.h
+#else
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -4141,4 +4141,6 @@ DrvGetDirectDrawInfo(
 }
 #endif
 
+#endif /* defined __VIDEO_H */
+
 #endif /* __WINDDI_H */
index 7b2168e..be82bbe 100644 (file)
@@ -31,6 +31,8 @@
 extern "C" {
 #endif
 
+#pragma pack(push,4)
+
 /*
 ** Definitions specific to this Device Driver Kit
 */
index 1c7859e..bbe8daf 100644 (file)
@@ -31,6 +31,8 @@
 extern "C" {
 #endif
 
+#pragma pack(push,4)
+
 typedef struct _ZONE_SEGMENT_HEADER {
   SINGLE_LIST_ENTRY  SegmentList;
   PVOID  Reserved;
index 6176233..29a2118 100644 (file)
@@ -31,6 +31,8 @@
 extern "C" {
 #endif
 
+#pragma pack(push,4)
+
 #include <winsock2.h>
 #include "ntddk.h"
 
index c8bafae..3940b44 100644 (file)
@@ -232,8 +232,6 @@ typedef ULONG TR_GROUP_ADDRESS;
        } \
 }
 
-#pragma pack(pop)
-
 #ifdef __cplusplus
 }
 #endif