Freigeben über


NDISUIO_OPEN_CONTEXT (Windows CE 5.0)

Send Feedback

This structure represents the network device object when opened. It is allocated on processing ProtocolBindAdapter from NDIS and freed when all references to it are gone.

typedef struct _NDISUIO_OPEN_CONTEXT {LIST_ENTRYLink;ULONGFlags;ULONG RefCount;NUIO_LOCK Lock;PFILE_OBJECT pFileObject;NDIS_HANDLE BindingHandle;NDIS_HANDLESendPacketPool;NDIS_HANDLE SendBufferPool;NDIS_HANDLERecvPacketPool;NDIS_HANDLE RecvBufferPool;ULONG MacOptions;ULONG MaxFrameSize;LIST_ENTRY PendedWrites;ULONG PendedSendCount;#ifndef UNDER_CELIST_ENTRY PendedReads;ULONG PendedReadCount;#elseNDIS_EVENT ReadEvent;BOOL bBlockingRead;DWORD dwReadTimeOut;#endifLIST_ENTRY RecvPktQueue;ULONG RecvPktCount;NET_DEVICE_POWER_STATE PowerState;NDIS_STRING DeviceName;NDIS_STRING DeviceDescr;NDIS_STATUS BindStatus;NUIO_EVENT BindEvent;#ifndef UNDER_CEBOOLEAN bRunningOnWin9x;#endif#ifdef UNDER_CEUSHORT EthType;#endifULONG oc_sig;} NDISUIO_OPEN_CONTEXT, *PNDISUIO_OPEN_CONTEXT;

Members

  • Link
    Link to the global list.
  • Flags
    State information. The following table shows the values for Flags.
    Flag Value
    NUIOO_BIND_IDLE 0x00000000
    NUIOO_BIND_OPENING 0x00000001
    NUIOO_BIND_FAILED 0x00000002
    NUIOO_BIND_ACTIVE 0x00000004
    NUIOO_BIND_CLOSING 0x00000008
    NUIOO_BIND_FLAGS 0x0000000F
    NUIOO_OPEN_IDLE 0x00000000
    NUIOO_OPEN_ACTIVE 0x00000010
    NUIOO_OPEN_FLAGS 0x000000F0
    NUIOO_RESET_IN_PROGRESS 0x00000100
    NUIOO_NOT_RESETTING 0x00000000
    NUIOO_RESET_FLAGS 0x00000100
    NUIOO_MEDIA_CONNECTED 0x00000000
    NUIOO_MEDIA_DISCONNECTED 0x00000200
    NUIOO_MEDIA_FLAGS 0x00000200
    NUIOO_READ_SERVICING 0x00100000
    NUIOO_READ_FLAGS 0x00100000
    NUIOO_UNBIND_RECEIVED 0x10000000
    NUIOO_UNBIND_FLAGS 0x10000000
  • RefCount
    Count of pended read IRPs, queued or incomplete write IRPs, and existence of binding.
  • Lock
    Indicates an NDISUIO lock.
  • pFileObject
    Pointer to the file assignment for the open device.
  • BindingHandle
    File handle for NDIS binding.
  • SendPacketPool
    File handle for the send packet pool.
  • SendBufferPool
    File handle for the send buffer.
  • RecvPacketPool
    File handle for the received packet pool.
  • RecvBufferPool
    File handle for the receive buffer.
  • MacOptions
    Media access options.
  • MaxFrameSize
    Maximum frame size permitted, in bytes.
  • PendedWrites
    Pended write IRP queue.
  • PendedSendCount
    Number of pended writes.
  • PendedReads
    Pended read IRP queue.
  • PendedReadCount
    Number of pended reads.
  • ReadEvent
    Event to trigger when bBlockingRead is TRUE.
  • bBlockingRead
    Boolean value indicating that ReadEvent has occurred.
  • dwReadTimeOut
    Amount of time to wait for incoming reads.
  • RecvPktQueue
    Not used.
  • RecvPktCount
    Not used.
  • PowerState
    Indication of the device power state.
  • DeviceName
    Name of the device used in NdisOpenAdapter.
  • DeviceDescr
    Friendly name of the DeviceName adapter.
  • BindStatus
    Existence of the bind status for the device designated by NdisOpenAdapter or NdisCloseAdapter.
  • BindEvent
    Notification event that adapter binding or unbinding is complete.
  • bRunningOnWin9x
    Not used.
  • EthType
    Ethernet frame type of interest, which can be tuned for each adapter context. The following table shows the valid EthType values.
    EthType Value
    NUIO_ETH_TYPE 0x8001
    NUIO_8021P_TAG_TYPE 0x0081
  • oc_sig
    Validation signature.

Remarks

While an NDIS binding exists, read I/O request packets (IRPs) are queued on this structure and processed when packets are received. If data arrives in the absence of a pended read, NDISUIO saves the contents of the latest packet received. If no binding exists, the read packet fails.

NDISUIO uses write IRPs to send data. Each write IRP maps to a single NDIS packet. Packet send-completion is mapped to write IRP completion. If no active binding exists, write IRPs fail.

Requirements

OS Versions: Windows CE .NET 4.0 and later.
Header: Nuiouser.h.

See Also

ProtocolBindAdapter | NdisOpenAdapter | NdisCloseAdapter

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.