36 (OutputBufferSize) ? *OutputBufferSize : 0,
42 WARN_(SERMOUSE,
"IoBuildDeviceIoControlRequest() failed\n");
50 INFO_(SERMOUSE,
"Operation pending\n");
77 ULONG ButtonsDifference;
87 TRACE_(SERMOUSE,
"SermouseDeviceWorker() called\n");
109 &BaudRate,
sizeof(BaudRate),
NULL,
NULL);
124 &Timeouts,
sizeof(Timeouts),
NULL,
NULL);
155 INFO_(SERMOUSE,
"No memory actually, trying again\n");
174 INFO_(SERMOUSE,
"ReceivedByte 0x%02x\n", ReceivedByte);
177 if ((ReceivedByte & 0x40) == 0x40)
197 Input->LastX = (
signed char)(PacketBuffer[1] | ((PacketBuffer[0] & 0x03) << 6));
198 Input->LastY = (
signed char)(PacketBuffer[2] | ((PacketBuffer[0] & 0x0c) << 4));
223 Input->ButtonFlags = 0;
226 if (ButtonsDifference != 0)
#define InterlockedIncrement
#define NT_SUCCESS(StatCode)
#define KeRaiseIrql(irql, oldIrql)
#define KeWaitForSingleObject(pEvt, foo, a, b, c)
#define KeInitializeEvent(pEvt, foo, foo2)
#define KeLowerIrql(oldIrql)
VOID NTAPI KeClearEvent(IN PKEVENT Event)
IN PVCB IN VBO IN ULONG OUT PBCB OUT PVOID IN BOOLEAN IN BOOLEAN Zero
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
VOID(STDAPICALLTYPE * PSERVICE_CALLBACK_ROUTINE)(IN PVOID NormalContext, IN PVOID SystemArgument1, IN PVOID SystemArgument2, IN OUT PVOID SystemArgument3)
#define KeStallExecutionProcessor(MicroSeconds)
__in UCHAR __in POWER_STATE __in_opt PVOID __in PIO_STATUS_BLOCK IoStatus
#define MOUSE_LEFT_BUTTON_DOWN
#define MOUSE_LEFT_BUTTON_UP
#define MOUSE_MIDDLE_BUTTON_DOWN
#define MOUSE_RIGHT_BUTTON_UP
#define MOUSE_MIDDLE_BUTTON_UP
#define MOUSE_RIGHT_BUTTON_DOWN
#define IOCTL_SERIAL_SET_LINE_CONTROL
#define IOCTL_SERIAL_SET_TIMEOUTS
#define IOCTL_SERIAL_SET_FIFO_CONTROL
#define IOCTL_SERIAL_SET_BAUD_RATE
PIRP NTAPI IoBuildSynchronousFsdRequest(IN ULONG MajorFunction, IN PDEVICE_OBJECT DeviceObject, IN PVOID Buffer, IN ULONG Length, IN PLARGE_INTEGER StartingOffset, IN PKEVENT Event, IN PIO_STATUS_BLOCK IoStatusBlock)
PIRP NTAPI IoBuildDeviceIoControlRequest(IN ULONG IoControlCode, IN PDEVICE_OBJECT DeviceObject, IN PVOID InputBuffer, IN ULONG InputBufferLength, IN PVOID OutputBuffer, IN ULONG OutputBufferLength, IN BOOLEAN InternalDeviceIoControl, IN PKEVENT Event, IN PIO_STATUS_BLOCK IoStatusBlock)
NTSTATUS NTAPI PsTerminateSystemThread(IN NTSTATUS ExitStatus)
static NTSTATUS SermouseDeviceIoControl(IN PDEVICE_OBJECT DeviceObject, IN ULONG CtlCode, IN PVOID InputBuffer OPTIONAL, IN ULONG InputBufferSize, IN OUT PVOID OutputBuffer OPTIONAL, IN OUT PULONG OutputBufferSize)
VOID NTAPI SermouseDeviceWorker(PVOID Context)
#define MIDDLE_BUTTON_SHIFT
#define RIGHT_BUTTON_MASK
struct _SERMOUSE_DEVICE_EXTENSION * PSERMOUSE_DEVICE_EXTENSION
#define MOUSE_BUTTON_LEFT
#define MIDDLE_BUTTON_MASK
#define PACKET_BUFFER_SIZE
#define RIGHT_BUTTON_SHIFT
#define MOUSE_BUTTON_MIDDLE
#define MOUSE_BUTTON_RIGHT
#define LEFT_BUTTON_SHIFT
PULONG MinorVersion OPTIONAL
PDEVICE_OBJECT ClassDeviceObject
ULONG WriteTotalTimeoutMultiplier
ULONG ReadTotalTimeoutConstant
ULONG WriteTotalTimeoutConstant
ULONG ReadTotalTimeoutMultiplier
ULONG ReadIntervalTimeout
KEVENT StopWorkerThreadEvent
PDEVICE_OBJECT LowerDevice
ULONG PacketBufferPosition
MOUSE_ATTRIBUTES AttributesInformation
UCHAR PacketBuffer[PACKET_BUFFER_SIZE]
MOUSE_INPUT_DATA MouseInputData[2]
#define RtlZeroMemory(Destination, Length)
#define STATUS_INSUFFICIENT_RESOURCES
_In_ PDEVICE_OBJECT DeviceObject
_Must_inspect_result_ _In_ WDFDEVICE _In_ PIRP _In_ WDFQUEUE Queue
_Must_inspect_result_ _In_ WDFIOTARGET _In_opt_ WDFREQUEST _In_opt_ PWDF_MEMORY_DESCRIPTOR OutputBuffer
_Must_inspect_result_ _In_ WDFIOTARGET _In_opt_ WDFREQUEST _In_opt_ PWDF_MEMORY_DESCRIPTOR InputBuffer
_Requires_lock_held_ Interrupt _Releases_lock_ Interrupt _In_ _IRQL_restores_ KIRQL OldIrql