This commit brings support for compiling ReactOS with Visual Studio 2015 RC (and...
[reactos.git] / reactos / drivers / network / ndis / include / ndissys.h
1 /*
2 * COPYRIGHT: See COPYING in the top level directory
3 * PROJECT: ReactOS NDIS library
4 * FILE: ndissys.h
5 * PURPOSE: NDIS library definitions
6 * NOTES: Spin lock acquire order:
7 * - Miniport list lock
8 * - Adapter list lock
9 */
10 #ifndef __NDISSYS_H
11 #define __NDISSYS_H
12
13 /* portability fixes */
14 #ifdef _M_AMD64
15 #define KfReleaseSpinLock KeReleaseSpinLock
16 #define KefAcquireSpinLockAtDpcLevel KeAcquireSpinLockAtDpcLevel
17 #define KefReleaseSpinLockFromDpcLevel KeReleaseSpinLockFromDpcLevel
18 #endif
19
20 #include <ndis.h>
21
22 #include "debug.h"
23 #include "miniport.h"
24 #include "protocol.h"
25 #include "efilter.h"
26 #include "buffer.h"
27
28 /* Exported functions */
29 #ifndef EXPORT
30 #define EXPORT NTAPI
31 #endif
32
33 /* the version of NDIS we claim to be */
34 #define NDIS_VERSION 0x00050001
35
36 #define NDIS_TAG 0x4e4d4953
37
38 #define MIN(value1, value2) \
39 ((value1 < value2)? value1 : value2)
40
41 #define MAX(value1, value2) \
42 ((value1 > value2)? value1 : value2)
43
44 #define ExInterlockedRemoveEntryList(_List,_Lock) \
45 { KIRQL OldIrql; \
46 KeAcquireSpinLock(_Lock, &OldIrql); \
47 RemoveEntryList(_List); \
48 KeReleaseSpinLock(_Lock, OldIrql); \
49 }
50
51 /* missing protypes */
52 VOID
53 NTAPI
54 ExGetCurrentProcessorCounts(
55 PULONG ThreadKernelTime,
56 PULONG TotalCpuTime,
57 PULONG ProcessorNumber);
58
59 VOID
60 NTAPI
61 ExGetCurrentProcessorCpuUsage(
62 PULONG CpuUsage);
63
64 #endif /* __NDISSYS_H */