Skip to content

Latest commit

 

History

History
119 lines (74 loc) · 4.41 KB

nc-video-pdriver_io_port_uchar.md

File metadata and controls

119 lines (74 loc) · 4.41 KB
UID title description old-location tech.root ms.date keywords ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames f1_keywords topic_type api_type api_location api_name
NC:video.PDRIVER_IO_PORT_UCHAR
PDRIVER_IO_PORT_UCHAR (video.h)
SvgaHwIoPortUchar traps an I/O port to which a full-screen MS-DOS application in an x86-based machine is sending UCHAR-sized data.
display\svgahwioportuchar.htm
display
05/10/2018
PDRIVER_IO_PORT_UCHAR callback function
PDRIVER_IO_PORT_UCHAR, PDRIVER_IO_PORT_UCHAR callback, SvgaHwIoPortUchar, SvgaHwIoPortUchar callback function [Display Devices], VideoMiniport_Functions_d926584b-82e3-463e-ad50-b04d065a1d9d.xml, display.svgahwioportuchar, video/SvgaHwIoPortUchar
video.h
Video.h
Desktop
Windows
PDRIVER_IO_PORT_UCHAR
video/PDRIVER_IO_PORT_UCHAR
APIRef
kbSyntax
UserDefined
video.h
PDRIVER_IO_PORT_UCHAR

PDRIVER_IO_PORT_UCHAR callback function

-description

SvgaHwIoPortUchar traps an I/O port to which a full-screen MS-DOS application in an x86-based machine is sending UCHAR-sized data.

-parameters

-param Context

Specifies the miniport driver-defined context value that was set in the EmulatorAccessEntriesContext member of VIDEO_PORT_CONFIG_INFO.

-param Port

Specifies the mapped I/O port to be trapped.

-param AccessMode

Specifies the type of access to be trapped, which can be one or a combination (ORed) of the following values:

EMULATOR_READ_ACCESS
EMULATOR_WRITE_ACCESS

-param Data

Pointer to the byte to be transferred.

-returns

SvgaHwIoPortUchar returns the final status of the operation.

-remarks

Only miniport drivers of VGA-compatible SVGA adapters have SvgaHwIoPortXxx functions. (See SVGA Functions.)

SvgaHwIoPortUchar intercepts any byte access attempted by a full-screen MS-DOS application issuing either or both of the instructions OUT DX, AL and IN AL, DX.

If the miniport driver enables the Port for direct access by calling VideoPortSetTrappedEmulatorPorts, its SvgaHwIoPortUchar function will not be called. Such an application then will have direct access to the Port, unless the miniport driver disables the Port with another call to VideoPortSetTrappedEmulatorPorts.

If one or more application-issued x86 IN or OUT instructions might affect the state of the VGA-compatible adapter sequencer register, miscellaneous output register, or any adapter-specific register and, thereby, cause the machine to hang, the miniport driver must not enable the port for direct access by calling VideoPortSetTrappedEmulatorPorts.

SvgaHwIoPortUchar must buffer subsequent instructions from the application to the Port and check that none can hang the machine. If the application issues any sequence of instructions that might hang the machine, SvgaHwIoPortUchar must discard the buffered instructions. Otherwise, it should output them, a UCHAR at a time, to the specified, mapped I/O port.

SvgaHwIoPortUchar should be made pageable.

-see-also

EMULATOR_ACCESS_ENTRY

SVGA Functions

SvgaHwIoPortUcharString

VIDEO_ACCESS_RANGE

VIDEO_PORT_CONFIG_INFO

VideoPortGetDeviceBase

VideoPortSetTrappedEmulatorPorts