ReactOS 0.4.17-dev-1281-g065abb3
clientif.h
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS USB Host Controller Extension
3 * LICENSE: MIT (https://spdx.org/licenses/MIT)
4 * PURPOSE: USBD client handles and the USBDI bus interface
5 * COPYRIGHT: Copyright 2026 Justin Miller <justin.miller@reactos.org>
6 */
7
8#pragma once
9
10/* What GetUSBDIVersion reports; newer than the USBDI_VERSION in usb.h */
11#define UCX_USBDI_VERSION 0x600
12
15{
16public:
18 static
20 CreateFromQuery(
24
25 VOID
26 Unregister();
27
28 static
31 _In_ USBD_CLIENT_HANDLE Handle)
32 {
33 return (UcxUsbdHandle*)Handle;
34 }
35
36 /* XRB allocation */
37
43
44 VOID
46 _In_ UcxXrbPreamble* Xrb);
47
48public:
54
55 /* Still valid once the device is gone */
57 WDFMEMORY m_Memory;
58 WDFDEVICE m_RootHubPdo;
60
61 /* On the USB device's handle list */
63
64 /* Device delete already dropped the client device object reference */
66
67 /* Storage deleted; XRBs still out keep it readable through their references */
69
78
79 /* Granted through QUERY_USB_CAPABILITY */
83
84 /* Every live XRB, kept only when verifying */
88};
89
91VOID
95
Type
Definition: Type.h:7
unsigned char BOOLEAN
Definition: actypes.h:127
LONG NTSTATUS
Definition: precomp.h:26
ULONG m_VerifierStaticStreamCountOverride
Definition: clientif.h:74
NTSTATUS AllocateXrb(_In_ ULONG Size, _In_ ULONG Type, _Outptr_ UcxXrbPreamble **Xrb)
Definition: clientif.cpp:663
UcxController * m_Controller
Definition: clientif.h:56
KSPIN_LOCK m_XrbLock
Definition: clientif.h:86
ULONG m_VerifierFailEndpointOffload
Definition: clientif.h:77
ULONG m_PoolTag
Definition: clientif.h:51
UcxUsbDevice * m_Device
Definition: clientif.h:53
ULONG m_VerifierFailRegistration
Definition: clientif.h:71
BOOLEAN m_TrackXrbs
Definition: clientif.h:85
ULONG m_VerifierFailChainedMdl
Definition: clientif.h:72
PVOID m_ClientContext
Definition: clientif.h:52
BOOLEAN m_Orphaned
Definition: clientif.h:65
BOOLEAN m_StreamsGranted
Definition: clientif.h:80
ULONG m_GrantedStreams
Definition: clientif.h:82
LIST_ENTRY m_XrbList
Definition: clientif.h:87
BOOLEAN m_VerifierEnabled
Definition: clientif.h:70
ULONG m_ContractVersion
Definition: clientif.h:49
BOOLEAN m_ChainedMdlGranted
Definition: clientif.h:81
LIST_ENTRY m_DeviceLink
Definition: clientif.h:62
static UcxUsbdHandle * FromClientHandle(_In_ USBD_CLIENT_HANDLE Handle)
Definition: clientif.h:30
ULONG m_VerifierFailSecureTransfer
Definition: clientif.h:76
PDEVICE_OBJECT m_ClientDeviceObject
Definition: clientif.h:50
BOOLEAN m_Unregistered
Definition: clientif.h:68
_IRQL_requires_(PASSIVE_LEVEL) static NTSTATUS CreateFromQuery(_In_ UcxRootHub *RootHub
ULONG m_VerifierFailStaticStreamSupport
Definition: clientif.h:73
VOID TrackXrb(_In_ UcxXrbPreamble *Xrb)
Definition: clientif.cpp:724
WDFMEMORY m_Memory
Definition: clientif.h:57
VOID Unregister()
Definition: clientif.cpp:589
ULONG m_VerifierFailEnableStaticStreams
Definition: clientif.h:75
UcxRootHub * m_RootHub
Definition: clientif.h:59
WDFDEVICE m_RootHubPdo
Definition: clientif.h:58
BOOLEAN NTAPI UcxAnyUsbdHandleHasVerifier(_In_ UcxUsbDevice *Device)
Definition: clientif.cpp:646
VOID NTAPI UcxDropLeakedUsbdHandles(_In_ UcxUsbDevice *Device)
Definition: clientif.cpp:615
#define PASSIVE_LEVEL
Definition: env_spec_w32.h:693
ULONG KSPIN_LOCK
Definition: env_spec_w32.h:72
ULONG Handle
Definition: gdb_input.c:15
_Must_inspect_result_ _In_ PUCXHUB_DEVICE_CREATE_INFO _Out_ UCXUSBDEVICE * Device
Definition: hubucx.h:258
#define _Inout_
Definition: no_sal2.h:162
#define _Outptr_
Definition: no_sal2.h:262
#define _In_
Definition: no_sal2.h:158
Definition: typedefs.h:120
#define NTAPI
Definition: typedefs.h:36
uint32_t ULONG
Definition: typedefs.h:59
_Must_inspect_result_ _In_ UCXCONTROLLER _In_ PUCX_ROOTHUB_CONFIG _In_opt_ PWDF_OBJECT_ATTRIBUTES _Out_ UCXROOTHUB * RootHub
Definition: ucxroothub.h:299
_In_ UCXUSBDEVICE _In_ ULONG Interface
Definition: ucxusbdevice.h:428
_Must_inspect_result_ _In_ WDFDEVICE _In_ PWDF_DEVICE_PROPERTY_DATA _In_ DEVPROPTYPE _In_ ULONG Size
Definition: wdfdevice.h:4539