Initial bulk commit for "Git on MSys"
[msysgit/historical-msysgit.git] / mingw / include / ddk / win2k.h
blob84eadd0ba04e66f023c78529e8c3a8f1553d3019
1 /*
2 * win2k.h
4 * Definitions only used in Windows 2000 and earlier versions
6 * This file is part of the w32api package.
8 * Contributors:
9 * Created by Casper S. Hornstrup <chorns@users.sourceforge.net>
11 * THIS SOFTWARE IS NOT COPYRIGHTED
13 * This source code is offered for use in the public domain. You may
14 * use, modify or distribute it freely.
16 * This code is distributed in the hope that it will be useful but
17 * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
18 * DISCLAIMED. This includes but is not limited to warranties of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
23 #ifndef __WIN2K_H
24 #define __WIN2K_H
26 #if __GNUC__ >=3
27 #pragma GCC system_header
28 #endif
30 #ifdef __cplusplus
31 extern "C" {
32 #endif
34 #include "ntddk.h"
36 #pragma pack(push,4)
38 typedef enum _BUS_DATA_TYPE {
39 ConfigurationSpaceUndefined = -1,
40 Cmos,
41 EisaConfiguration,
42 Pos,
43 CbusConfiguration,
44 PCIConfiguration,
45 VMEConfiguration,
46 NuBusConfiguration,
47 PCMCIAConfiguration,
48 MPIConfiguration,
49 MPSAConfiguration,
50 PNPISAConfiguration,
51 SgiInternalConfiguration,
52 MaximumBusDataType
53 } BUS_DATA_TYPE, *PBUS_DATA_TYPE;
55 NTOSAPI
56 VOID
57 DDKAPI
58 ExReleaseResourceForThreadLite(
59 /*IN*/ PERESOURCE Resource,
60 /*IN*/ ERESOURCE_THREAD ResourceThreadId);
62 NTOSAPI
63 NTSTATUS
64 DDKAPI
65 IoReadPartitionTable(
66 /*IN*/ PDEVICE_OBJECT DeviceObject,
67 /*IN*/ ULONG SectorSize,
68 /*IN*/ BOOLEAN ReturnRecognizedPartitions,
69 /*OUT*/ struct _DRIVE_LAYOUT_INFORMATION **PartitionBuffer);
71 NTOSAPI
72 NTSTATUS
73 DDKAPI
74 IoSetPartitionInformation(
75 /*IN*/ PDEVICE_OBJECT DeviceObject,
76 /*IN*/ ULONG SectorSize,
77 /*IN*/ ULONG PartitionNumber,
78 /*IN*/ ULONG PartitionType);
80 NTOSAPI
81 NTSTATUS
82 DDKAPI
83 IoWritePartitionTable(
84 /*IN*/ PDEVICE_OBJECT DeviceObject,
85 /*IN*/ ULONG SectorSize,
86 /*IN*/ ULONG SectorsPerTrack,
87 /*IN*/ ULONG NumberOfHeads,
88 /*IN*/ struct _DRIVE_LAYOUT_INFORMATION *PartitionBuffer);
91 * PVOID MmGetSystemAddressForMdl(
92 * IN PMDL Mdl);
94 #define MmGetSystemAddressForMdl(Mdl) \
95 (((Mdl)->MdlFlags & (MDL_MAPPED_TO_SYSTEM_VA | \
96 MDL_SOURCE_IS_NONPAGED_POOL)) ? \
97 ((Mdl)->MappedSystemVa) : \
98 (MmMapLockedPages((Mdl), KernelMode)))
100 #pragma pack(pop)
102 #ifdef __cplusplus
104 #endif
106 #endif /* __WIN2K_H */