Deleted Added
full compact
ntoskrnl_var.h (151248) ntoskrnl_var.h (151451)
1/*-
2 * Copyright (c) 2003
3 * Bill Paul <wpaul@windriver.com>. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 15 unchanged lines hidden (view full) ---

24 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
30 * THE POSSIBILITY OF SUCH DAMAGE.
31 *
1/*-
2 * Copyright (c) 2003
3 * Bill Paul <wpaul@windriver.com>. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 15 unchanged lines hidden (view full) ---

24 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
30 * THE POSSIBILITY OF SUCH DAMAGE.
31 *
32 * $FreeBSD: head/sys/compat/ndis/ntoskrnl_var.h 151248 2005-10-12 03:02:50Z wpaul $
32 * $FreeBSD: head/sys/compat/ndis/ntoskrnl_var.h 151451 2005-10-18 19:52:15Z wpaul $
33 */
34
35#ifndef _NTOSKRNL_VAR_H_
36#define _NTOSKRNL_VAR_H_
37
33 */
34
35#ifndef _NTOSKRNL_VAR_H_
36#define _NTOSKRNL_VAR_H_
37
38#define MTX_NTOSKRNL_SPIN_LOCK "NDIS thread lock"
39
38/*
39 * us_buf is really a wchar_t *, but it's inconvenient to include
40 * all the necessary header goop needed to define it, and it's a
41 * pointer anyway, so for now, just make it a uint16_t *.
42 */
43struct unicode_string {
44 uint16_t us_len;
45 uint16_t us_maxlen;

--- 522 unchanged lines hidden (view full) ---

568typedef struct custom_extension custom_extension;
569
570/*
571 * The KINTERRUPT structure in Windows is opaque to drivers.
572 * We define our own custom version with things we need.
573 */
574
575struct kinterrupt {
40/*
41 * us_buf is really a wchar_t *, but it's inconvenient to include
42 * all the necessary header goop needed to define it, and it's a
43 * pointer anyway, so for now, just make it a uint16_t *.
44 */
45struct unicode_string {
46 uint16_t us_len;
47 uint16_t us_maxlen;

--- 522 unchanged lines hidden (view full) ---

570typedef struct custom_extension custom_extension;
571
572/*
573 * The KINTERRUPT structure in Windows is opaque to drivers.
574 * We define our own custom version with things we need.
575 */
576
577struct kinterrupt {
578 list_entry ki_list;
576 device_t ki_dev;
579 device_t ki_dev;
580 int ki_rid;
577 void *ki_cookie;
578 struct resource *ki_irq;
579 kspin_lock ki_lock_priv;
580 kspin_lock *ki_lock;
581 void *ki_svcfunc;
582 void *ki_svcctx;
583};
584

--- 714 unchanged lines hidden (view full) ---

1299extern int windrv_wrap(funcptr, funcptr *, int, int);
1300extern int windrv_unwrap(funcptr);
1301extern void ctxsw_utow(void);
1302extern void ctxsw_wtou(void);
1303
1304extern int ntoskrnl_libinit(void);
1305extern int ntoskrnl_libfini(void);
1306
581 void *ki_cookie;
582 struct resource *ki_irq;
583 kspin_lock ki_lock_priv;
584 kspin_lock *ki_lock;
585 void *ki_svcfunc;
586 void *ki_svcctx;
587};
588

--- 714 unchanged lines hidden (view full) ---

1303extern int windrv_wrap(funcptr, funcptr *, int, int);
1304extern int windrv_unwrap(funcptr);
1305extern void ctxsw_utow(void);
1306extern void ctxsw_wtou(void);
1307
1308extern int ntoskrnl_libinit(void);
1309extern int ntoskrnl_libfini(void);
1310
1311extern void ntoskrnl_intr(void *);
1312
1313extern uint16_t ExQueryDepthSList(slist_header *);
1314extern slist_entry
1315 *InterlockedPushEntrySList(slist_header *, slist_entry *);
1316extern slist_entry *InterlockedPopEntrySList(slist_header *);
1307extern uint32_t RtlUnicodeStringToAnsiString(ansi_string *,
1308 unicode_string *, uint8_t);
1309extern uint32_t RtlAnsiStringToUnicodeString(unicode_string *,
1310 ansi_string *, uint8_t);
1311extern void RtlInitAnsiString(ansi_string *, char *);
1312extern void RtlInitUnicodeString(unicode_string *,
1313 uint16_t *);
1314extern void RtlFreeUnicodeString(unicode_string *);

--- 22 unchanged lines hidden (view full) ---

1337extern void KefAcquireSpinLockAtDpcLevel(kspin_lock *);
1338extern void KefReleaseSpinLockFromDpcLevel(kspin_lock *);
1339extern uint8_t KeAcquireSpinLockRaiseToDpc(kspin_lock *);
1340#else
1341extern void KeAcquireSpinLockAtDpcLevel(kspin_lock *);
1342extern void KeReleaseSpinLockFromDpcLevel(kspin_lock *);
1343#endif
1344extern void KeInitializeSpinLock(kspin_lock *);
1317extern uint32_t RtlUnicodeStringToAnsiString(ansi_string *,
1318 unicode_string *, uint8_t);
1319extern uint32_t RtlAnsiStringToUnicodeString(unicode_string *,
1320 ansi_string *, uint8_t);
1321extern void RtlInitAnsiString(ansi_string *, char *);
1322extern void RtlInitUnicodeString(unicode_string *,
1323 uint16_t *);
1324extern void RtlFreeUnicodeString(unicode_string *);

--- 22 unchanged lines hidden (view full) ---

1347extern void KefAcquireSpinLockAtDpcLevel(kspin_lock *);
1348extern void KefReleaseSpinLockFromDpcLevel(kspin_lock *);
1349extern uint8_t KeAcquireSpinLockRaiseToDpc(kspin_lock *);
1350#else
1351extern void KeAcquireSpinLockAtDpcLevel(kspin_lock *);
1352extern void KeReleaseSpinLockFromDpcLevel(kspin_lock *);
1353#endif
1354extern void KeInitializeSpinLock(kspin_lock *);
1355extern uint8_t KeAcquireInterruptSpinLock(kinterrupt *);
1356extern void KeReleaseInterruptSpinLock(kinterrupt *, uint8_t);
1345extern uint8_t KeSynchronizeExecution(kinterrupt *, void *, void *);
1346extern uintptr_t InterlockedExchange(volatile uint32_t *,
1347 uintptr_t);
1348extern void *ExAllocatePoolWithTag(uint32_t, size_t, uint32_t);
1349extern void ExFreePool(void *);
1350extern uint32_t IoConnectInterrupt(kinterrupt **, void *, void *,
1351 kspin_lock *, uint32_t, uint8_t, uint8_t, uint8_t, uint8_t,
1352 uint32_t, uint8_t);

--- 56 unchanged lines hidden ---
1357extern uint8_t KeSynchronizeExecution(kinterrupt *, void *, void *);
1358extern uintptr_t InterlockedExchange(volatile uint32_t *,
1359 uintptr_t);
1360extern void *ExAllocatePoolWithTag(uint32_t, size_t, uint32_t);
1361extern void ExFreePool(void *);
1362extern uint32_t IoConnectInterrupt(kinterrupt **, void *, void *,
1363 kspin_lock *, uint32_t, uint8_t, uint8_t, uint8_t, uint8_t,
1364 uint32_t, uint8_t);

--- 56 unchanged lines hidden ---