* 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)
This commit is contained in:
Danny Smith 2002-12-19 01:34:26 +00:00
parent 9774594921
commit 037c11e868
21 changed files with 115 additions and 42 deletions

View 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> 2002-12-18 James E. Lucas <xelloss@users.sourceforge.net>
* include/winnetwk.h (WNetResourceInformation[AW]): Correct * include/winnetwk.h (WNetResourceInformation[AW]): Correct

View File

@ -31,8 +31,6 @@
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4)
typedef USHORT USAGE, *PUSAGE; typedef USHORT USAGE, *PUSAGE;
#define HID_USAGE_GENERIC_POINTER ((USAGE) 0x01) #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_RUDDER ((USAGE) 0xBA)
#define HID_USAGE_SIMULATION_THROTTLE ((USAGE) 0xBB) #define HID_USAGE_SIMULATION_THROTTLE ((USAGE) 0xBB)
#pragma pack(pop)
#ifdef __cplusplus #ifdef __cplusplus
} }
#endif #endif

View File

@ -39,6 +39,13 @@ extern "C" {
#define EMULATOR_READ_ACCESS 0x01 #define EMULATOR_READ_ACCESS 0x01
#define EMULATOR_WRITE_ACCESS 0x02 #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 { typedef struct _EMULATOR_ACCESS_ENTRY {
ULONG BasePort; ULONG BasePort;
ULONG NumConsecutivePorts; ULONG NumConsecutivePorts;
@ -48,12 +55,8 @@ typedef struct _EMULATOR_ACCESS_ENTRY {
PVOID Routine; PVOID Routine;
} EMULATOR_ACCESS_ENTRY, *PEMULATOR_ACCESS_ENTRY; } EMULATOR_ACCESS_ENTRY, *PEMULATOR_ACCESS_ENTRY;
typedef enum _EMULATOR_PORT_ACCESS_TYPE { #ifndef VIDEO_ACCESS_RANGE_DEFINED /* also in video.h */
Uchar, #define VIDEO_ACCESS_RANGE_DEFINED
Ushort,
Ulong
} EMULATOR_PORT_ACCESS_TYPE, *PEMULATOR_PORT_ACCESS_TYPE;
typedef struct _VIDEO_ACCESS_RANGE { typedef struct _VIDEO_ACCESS_RANGE {
PHYSICAL_ADDRESS RangeStart; PHYSICAL_ADDRESS RangeStart;
ULONG RangeLength; ULONG RangeLength;
@ -62,6 +65,7 @@ typedef struct _VIDEO_ACCESS_RANGE {
UCHAR RangeShareable; UCHAR RangeShareable;
UCHAR RangePassive; UCHAR RangePassive;
} VIDEO_ACCESS_RANGE, *PVIDEO_ACCESS_RANGE; } VIDEO_ACCESS_RANGE, *PVIDEO_ACCESS_RANGE;
#endif
typedef VOID DDKAPI typedef VOID DDKAPI
(*PBANKED_SECTION_ROUTINE)( (*PBANKED_SECTION_ROUTINE)(

View File

@ -76,7 +76,8 @@ typedef enum _TAPE_STATUS {
} TAPE_STATUS, *PTAPE_STATUS; } TAPE_STATUS, *PTAPE_STATUS;
#define INQUIRYDATABUFFERSIZE 36 #define INQUIRYDATABUFFERSIZE 36
#ifndef _INQUIRYDATA_DEFINED /* also in scsi.h */
#define _INQUIRYDATA_DEFINED
typedef struct _INQUIRYDATA { typedef struct _INQUIRYDATA {
UCHAR DeviceType : 5; UCHAR DeviceType : 5;
UCHAR DeviceTypeQualifier : 3; UCHAR DeviceTypeQualifier : 3;
@ -119,6 +120,7 @@ typedef struct _INQUIRYDATA {
UCHAR VendorSpecific[20]; UCHAR VendorSpecific[20];
UCHAR Reserved3[40]; UCHAR Reserved3[40];
} INQUIRYDATA, *PINQUIRYDATA; } INQUIRYDATA, *PINQUIRYDATA;
#endif
typedef struct _MODE_CAPABILITIES_PAGE { typedef struct _MODE_CAPABILITIES_PAGE {
UCHAR PageCode : 6; UCHAR PageCode : 6;

View File

@ -3989,7 +3989,7 @@ typedef struct _NDIS_BIND_PATHS {
typedef struct _##BaseName BaseName, *P##BaseName; typedef struct _##BaseName BaseName, *P##BaseName;
#define DECLARE_UNKNOWN_PROTOTYPE(Name) \ #define DECLARE_UNKNOWN_PROTOTYPE(Name) \
typedef VOID (*##Name)(VOID); typedef VOID (*(Name))(VOID);
#define ETH_LENGTH_OF_ADDRESS 6 #define ETH_LENGTH_OF_ADDRESS 6

View File

@ -31,8 +31,6 @@
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4)
DEFINE_GUID(GUID_NDIS_LAN_CLASS, DEFINE_GUID(GUID_NDIS_LAN_CLASS,
0xad498944, 0x762f, 0x11d0, 0x8d, 0xcb, 0x00, 0xc0, 0x4f, 0xc3, 0x35, 0x8c); 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, DEFINE_GUID(GUID_NDIS_STATUS_RESET_START,
0x981f2d76, 0xb1f3, 0x11d0, 0x8d, 0xd7, 0x00, 0xc0, 0x4f, 0xc3, 0x35, 0x8c); 0x981f2d76, 0xb1f3, 0x11d0, 0x8d, 0xd7, 0x00, 0xc0, 0x4f, 0xc3, 0x35, 0x8c);
#pragma pack(pop)
#ifdef __cplusplus #ifdef __cplusplus
} }
#endif #endif

View File

@ -892,6 +892,9 @@ typedef union _CDB {
UCHAR AsByte[16]; UCHAR AsByte[16];
} CDB, *PCDB; } CDB, *PCDB;
#ifndef _INQUIRYDATA_DEFINED /* also in minitape.h */
#define _INQUIRYDATA_DEFINED
#define INQUIRYDATABUFFERSIZE 36 #define INQUIRYDATABUFFERSIZE 36
typedef struct _INQUIRYDATA { typedef struct _INQUIRYDATA {
@ -936,6 +939,7 @@ typedef struct _INQUIRYDATA {
UCHAR VendorSpecific[20]; UCHAR VendorSpecific[20];
UCHAR Reserved3[40]; UCHAR Reserved3[40];
} INQUIRYDATA, *PINQUIRYDATA; } INQUIRYDATA, *PINQUIRYDATA;
#endif
/* INQUIRYDATA.DeviceType constants */ /* INQUIRYDATA.DeviceType constants */
#define DIRECT_ACCESS_DEVICE 0x00 #define DIRECT_ACCESS_DEVICE 0x00

View File

@ -46,6 +46,21 @@ typedef struct _SCSIWMI_REQUEST_CONTEXT {
ULONG ReturnSize; ULONG ReturnSize;
} SCSIWMI_REQUEST_CONTEXT, *PSCSIWMI_REQUEST_CONTEXT; } 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 { typedef struct _SCSIWMIGUIDREGINFO {
LPCGUID Guid; LPCGUID Guid;
ULONG InstanceCount; ULONG InstanceCount;

View File

@ -311,7 +311,7 @@ typedef struct _TDI_REQUEST_SET_EVENT {
#define TDI_RECEIVE_AT_DISPATCH_LEVEL 0x00000800 #define TDI_RECEIVE_AT_DISPATCH_LEVEL 0x00000800
#define TDI_RECEIVE_CONTROL_INFO 0x00001000 #define TDI_RECEIVE_CONTROL_INFO 0x00001000
/* Listen flags * /* Listen flags */
#define TDI_QUERY_ACCEPT 0x00000001 #define TDI_QUERY_ACCEPT 0x00000001
/* Options used for both SendOptions and ReceiveIndicators */ /* Options used for both SendOptions and ReceiveIndicators */

View File

@ -31,8 +31,6 @@
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4)
#define TDI_SUCCESS STATUS_SUCCESS #define TDI_SUCCESS STATUS_SUCCESS
#define TDI_NO_RESOURCES STATUS_INSUFFICIENT_RESOURCES #define TDI_NO_RESOURCES STATUS_INSUFFICIENT_RESOURCES
#define TDI_ADDR_IN_USE STATUS_ADDRESS_ALREADY_EXISTS #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_REUSE 1
#define TDI_ADDRESS_OPTION_DHCP 2 #define TDI_ADDRESS_OPTION_DHCP 2
#pragma pack(pop)
#ifdef __cplusplus #ifdef __cplusplus
} }
#endif #endif

View File

@ -27,16 +27,16 @@
#pragma GCC system_header #pragma GCC system_header
#endif #endif
#ifdef __USBDI_H
#error usbdi.h cannot be included with usb.h
#else
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4) #pragma pack(push,4)
#ifdef __USBDI_H
#error usbdi.h cannot be included with usb.h
#endif
#include "ntddk.h" #include "ntddk.h"
#include "usb100.h" #include "usb100.h"
@ -470,4 +470,6 @@ typedef struct _OS_STRING {
} }
#endif #endif
#endif /* defined __USBDI_H */
#endif /* __USB_H */ #endif /* __USB_H */

View File

@ -27,16 +27,16 @@
#pragma GCC system_header #pragma GCC system_header
#endif #endif
#if !defined(__USB_H) && !defined(__USBDI_H)
#error include usb.h or usbdi.h before usbcamdi.h
#else
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4) #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" #include "ntddk.h"
#if defined(_BATTERYCLASS_) #if defined(_BATTERYCLASS_)
@ -398,4 +398,7 @@ USBCAMD_Debug_LogEntry(
} }
#endif #endif
#endif /* !defined(__USB_H) && !defined(__USBDI_H) */
#endif /* __USBCAMDI_H */ #endif /* __USBCAMDI_H */

View File

@ -27,16 +27,16 @@
#pragma GCC system_header #pragma GCC system_header
#endif #endif
#ifdef __USB_H
#error usb.h cannot be included with usbdi.h
#else
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4) #pragma pack(push,4)
#ifdef __USB_H
#error usb.h cannot be included with usbdi.h
#endif
#include "ntddk.h" #include "ntddk.h"
#include "usbioctl.h" #include "usbioctl.h"
@ -407,4 +407,6 @@ typedef struct _URB {
} }
#endif #endif
#endif /* defined __USB_H */
#endif /* __USBDI_H */ #endif /* __USBDI_H */

View File

@ -23,18 +23,21 @@
#ifndef __VIDEO_H #ifndef __VIDEO_H
#define __VIDEO_H #define __VIDEO_H
#ifdef __WINDDI_H
#error winddi.h cannot be included with video.h
#endif
#if __GNUC__ >=3 #if __GNUC__ >=3
#pragma GCC system_header #pragma GCC system_header
#endif #endif
#ifdef __WINDDI_H
#error winddi.h cannot be included with video.h
#else
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4)
#include "ntddk.h" #include "ntddk.h"
#if defined(_VIDEOPORT_) #if defined(_VIDEOPORT_)
@ -247,6 +250,8 @@ typedef BOOLEAN DDKAPI
#define VIDEO_RANGE_PASSIVE_DECODE 1 #define VIDEO_RANGE_PASSIVE_DECODE 1
#define VIDEO_RANGE_10_BIT_DECODE 2 #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 { typedef struct _VIDEO_ACCESS_RANGE {
PHYSICAL_ADDRESS RangeStart; PHYSICAL_ADDRESS RangeStart;
ULONG RangeLength; ULONG RangeLength;
@ -255,6 +260,7 @@ typedef struct _VIDEO_ACCESS_RANGE {
UCHAR RangeShareable; UCHAR RangeShareable;
UCHAR RangePassive; UCHAR RangePassive;
} VIDEO_ACCESS_RANGE, *PVIDEO_ACCESS_RANGE; } VIDEO_ACCESS_RANGE, *PVIDEO_ACCESS_RANGE;
#endif
typedef VOID DDKAPI typedef VOID DDKAPI
(*PVIDEO_HW_LEGACYRESOURCES)( (*PVIDEO_HW_LEGACYRESOURCES)(
@ -1559,4 +1565,6 @@ VideoPortZeroMemory(
} }
#endif #endif
#endif /* defined __WINDDI_H */
#endif /* __VIDEO_H */ #endif /* __VIDEO_H */

View File

@ -31,6 +31,8 @@
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4)
#include "ntddk.h" #include "ntddk.h"
#include "video.h" #include "video.h"

View File

@ -33,6 +33,7 @@ extern "C" {
#include "ntddk.h" #include "ntddk.h"
#pragma pack(push,4)
typedef enum _BUS_DATA_TYPE { typedef enum _BUS_DATA_TYPE {
ConfigurationSpaceUndefined = -1, ConfigurationSpaceUndefined = -1,

View File

@ -23,14 +23,14 @@
#ifndef __WINDDI_H #ifndef __WINDDI_H
#define __WINDDI_H #define __WINDDI_H
#ifdef __VIDEO_H
#error video.h cannot be included with winddi.h
#endif
#if __GNUC__ >=3 #if __GNUC__ >=3
#pragma GCC system_header #pragma GCC system_header
#endif #endif
#ifdef __VIDEO_H
#error video.h cannot be included with winddi.h
#else
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
@ -4141,4 +4141,6 @@ DrvGetDirectDrawInfo(
} }
#endif #endif
#endif /* defined __VIDEO_H */
#endif /* __WINDDI_H */ #endif /* __WINDDI_H */

View File

@ -31,6 +31,8 @@
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4)
/* /*
** Definitions specific to this Device Driver Kit ** Definitions specific to this Device Driver Kit
*/ */

View File

@ -31,6 +31,8 @@
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4)
typedef struct _ZONE_SEGMENT_HEADER { typedef struct _ZONE_SEGMENT_HEADER {
SINGLE_LIST_ENTRY SegmentList; SINGLE_LIST_ENTRY SegmentList;
PVOID Reserved; PVOID Reserved;

View File

@ -31,6 +31,8 @@
extern "C" { extern "C" {
#endif #endif
#pragma pack(push,4)
#include <winsock2.h> #include <winsock2.h>
#include "ntddk.h" #include "ntddk.h"

View File

@ -232,8 +232,6 @@ typedef ULONG TR_GROUP_ADDRESS;
} \ } \
} }
#pragma pack(pop)
#ifdef __cplusplus #ifdef __cplusplus
} }
#endif #endif