VirtualBox

source: vbox/trunk/src/VBox/HostDrivers/VBoxUSB/win/mon/VBoxUsbMon.h@ 38488

Last change on this file since 38488 was 38488, checked in by vboxsync, 13 years ago

usb/win: usbhub filter drivers support (more correct dealing with usbhub device & driver objects)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.1 KB
Line 
1/* $Id: VBoxUsbMon.h 38488 2011-08-18 10:26:06Z vboxsync $ */
2/** @file
3 * VBox USB Monitor
4 */
5/*
6 * Copyright (C) 2011 Oracle Corporation
7 *
8 * This file is part of VirtualBox Open Source Edition (OSE), as
9 * available from http://www.virtualbox.org. This file is free software;
10 * you can redistribute it and/or modify it under the terms of the GNU
11 * General Public License (GPL) as published by the Free Software
12 * Foundation, in version 2 as it comes in the "COPYING" file of the
13 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
14 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
15 */
16#ifndef ___VBoxUsbMon_h___
17#define ___VBoxUsbMon_h___
18
19#include <VBox/cdefs.h>
20#include <VBox/types.h>
21#include <iprt/assert.h>
22#include <VBox/sup.h>
23#include <iprt/asm.h>
24#include <VBox/log.h>
25
26#ifdef DEBUG
27/* disables filters */
28//#define VBOXUSBMON_DBG_NO_FILTERS
29/* disables pnp hooking */
30//#define VBOXUSBMON_DBG_NO_PNPHOOK
31#endif
32
33#include "../../../win/VBoxDbgLog.h"
34#include "../cmn/VBoxDrvTool.h"
35#include "../cmn/VBoxUsbTool.h"
36
37#include "VBoxUsbHook.h"
38#include "VBoxUsbFlt.h"
39
40PVOID VBoxUsbMonMemAlloc(SIZE_T cbBytes);
41PVOID VBoxUsbMonMemAllocZ(SIZE_T cbBytes);
42VOID VBoxUsbMonMemFree(PVOID pvMem);
43
44NTSTATUS VBoxUsbMonGetDescriptor(PDEVICE_OBJECT pDevObj, void *buffer, int size, int type, int index, int language_id);
45NTSTATUS VBoxUsbMonQueryBusRelations(PDEVICE_OBJECT pDevObj, PFILE_OBJECT pFileObj, PDEVICE_RELATIONS *pDevRelations);
46
47void vboxUsbDbgPrintUnicodeString(PUNICODE_STRING pUnicodeString);
48
49/* visit usbhub-originated device PDOs */
50#define VBOXUSBMONHUBWALK_F_PDO 0x00000001
51/* visit usbhub device FDOs */
52#define VBOXUSBMONHUBWALK_F_FDO 0x00000002
53/* visit all usbhub-originated device objects */
54#define VBOXUSBMONHUBWALK_F_ALL (VBOXUSBMONHUBWALK_F_FDO | VBOXUSBMONHUBWALK_F_PDO)
55
56typedef DECLCALLBACK(BOOLEAN) FNVBOXUSBMONDEVWALKER(PFILE_OBJECT pFile, PDEVICE_OBJECT pTopDo, PDEVICE_OBJECT pHubDo, PVOID pvContext);
57typedef FNVBOXUSBMONDEVWALKER *PFNVBOXUSBMONDEVWALKER;
58
59VOID vboxUsbMonHubDevWalk(PFNVBOXUSBMONDEVWALKER pfnWalker, PVOID pvWalker, ULONG fFlags);
60
61#endif /* #ifndef ___VBoxUsbMon_h___ */
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette