ReactOS  0.4.14-dev-583-g2a1ba2c
hidpi.h File Reference
#include "hidusage.h"
Include dependency graph for hidpi.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _HIDP_UNKNOWN_TOKEN
 
struct  _HIDP_KEYBOARD_MODIFIER_STATE
 
struct  _USAGE_AND_PAGE
 
struct  _HIDD_ATTRIBUTES
 
struct  _HIDD_CONFIGURATION
 
struct  _HIDP_BUTTON_CAPS
 
struct  _HIDP_CAPS
 
struct  _HIDP_DATA
 
struct  _HIDP_EXTENDED_ATTRIBUTES
 
struct  _HIDP_LINK_COLLECTION_NODE
 
struct  _HIDP_VALUE_CAPS
 

Macros

#define HIDAPI   DECLSPEC_IMPORT
 
#define HIDP_LINK_COLLECTION_ROOT   ((USHORT) -1)
 
#define HIDP_LINK_COLLECTION_UNSPECIFIED   ((USHORT) 0)
 
#define FACILITY_HID_ERROR_CODE   0x11
 
#define HIDP_ERROR_CODES(SEV, CODE)   ((NTSTATUS) (((SEV) << 28) | (FACILITY_HID_ERROR_CODE << 16) | (CODE)))
 
#define HIDP_STATUS_SUCCESS   (HIDP_ERROR_CODES(0x0, 0))
 
#define HIDP_STATUS_NULL   (HIDP_ERROR_CODES(0x8, 1))
 
#define HIDP_STATUS_INVALID_PREPARSED_DATA   (HIDP_ERROR_CODES(0xC, 1))
 
#define HIDP_STATUS_INVALID_REPORT_TYPE   (HIDP_ERROR_CODES(0xC, 2))
 
#define HIDP_STATUS_INVALID_REPORT_LENGTH   (HIDP_ERROR_CODES(0xC, 3))
 
#define HIDP_STATUS_USAGE_NOT_FOUND   (HIDP_ERROR_CODES(0xC, 4))
 
#define HIDP_STATUS_VALUE_OUT_OF_RANGE   (HIDP_ERROR_CODES(0xC, 5))
 
#define HIDP_STATUS_BAD_LOG_PHY_VALUES   (HIDP_ERROR_CODES(0xC, 6))
 
#define HIDP_STATUS_BUFFER_TOO_SMALL   (HIDP_ERROR_CODES(0xC, 7))
 
#define HIDP_STATUS_INTERNAL_ERROR   (HIDP_ERROR_CODES(0xC, 8))
 
#define HIDP_STATUS_I8042_TRANS_UNKNOWN   (HIDP_ERROR_CODES(0xC, 9))
 
#define HIDP_STATUS_INCOMPATIBLE_REPORT_ID   (HIDP_ERROR_CODES(0xC, 0xA))
 
#define HIDP_STATUS_NOT_VALUE_ARRAY   (HIDP_ERROR_CODES(0xC, 0xB))
 
#define HIDP_STATUS_IS_VALUE_ARRAY   (HIDP_ERROR_CODES(0xC, 0xC))
 
#define HIDP_STATUS_DATA_INDEX_NOT_FOUND   (HIDP_ERROR_CODES(0xC, 0xD))
 
#define HIDP_STATUS_DATA_INDEX_OUT_OF_RANGE   (HIDP_ERROR_CODES(0xC, 0xE))
 
#define HIDP_STATUS_BUTTON_NOT_PRESSED   (HIDP_ERROR_CODES(0xC, 0xF))
 
#define HIDP_STATUS_REPORT_DOES_NOT_EXIST   (HIDP_ERROR_CODES(0xC, 0x10))
 
#define HIDP_STATUS_NOT_IMPLEMENTED   (HIDP_ERROR_CODES(0xC, 0x20))
 
#define HIDP_STATUS_I8242_TRANS_UNKNOWN   HIDP_STATUS_I8042_TRANS_UNKNOWN
 
#define HidP_GetButtonCaps(_Type_, _Caps_, _Len_, _Data_)   HidP_GetSpecificButtonCaps(_Type_, 0, 0, 0, _Caps_, _Len_, _Data_)
 
#define HidP_GetButtons(Rty, UPa, LCo, ULi, ULe, Ppd, Rep, RLe)   HidP_GetUsages(Rty, UPa, LCo, ULi, ULe, Ppd, Rep, RLe)
 
#define HidP_GetButtonListLength(RTy, UPa, Ppd)   HidP_GetUsageListLength(Rty, UPa, Ppd)
 
#define HidP_GetButtonsEx(RT, LC, BL, UL, PD, R, RL)   HidP_GetUsagesEx(RT, LC, BL, UL, PD, R, RL)
 
#define HidP_GetValueCaps(_Type_, _Caps_, _Len_, _Data_)   HidP_GetSpecificValueCaps (_Type_, 0, 0, 0, _Caps_, _Len_, _Data_)
 
#define HidP_IsSameUsageAndPage(u1, u2)   ((* (PULONG) &u1) == (* (PULONG) &u2))
 
#define HidP_SetButtons(RT, UP, LC, UL1, UL2, PD, R, RL)   HidP_SetUsages(RT, UP, LC, UL1, UL2, PD, R, RL)
 
#define HidP_UnsetButtons(RT, UP, LC, UL1, UL2, PD, R, RL)   HidP_UnsetUsages(RT, UP, LC, UL1, UL2, PD, R, RL)
 

Typedefs

typedef PUCHAR PHIDP_REPORT_DESCRIPTOR
 
typedef struct _HIDP_PREPARSED_DATA * PHIDP_PREPARSED_DATA
 
typedef struct _HIDP_UNKNOWN_TOKEN HIDP_UNKNOWN_TOKEN
 
typedef struct _HIDP_UNKNOWN_TOKENPHIDP_UNKNOWN_TOKEN
 
typedef enum _HIDP_KEYBOARD_DIRECTION HIDP_KEYBOARD_DIRECTION
 
typedef struct _HIDP_KEYBOARD_MODIFIER_STATE HIDP_KEYBOARD_MODIFIER_STATE
 
typedef struct _HIDP_KEYBOARD_MODIFIER_STATEPHIDP_KEYBOARD_MODIFIER_STATE
 
typedef BOOLEAN(NTAPIPHIDP_INSERT_SCANCODES) (_In_opt_ PVOID Context, _In_reads_bytes_(Length) PCHAR NewScanCodes, _In_ ULONG Length)
 
typedef struct _USAGE_AND_PAGE USAGE_AND_PAGE
 
typedef struct _USAGE_AND_PAGEPUSAGE_AND_PAGE
 
typedef struct _HIDD_ATTRIBUTES HIDD_ATTRIBUTES
 
typedef struct _HIDD_ATTRIBUTESPHIDD_ATTRIBUTES
 
typedef struct _HIDD_CONFIGURATION HIDD_CONFIGURATION
 
typedef struct _HIDD_CONFIGURATIONPHIDD_CONFIGURATION
 
typedef struct _HIDP_BUTTON_CAPS HIDP_BUTTON_CAPS
 
typedef struct _HIDP_BUTTON_CAPSPHIDP_BUTTON_CAPS
 
typedef struct _HIDP_CAPS HIDP_CAPS
 
typedef struct _HIDP_CAPSPHIDP_CAPS
 
typedef struct _HIDP_DATA HIDP_DATA
 
typedef struct _HIDP_DATAPHIDP_DATA
 
typedef struct _HIDP_EXTENDED_ATTRIBUTES HIDP_EXTENDED_ATTRIBUTES
 
typedef struct _HIDP_EXTENDED_ATTRIBUTESPHIDP_EXTENDED_ATTRIBUTES
 
typedef struct _HIDP_LINK_COLLECTION_NODE HIDP_LINK_COLLECTION_NODE
 
typedef struct _HIDP_LINK_COLLECTION_NODEPHIDP_LINK_COLLECTION_NODE
 
typedef struct _HIDP_VALUE_CAPS HIDP_VALUE_CAPS
 
typedef struct _HIDP_VALUE_CAPSPHIDP_VALUE_CAPS
 
typedef enum _HIDP_REPORT_TYPE HIDP_REPORT_TYPE
 

Enumerations

enum  _HIDP_KEYBOARD_DIRECTION { HidP_Keyboard_Break, HidP_Keyboard_Make }
 
enum  _HIDP_REPORT_TYPE { HidP_Input, HidP_Output, HidP_Feature }
 

Functions

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_TranslateUsageAndPagesToI8042ScanCodes (_In_reads_(UsageListLength) PUSAGE_AND_PAGE ChangedUsageList, _In_ ULONG UsageListLength, _In_ HIDP_KEYBOARD_DIRECTION KeyAction, _Inout_ PHIDP_KEYBOARD_MODIFIER_STATE ModifierState, _In_ PHIDP_INSERT_SCANCODES InsertCodesProcedure, _In_opt_ PVOID InsertCodesContext)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_TranslateUsagesToI8042ScanCodes (_In_reads_(UsageListLength) PUSAGE ChangedUsageList, _In_ ULONG UsageListLength, _In_ HIDP_KEYBOARD_DIRECTION KeyAction, _Inout_ PHIDP_KEYBOARD_MODIFIER_STATE ModifierState, _In_ PHIDP_INSERT_SCANCODES InsertCodesProcedure, _In_opt_ PVOID InsertCodesContext)
 
_Must_inspect_result_ _IRQL_requires_max_ (PASSIVE_LEVEL) HIDAPI NTSTATUS NTAPI HidP_GetCaps(_In_ PHIDP_PREPARSED_DATA PreparsedData
 
_Must_inspect_result_ _IRQL_requires_max_ (DISPATCH_LEVEL) HIDAPI NTSTATUS NTAPI HidP_GetData(_In_ HIDP_REPORT_TYPE ReportType
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA _Inout_ PULONG _In_ PHIDP_PREPARSED_DATA _Out_writes_bytes_ (ReportLength) PCHAR Report
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetScaledUsageValue (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _Out_ PLONG UsageValue, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsages (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _Out_writes_to_(*UsageLength, *UsageLength) USAGE *UsageList, _Inout_ ULONG *UsageLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _Out_writes_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ _In_ USHORT _Inout_updates_to_ UsageLength PUSAGE_AND_PAGE _Inout_ ULONG _In_ PHIDP_PREPARSED_DATA _In_reads_bytes_ (ReportLength) PCHAR Report
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsageValue (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _Out_ PULONG UsageValue, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsageValueArray (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _Inout_updates_bytes_(UsageValueByteLength) PCHAR UsageValue, _In_ USHORT UsageValueByteLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetData (_In_ HIDP_REPORT_TYPE ReportType, _Inout_updates_to_(*DataLength, *DataLength) PHIDP_DATA DataList, _Inout_ PULONG DataLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetScaledUsageValue (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _In_ LONG UsageValue, _In_ PHIDP_PREPARSED_DATA PreparsedData, _Inout_updates_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsages (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _Inout_updates_to_(*UsageLength, *UsageLength) PUSAGE UsageList, _Inout_ PULONG UsageLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsageValue (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _In_ ULONG UsageValue, _In_ PHIDP_PREPARSED_DATA PreparsedData, _Inout_updates_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsageValueArray (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_ USHORT LinkCollection, _In_ USAGE Usage, _In_reads_bytes_(UsageValueByteLength) PCHAR UsageValue, _In_ USHORT UsageValueByteLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _Inout_updates_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_UnsetUsages (_In_ HIDP_REPORT_TYPE ReportType, _In_ USAGE UsagePage, _In_opt_ USHORT LinkCollection, _Inout_updates_to_(*UsageLength, *UsageLength) PUSAGE UsageList, _Inout_ PULONG UsageLength, _In_ PHIDP_PREPARSED_DATA PreparsedData, _In_reads_bytes_(ReportLength) PCHAR Report, _In_ ULONG ReportLength)
 
_Must_inspect_result_ _In_reads_ (UsageListLength) PUSAGE_AND_PAGE CurrentUsageList
 
_Must_inspect_result_ _Out_writes_ (UsageListLength) PUSAGE_AND_PAGE BreakUsageList
 

Variables

_Must_inspect_result_ _Out_ PHIDP_CAPS Capabilities
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA DataList
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA _Inout_ PULONG DataLength
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA _Inout_ PULONG _In_ PHIDP_PREPARSED_DATA PreparsedData
 
_Must_inspect_result_ _Out_writes_to_ DataLength PHIDP_DATA _Inout_ PULONG _In_ PHIDP_PREPARSED_DATA _In_ ULONG ReportLength
 
_Must_inspect_result_ _In_ USHORT DataIndex
 
_Must_inspect_result_ _In_ USHORT _In_ PHIDP_PREPARSED_DATA _Out_writes_to_ LengthAttributes PHIDP_EXTENDED_ATTRIBUTES Attributes
 
_Must_inspect_result_ _In_ USHORT _In_ PHIDP_PREPARSED_DATA _Out_writes_to_ LengthAttributes PHIDP_EXTENDED_ATTRIBUTES _Inout_ OUT PULONG LengthAttributes
 
_Must_inspect_result_ _Inout_ PULONG LinkCollectionNodesLength
 
_Must_inspect_result_ _In_ USAGE UsagePage
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT LinkCollection
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE Usage
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE _Out_ PHIDP_BUTTON_CAPS ButtonCaps
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE _Out_ PHIDP_BUTTON_CAPS _Inout_ PUSHORT ButtonCapsLength
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE _Out_ PHIDP_VALUE_CAPS ValueCaps
 
_Must_inspect_result_ _In_ USAGE _In_ USHORT _In_ USAGE _Out_ PHIDP_VALUE_CAPS _Inout_ PUSHORT ValueCapsLength
 
_Must_inspect_result_ _In_ USHORT _Inout_updates_to_ UsageLength PUSAGE_AND_PAGE ButtonList
 
_Must_inspect_result_ _In_ USHORT _Inout_updates_to_ UsageLength PUSAGE_AND_PAGE _Inout_ ULONGUsageLength
 
_Must_inspect_result_ _In_ UCHAR ReportID
 
_Must_inspect_result_ _In_ ULONG UsageListLength
 

Macro Definition Documentation

◆ FACILITY_HID_ERROR_CODE

#define FACILITY_HID_ERROR_CODE   0x11

Definition at line 243 of file hidpi.h.

◆ HIDAPI

#define HIDAPI   DECLSPEC_IMPORT

Definition at line 35 of file hidpi.h.

◆ HIDP_ERROR_CODES

#define HIDP_ERROR_CODES (   SEV,
  CODE 
)    ((NTSTATUS) (((SEV) << 28) | (FACILITY_HID_ERROR_CODE << 16) | (CODE)))

Definition at line 245 of file hidpi.h.

◆ HidP_GetButtonCaps

#define HidP_GetButtonCaps (   _Type_,
  _Caps_,
  _Len_,
  _Data_ 
)    HidP_GetSpecificButtonCaps(_Type_, 0, 0, 0, _Caps_, _Len_, _Data_)

Definition at line 279 of file hidpi.h.

◆ HidP_GetButtonListLength

#define HidP_GetButtonListLength (   RTy,
  UPa,
  Ppd 
)    HidP_GetUsageListLength(Rty, UPa, Ppd)

Definition at line 297 of file hidpi.h.

◆ HidP_GetButtons

#define HidP_GetButtons (   Rty,
  UPa,
  LCo,
  ULi,
  ULe,
  Ppd,
  Rep,
  RLe 
)    HidP_GetUsages(Rty, UPa, LCo, ULi, ULe, Ppd, Rep, RLe)

Definition at line 294 of file hidpi.h.

◆ HidP_GetButtonsEx

#define HidP_GetButtonsEx (   RT,
  LC,
  BL,
  UL,
  PD,
  R,
  RL 
)    HidP_GetUsagesEx(RT, LC, BL, UL, PD, R, RL)

Definition at line 312 of file hidpi.h.

◆ HidP_GetValueCaps

#define HidP_GetValueCaps (   _Type_,
  _Caps_,
  _Len_,
  _Data_ 
)    HidP_GetSpecificValueCaps (_Type_, 0, 0, 0, _Caps_, _Len_, _Data_)

Definition at line 470 of file hidpi.h.

◆ HidP_IsSameUsageAndPage

#define HidP_IsSameUsageAndPage (   u1,
  u2 
)    ((* (PULONG) &u1) == (* (PULONG) &u2))

Definition at line 495 of file hidpi.h.

◆ HIDP_LINK_COLLECTION_ROOT

#define HIDP_LINK_COLLECTION_ROOT   ((USHORT) -1)

Definition at line 184 of file hidpi.h.

◆ HIDP_LINK_COLLECTION_UNSPECIFIED

#define HIDP_LINK_COLLECTION_UNSPECIFIED   ((USHORT) 0)

Definition at line 185 of file hidpi.h.

◆ HidP_SetButtons

#define HidP_SetButtons (   RT,
  UP,
  LC,
  UL1,
  UL2,
  PD,
  R,
  RL 
)    HidP_SetUsages(RT, UP, LC, UL1, UL2, PD, R, RL)

Definition at line 530 of file hidpi.h.

◆ HIDP_STATUS_BAD_LOG_PHY_VALUES

#define HIDP_STATUS_BAD_LOG_PHY_VALUES   (HIDP_ERROR_CODES(0xC, 6))

Definition at line 255 of file hidpi.h.

◆ HIDP_STATUS_BUFFER_TOO_SMALL

#define HIDP_STATUS_BUFFER_TOO_SMALL   (HIDP_ERROR_CODES(0xC, 7))

Definition at line 256 of file hidpi.h.

◆ HIDP_STATUS_BUTTON_NOT_PRESSED

#define HIDP_STATUS_BUTTON_NOT_PRESSED   (HIDP_ERROR_CODES(0xC, 0xF))

Definition at line 264 of file hidpi.h.

◆ HIDP_STATUS_DATA_INDEX_NOT_FOUND

#define HIDP_STATUS_DATA_INDEX_NOT_FOUND   (HIDP_ERROR_CODES(0xC, 0xD))

Definition at line 262 of file hidpi.h.

◆ HIDP_STATUS_DATA_INDEX_OUT_OF_RANGE

#define HIDP_STATUS_DATA_INDEX_OUT_OF_RANGE   (HIDP_ERROR_CODES(0xC, 0xE))

Definition at line 263 of file hidpi.h.

◆ HIDP_STATUS_I8042_TRANS_UNKNOWN

#define HIDP_STATUS_I8042_TRANS_UNKNOWN   (HIDP_ERROR_CODES(0xC, 9))

Definition at line 258 of file hidpi.h.

◆ HIDP_STATUS_I8242_TRANS_UNKNOWN

#define HIDP_STATUS_I8242_TRANS_UNKNOWN   HIDP_STATUS_I8042_TRANS_UNKNOWN

Definition at line 267 of file hidpi.h.

◆ HIDP_STATUS_INCOMPATIBLE_REPORT_ID

#define HIDP_STATUS_INCOMPATIBLE_REPORT_ID   (HIDP_ERROR_CODES(0xC, 0xA))

Definition at line 259 of file hidpi.h.

◆ HIDP_STATUS_INTERNAL_ERROR

#define HIDP_STATUS_INTERNAL_ERROR   (HIDP_ERROR_CODES(0xC, 8))

Definition at line 257 of file hidpi.h.

◆ HIDP_STATUS_INVALID_PREPARSED_DATA

#define HIDP_STATUS_INVALID_PREPARSED_DATA   (HIDP_ERROR_CODES(0xC, 1))

Definition at line 250 of file hidpi.h.

◆ HIDP_STATUS_INVALID_REPORT_LENGTH

#define HIDP_STATUS_INVALID_REPORT_LENGTH   (HIDP_ERROR_CODES(0xC, 3))

Definition at line 252 of file hidpi.h.

◆ HIDP_STATUS_INVALID_REPORT_TYPE

#define HIDP_STATUS_INVALID_REPORT_TYPE   (HIDP_ERROR_CODES(0xC, 2))

Definition at line 251 of file hidpi.h.

◆ HIDP_STATUS_IS_VALUE_ARRAY

#define HIDP_STATUS_IS_VALUE_ARRAY   (HIDP_ERROR_CODES(0xC, 0xC))

Definition at line 261 of file hidpi.h.

◆ HIDP_STATUS_NOT_IMPLEMENTED

#define HIDP_STATUS_NOT_IMPLEMENTED   (HIDP_ERROR_CODES(0xC, 0x20))

Definition at line 266 of file hidpi.h.

◆ HIDP_STATUS_NOT_VALUE_ARRAY

#define HIDP_STATUS_NOT_VALUE_ARRAY   (HIDP_ERROR_CODES(0xC, 0xB))

Definition at line 260 of file hidpi.h.

◆ HIDP_STATUS_NULL

#define HIDP_STATUS_NULL   (HIDP_ERROR_CODES(0x8, 1))

Definition at line 249 of file hidpi.h.

◆ HIDP_STATUS_REPORT_DOES_NOT_EXIST

#define HIDP_STATUS_REPORT_DOES_NOT_EXIST   (HIDP_ERROR_CODES(0xC, 0x10))

Definition at line 265 of file hidpi.h.

◆ HIDP_STATUS_SUCCESS

#define HIDP_STATUS_SUCCESS   (HIDP_ERROR_CODES(0x0, 0))

Definition at line 248 of file hidpi.h.

◆ HIDP_STATUS_USAGE_NOT_FOUND

#define HIDP_STATUS_USAGE_NOT_FOUND   (HIDP_ERROR_CODES(0xC, 4))

Definition at line 253 of file hidpi.h.

◆ HIDP_STATUS_VALUE_OUT_OF_RANGE

#define HIDP_STATUS_VALUE_OUT_OF_RANGE   (HIDP_ERROR_CODES(0xC, 5))

Definition at line 254 of file hidpi.h.

◆ HidP_UnsetButtons

#define HidP_UnsetButtons (   RT,
  UP,
  LC,
  UL1,
  UL2,
  PD,
  R,
  RL 
)    HidP_UnsetUsages(RT, UP, LC, UL1, UL2, PD, R, RL)

Definition at line 618 of file hidpi.h.

Typedef Documentation

◆ HIDD_ATTRIBUTES

◆ HIDD_CONFIGURATION

◆ HIDP_BUTTON_CAPS

◆ HIDP_CAPS

◆ HIDP_DATA

◆ HIDP_EXTENDED_ATTRIBUTES

◆ HIDP_KEYBOARD_DIRECTION

◆ HIDP_KEYBOARD_MODIFIER_STATE

◆ HIDP_LINK_COLLECTION_NODE

◆ HIDP_REPORT_TYPE

◆ HIDP_UNKNOWN_TOKEN

◆ HIDP_VALUE_CAPS

◆ PHIDD_ATTRIBUTES

◆ PHIDD_CONFIGURATION

◆ PHIDP_BUTTON_CAPS

◆ PHIDP_CAPS

◆ PHIDP_DATA

◆ PHIDP_EXTENDED_ATTRIBUTES

◆ PHIDP_INSERT_SCANCODES

typedef BOOLEAN(NTAPI * PHIDP_INSERT_SCANCODES) (_In_opt_ PVOID Context, _In_reads_bytes_(Length) PCHAR NewScanCodes, _In_ ULONG Length)

Definition at line 73 of file hidpi.h.

◆ PHIDP_KEYBOARD_MODIFIER_STATE

◆ PHIDP_LINK_COLLECTION_NODE

◆ PHIDP_PREPARSED_DATA

typedef struct _HIDP_PREPARSED_DATA* PHIDP_PREPARSED_DATA

Definition at line 39 of file hidpi.h.

◆ PHIDP_REPORT_DESCRIPTOR

Definition at line 38 of file hidpi.h.

◆ PHIDP_UNKNOWN_TOKEN

◆ PHIDP_VALUE_CAPS

◆ PUSAGE_AND_PAGE

◆ USAGE_AND_PAGE

Enumeration Type Documentation

◆ _HIDP_KEYBOARD_DIRECTION

Enumerator
HidP_Keyboard_Break 
HidP_Keyboard_Make 

Definition at line 47 of file hidpi.h.

47  {
enum _HIDP_KEYBOARD_DIRECTION HIDP_KEYBOARD_DIRECTION

◆ _HIDP_REPORT_TYPE

Enumerator
HidP_Input 
HidP_Output 
HidP_Feature 

Definition at line 237 of file hidpi.h.

237  {
238  HidP_Input,
239  HidP_Output,
enum _HIDP_REPORT_TYPE HIDP_REPORT_TYPE

Function Documentation

◆ _In_reads_()

◆ _In_reads_bytes_()

◆ _IRQL_requires_max_() [1/2]

_Must_inspect_result_ _IRQL_requires_max_ ( PASSIVE_LEVEL  )

Definition at line 64 of file Messaging.c.

75 {
76  PFLT_SERVER_PORT_OBJECT PortObject;
78 
79  /* The caller must allow at least one connection */
80  if (MaxConnections == 0)
81  {
83  }
84 
85  /* The request must be for a kernel handle */
86  if (!(ObjectAttributes->Attributes & OBJ_KERNEL_HANDLE))
87  {
89  }
90 
91  /*
92  * Get rundown protection on the target to stop the owner
93  * from unloading whilst this port object is open. It gets
94  * removed in the FltpServerPortClose callback
95  */
97  if (!NT_SUCCESS(Status))
98  {
99  return Status;
100  }
101 
102  /* Create the server port object for this filter */
106  KernelMode,
107  NULL,
108  sizeof(FLT_SERVER_PORT_OBJECT),
109  0,
110  0,
111  (PVOID *)&PortObject);
112  if (NT_SUCCESS(Status))
113  {
114  /* Zero out the struct */
115  RtlZeroMemory(PortObject, sizeof(FLT_SERVER_PORT_OBJECT));
116 
117  /* Increment the ref count on the target filter */
119 
120  /* Setup the filter port object */
121  PortObject->Filter = Filter;
122  PortObject->ConnectNotify = ConnectNotifyCallback;
124  PortObject->MessageNotify = MessageNotifyCallback;
125  PortObject->Cookie = ServerPortCookie;
126  PortObject->MaxConnections = MaxConnections;
127 
128  /* Insert the object */
129  Status = ObInsertObject(PortObject,
130  NULL,
132  0,
133  NULL,
135  if (NT_SUCCESS(Status))
136  {
137  /* Lock the connection list */
139 
140  /* Add the new port object to the connection list and increment the count */
143 
144  /* Unlock the connection list*/
146  }
147  }
148 
149  if (!NT_SUCCESS(Status))
150  {
151  /* Allow the filter to be cleaned up */
153  }
154 
155  return Status;
156 }
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES ObjectAttributes
Definition: conport.c:35
#define STATUS_INVALID_PARAMETER
Definition: udferr_usr.h:135
_Must_inspect_result_ _Outptr_ PFLT_PORT * ServerPort
Definition: fltkernel.h:1873
PFLT_CONNECT_NOTIFY ConnectNotify
Definition: fltmgrint.h:191
VOID FLTAPI FltObjectDereference(_Inout_ PVOID Object)
Definition: Object.c:53
LONG NTSTATUS
Definition: precomp.h:26
#define InsertTailList(ListHead, Entry)
VOID FASTCALL ExReleaseFastMutex(IN PFAST_MUTEX FastMutex)
Definition: fmutex.c:31
ULONG FltpObjectPointerReference(_In_ PFLT_OBJECT Object)
Definition: Object.c:322
LIST_ENTRY mList
Definition: fltmgrint.h:56
_Must_inspect_result_ _In_opt_ PFLT_FILTER Filter
Definition: fltkernel.h:1802
#define FILE_READ_DATA
Definition: nt_native.h:628
smooth NULL
Definition: ftsmooth.c:416
NTSTATUS NTAPI ObCreateObject(IN KPROCESSOR_MODE ProbeMode OPTIONAL, IN POBJECT_TYPE Type, IN POBJECT_ATTRIBUTES ObjectAttributes OPTIONAL, IN KPROCESSOR_MODE AccessMode, IN OUT PVOID ParseContext OPTIONAL, IN ULONG ObjectSize, IN ULONG PagedPoolCharge OPTIONAL, IN ULONG NonPagedPoolCharge OPTIONAL, OUT PVOID *Object)
Definition: oblife.c:952
POBJECT_TYPE ServerPortObjectType
Definition: Messaging.c:24
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:32
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID _In_ PFLT_CONNECT_NOTIFY _In_ PFLT_DISCONNECT_NOTIFY DisconnectNotifyCallback
Definition: fltkernel.h:1873
PVOID *typedef PHANDLE
Definition: ntsecpkg.h:414
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID _In_ PFLT_CONNECT_NOTIFY ConnectNotifyCallback
Definition: fltkernel.h:1873
Status
Definition: gdiplustypes.h:24
NTSTATUS NTAPI ObInsertObject(IN PVOID Object, IN PACCESS_STATE AccessState OPTIONAL, IN ACCESS_MASK DesiredAccess, IN ULONG ObjectPointerBias, OUT PVOID *NewObject OPTIONAL, OUT PHANDLE Handle)
Definition: obhandle.c:2932
#define STANDARD_RIGHTS_ALL
Definition: nt_native.h:69
VOID FASTCALL ExAcquireFastMutex(IN PFAST_MUTEX FastMutex)
Definition: fmutex.c:23
NTSTATUS FLTAPI FltObjectReference(_Inout_ PVOID Object)
Definition: Object.c:41
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID ServerPortCookie
Definition: fltkernel.h:1873
FAST_MUTEX mLock
Definition: fltmgrint.h:55
PFLT_MESSAGE_NOTIFY MessageNotify
Definition: fltmgrint.h:193
#define RtlZeroMemory(Destination, Length)
Definition: typedefs.h:261
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID _In_ PFLT_CONNECT_NOTIFY _In_ PFLT_DISCONNECT_NOTIFY _In_opt_ PFLT_MESSAGE_NOTIFY _In_ LONG MaxConnections
Definition: fltkernel.h:1873
PFLT_DISCONNECT_NOTIFY DisconnectNotify
Definition: fltmgrint.h:192
#define OBJ_KERNEL_HANDLE
Definition: winternl.h:231
_Must_inspect_result_ _Outptr_ PFLT_PORT _In_ POBJECT_ATTRIBUTES _In_opt_ PVOID _In_ PFLT_CONNECT_NOTIFY _In_ PFLT_DISCONNECT_NOTIFY _In_opt_ PFLT_MESSAGE_NOTIFY MessageNotifyCallback
Definition: fltkernel.h:1873
FLT_MUTEX_LIST_HEAD ConnectionList
Definition: fltmgrint.h:121

◆ _IRQL_requires_max_() [2/2]

_Must_inspect_result_ _IRQL_requires_max_ ( DISPATCH_LEVEL  )

Definition at line 30 of file rmap.c.

36 {
38 }
#define TAG_RMAP
Definition: tag.h:133
#define P(row, col)
#define ExFreePoolWithTag(_P, _T)
Definition: module.h:1099

◆ _Out_writes_()

◆ _Out_writes_bytes_()

◆ HidP_GetScaledUsageValue()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetScaledUsageValue ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_Out_ PLONG  UsageValue,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_GetUsages()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsages ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_Out_writes_to_ *, *UsageLength USAGE UsageList,
_Inout_ ULONG UsageLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_Out_writes_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_GetUsageValue()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsageValue ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_Out_ PULONG  UsageValue,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_GetUsageValueArray()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_GetUsageValueArray ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_Inout_updates_bytes_(UsageValueByteLength) PCHAR  UsageValue,
_In_ USHORT  UsageValueByteLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetData()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetData ( _In_ HIDP_REPORT_TYPE  ReportType,
_Inout_updates_to_ *, *DataLength PHIDP_DATA  DataList,
_Inout_ PULONG  DataLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetScaledUsageValue()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetScaledUsageValue ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_In_ LONG  UsageValue,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_Inout_updates_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetUsages()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsages ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_Inout_updates_to_ *, *UsageLength PUSAGE  UsageList,
_Inout_ PULONG  UsageLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetUsageValue()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsageValue ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_In_ ULONG  UsageValue,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_Inout_updates_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_SetUsageValueArray()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_SetUsageValueArray ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_ USHORT  LinkCollection,
_In_ USAGE  Usage,
_In_reads_bytes_(UsageValueByteLength) PCHAR  UsageValue,
_In_ USHORT  UsageValueByteLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_Inout_updates_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

◆ HidP_TranslateUsageAndPagesToI8042ScanCodes()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_TranslateUsageAndPagesToI8042ScanCodes ( _In_reads_(UsageListLength) PUSAGE_AND_PAGE  ChangedUsageList,
_In_ ULONG  UsageListLength,
_In_ HIDP_KEYBOARD_DIRECTION  KeyAction,
_Inout_ PHIDP_KEYBOARD_MODIFIER_STATE  ModifierState,
_In_ PHIDP_INSERT_SCANCODES  InsertCodesProcedure,
_In_opt_ PVOID  InsertCodesContext 
)

Referenced by KbdHid_ReadCompletion().

◆ HidP_TranslateUsagesToI8042ScanCodes()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_TranslateUsagesToI8042ScanCodes ( _In_reads_(UsageListLength) PUSAGE  ChangedUsageList,
_In_ ULONG  UsageListLength,
_In_ HIDP_KEYBOARD_DIRECTION  KeyAction,
_Inout_ PHIDP_KEYBOARD_MODIFIER_STATE  ModifierState,
_In_ PHIDP_INSERT_SCANCODES  InsertCodesProcedure,
_In_opt_ PVOID  InsertCodesContext 
)

◆ HidP_UnsetUsages()

_Must_inspect_result_ HIDAPI NTSTATUS NTAPI HidP_UnsetUsages ( _In_ HIDP_REPORT_TYPE  ReportType,
_In_ USAGE  UsagePage,
_In_opt_ USHORT  LinkCollection,
_Inout_updates_to_ *, *UsageLength PUSAGE  UsageList,
_Inout_ PULONG  UsageLength,
_In_ PHIDP_PREPARSED_DATA  PreparsedData,
_In_reads_bytes_(ReportLength) PCHAR  Report,
_In_ ULONG  ReportLength 
)

Variable Documentation

◆ Attributes

Definition at line 348 of file hidpi.h.

Referenced by $include(), access_dirT(), BaseFormatObjectAttributes(), BaseSrvIsVdmAllowed(), BlImgAllocateImageBuffer(), BlMmAllocatePhysicalPages(), ChanMgrCreateChannel(), ChannelCreate(), CmpDoOpen(), CmpParseKey(), ConDrvGetConsoleScreenBufferInfo(), ConDrvSetConsoleTextAttribute(), ConsoleEfiTextGetColorBackground(), ConsoleEfiTextGetColorForeground(), CreateDesktopW(), CreateFileMappingW(), CreateMailslotW(), CreateNamedPipeW(), CreatePipe(), CreateRegistryKeyHandle(), DosChangeDirectory(), DosCreateDevice(), DosCreateDeviceEx(), DosCreateFile(), DosCreateFileEx(), DosInt21h(), DriverEntry(), EfiGetVariable(), ExpWinStaObjectParse(), FatConstructDirent(), CCabinet::GetAttributesOnFile(), GetDllList(), HidD_GetAttributes(), HidInternalDeviceControl(), Initialize(), IntDesktopObjectParse(), IopParseDevice(), IopParseFile(), KbdHid_InternalDeviceControl(), main(), MmCreateVirtualMappingUnsafe(), MmNotPresentFaultCachePage(), MmNotPresentFaultSectionView(), MmPapAllocatePagesInRange(), MmPapAllocatePhysicalPagesInRange(), MmPapPageAllocatorExtend(), MmSetPageProtect(), MouHid_InternalDeviceControl(), NetGroupAdd(), NtOpenProcess(), NtOpenThread(), ObpLookupEntryDirectory(), ObpLookupObjectName(), ObpReferenceProcessObjectByHandle(), ObpValidateAttributes(), ObReferenceObjectByHandle(), ObReferenceObjectByName(), OpenClassesRootKey(), OpenCurrentConfigKey(), OpenLocalMachineKey(), OpenRegistryKey(), OpenRegistryKeyHandle(), OpenUsersKey(), PrintPrettyName(), ProtectBootIni(), ProtectToPTE(), RegCreateKeyExW(), RegOpenKeyExW(), RtlAddRange(), RtlCreateUserProcess(), RtlpMapFile(), RxSetBasicInfo(), SamAddMemberToGroup(), SamGetMembersInGroup(), SampAddGroupMembershipToUser(), SamrAddMemberToGroup(), SamrSetMemberAttributesOfGroup(), SamSetMemberAttributesOfGroup(), SepCreateToken(), SetAttributesOnFile(), START_TEST(), StartThread(), test_pack_LUID_AND_ATTRIBUTES(), test_pack_SID_AND_ATTRIBUTES(), UnprotectBootIni(), USBH_IoctlGetNodeConnectionAttributes(), VfatCreateFile(), and VfatSetBasicInformation().

◆ ButtonCaps

◆ ButtonCapsLength

◆ ButtonList

◆ Capabilities

Definition at line 324 of file hidpi.h.

◆ DataIndex

Definition at line 346 of file hidpi.h.

Referenced by WriteMidiUartMulti().

◆ DataLength

Definition at line 333 of file hidpi.h.

Referenced by AcpiExWriteDataToField(), AcpiExWriteSerialBus(), AcpiRegQueryValue(), AddUDPHeaderIPv4(), ApphelpCacheParse(), BiConvertRegistryDataToElement(), CdAddInitialAllocation(), CmpFreeValueData(), CmSetValueKey(), compat_FsRtlValidateReparsePointBuffer(), CsrClientCallServer(), DECLARE_INTERFACE_(), CWebService::DoRequest(), EnumerateValueTest(), FltpReadRegistryValue(), FormatOutput(), FsRtlAddToTunnelCache(), FsRtlFindInTunnelCache(), FsRtlNotifyCompleteIrp(), FsRtlNotifyCompleteIrpList(), FsRtlNotifyFilterReportChange(), FsRtlNotifyUpdateBuffer(), FsRtlValidateReparsePointBuffer(), HandleDataIntersection(), HandlePhysicalConnection(), HwReadWriteData(), IKsControl_fnKsEvent(), IKsControl_fnKsMethod(), IKsControl_fnKsProperty(), IniCacheAddKey(), IopQueryBusDescription(), KdReceivePacket(), CKsNode::KsEvent(), CInputPin::KsEvent(), COutputPin::KsEvent(), CKsProxy::KsEvent(), KsFastMethodHandler(), KsFastPropertyHandler(), CKsNode::KsMethod(), CInputPin::KsMethod(), COutputPin::KsMethod(), CKsProxy::KsMethod(), KspCacheAddData(), KspHandleDataIntersection(), CKsNode::KsProperty(), CInputPin::KsProperty(), COutputPin::KsProperty(), CKsProxy::KsProperty(), LsapRegEnumerateValue(), LsapRegQueryValue(), LsapRegSetValue(), LsarEnumerateAccounts(), main(), NpQueryClientProcess(), NpReadDataQueue(), ProcessorSetFriendlyName(), RegEnumValueA(), RegQueryValueExA(), RepGetValueData(), RtlpNtQueryValueKey(), RtlpNtSetValueKey(), SampGetMembersInAlias(), SampRegEnumerateValue(), SampRegQueryValue(), SampRegSetValue(), SamrEnumerateAliasesInDomain(), SamrEnumerateDomainsInSamServer(), SamrEnumerateGroupsInDomain(), SamrEnumerateUsersInDomain(), SamrGetAliasMembership(), SamrLookupIdsInDomain(), SamrLookupNamesInDomain(), ScmCheckDriver(), ScmGetDriverStatus(), SepRegQueryHelper(), SmLookupSubsystem(), SmQueryInformation(), START_TEST(), test1(), test2(), test3(), test6(), test9(), UDPv4ChecksumCalculate(), UpdateMftMirror(), USBD_GetPdoRegistryParameter(), WriteMidiUartMulti(), WTSSetUserConfigA(), and WTSSetUserConfigW().

◆ DataList

◆ LengthAttributes

◆ LinkCollection

◆ LinkCollectionNodesLength

_Must_inspect_result_ _Inout_ PULONG LinkCollectionNodesLength

Definition at line 358 of file hidpi.h.

◆ PreparsedData

◆ ReportID

◆ ReportLength

◆ Usage

◆ UsageLength

◆ UsageListLength

◆ UsagePage

◆ ValueCaps

◆ ValueCapsLength