[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
Int 7C Fn 0007  - Sk-upps Data Link Interface API - Register Protocol      [N]

   AX = 0007h
   ES:BX -> Protocol Control Block (see below)

Return: AX = completion code (see AX=0001h)
Program: SK-UPPS is the Schneider & Koch Universal Portable Protocol Stack,
     which provides an API on top of its Data Link Interface, allowing the
     use of any of several network transport layers

See Also: AX=0008h,AX=000Bh

Format of Protocol Control Block (PCB):
Offset Size    Description
 00h   WORD    protocol type (high-low)
 02h   WORD    protocol mode (see below)
 04h   DWORD   -> Receive Upcall routine
 08h   DWORD   -> Transmit Upcall routine
 0Ch   DWORD   -> Event Upcall routine
 10h   DWORD   -> ASCIZ protocol name (zero if none)
 14h   WORD    protocol ID will be returned here (always non-zero)

Bitfields for protocol mode:
 bit 0 promiscuous mode; protocol receives all frames regardless of their
     destination (PROTOCOL TYPE must be FFFFh)
 bit 1 if set, protocol's Event Upcall will be called on entry and exit of the
     DLI's Interrupt Service Routine (see event codes below)
 bit 2 DLI 2.2+ hook mode; protocol receives all directed frames destined for
     this station (PROTOCOL TYPE must be FFFFh)
 bit 3 DLI 2.3+ receive error frames (only valid in promiscuous mode (bit 0))
 bit 4-5 DLI 2.5+ frame type:
   00 Ethernet II; specify type code in PROTOCOL TYPE field (high-low)
   01 IEEE 802.2; specify Service Access Point (SAP) in MSB
       (offset 0) of PROCOTOL TYPE field; LSB must be zero
   10 IEEE 802.2 with SNAP header; specify type code in PROTOCOL TYPE
       field (high-low)
   11 reserved (currently unused)
 bit 6 DLI 2.5+ if set, protocol's Event Upcall will be called with event code
     EV_BUFFER_WANTED, when DLI runs out of Mbufs
 bit 7 DLI 2.7+ chain mode; if set, client allows the specified frame type to
     be shared with other clients
 bit 8 DLI 2.8+ receive non-LLC frames rather than LLC frames
 bit 9 DLI 2.8+ receive all multicast frames (see also AX=0009h)
 bit 10-15 reserved (currently unused; must be zero)

Notes: If PROTOCOL TYPE is FFFFh and neither the "promiscuous" nor the "hook"
     mode bit is set, the protocol receives all frames that did not match
     any registered frame type (demultiplexor mode).
   Protocols using "promiscuous", "hook" or "chain" mode should always
     return from the Receive Upcall with the received Mbuf in ES:BX and the
     Carry Flag set. The DLI will then pass the Mbuf to the FEED BACK
     BUFFER function (see AX=000Fh).
   Some DLIs do not support all or even any of the "promiscuous",
     "receive non-LLC" and "receive all multicasts" mode bits.

Receive Upcall called with:
 ES:BX -> Mbuf
 AX = receive status (see below; also stored in Mbuf's RECEIVE STATUS field)
 interrupts disabled

Bitfields for receive status (reserved bits currently unused and always zero):
 bit 0-2 reserved
 bit 3 frame check sequence (FCS) error
 bit 4 overflow (frame too long)
 bit 5 framing error
 bit 6 reserved
 bit 7 non-LLC frame (see bit 8 of PCB's protocol mode field)
 bit 8-15 reserved

Notes: The protocol's Receive Upcall routine will be called whenever a frame
     matching the specified frame type is received. A received frame is
     passed to the protocol in the Mbuf's DATA area at OFFSET and its size
     is LENGTH bytes.
   The receive status passed to the Receive Upcall in register AL is
     always zero, except for protocols using "non-LLC" mode (bit 8 of PCB's
     protocol mode field) or "promiscuous" mode together with "receive
     error frames" (bits 0 & 3).
   Upcalls are FAR routines and must return with a RET FAR. If the Carry
     Flag is set on return from a Receive or Transmit Upcall, then ES:BX
     must point to an Mbuf, which the DLI will then pass to the RELEASE
     BUFFER function (see AX=0005h). See also notes for PROTOCOL MODE.

Event Upcall called with:
 AX = event code (see below)

Note:  All Event Upcalls may be ignored by the protocol.

Event codes found in register AX on Event Upcall:
 00h EV_BUFFER_AVAILABLE  client may now call REQUEST BUFFER (AX=0004h)
 01h EV_ISR_START  start of Interrupt Service Routine
 02h EV_ISR_END        end of ISR (see bit 1 in PCB's protocol mode field)
 03h EV_BUFFER_WANTED  DLI temporarily out of Mbufs
 04h EV_NETWORK_STATUS DLI 2.8+ network status (DX=status; see below)
 05h EV_IO_CONTROL DLI 2.8+ I/O control (DX=subfunction; see AX=0016h)

Bitfields for EV_NETWORK_STATUS in register DX:
   Token-Ring      FDDI
 bit 15 SIGNAL_LOSS        SIGNAL_LOSS
 bit 14 HARD_ERROR     HARD_ERROR
 bit 13 SOFT_ERROR     SOFT_ERROR
 bit 12 TRANSMIT_BEACON        TRANSMIT_BEACON
 bit 11 LOBE_WIRE_FAULT        PATH_TEST_FAILED
 bit 10 AUTO_REMOVAL       SELF_TEST_REQUIRED
 bit 9 reserved        reserved
 bit 8 REMOVE_RECEIVED     REMOTE_DISCONNECT
 bit 7 COUNTER_OVERFLOW    reserved
 bit 6 SINGLE_STATION      DUPLICATE_ADDRESS
 bit 5 RING_RECOVERY       NO_RING_OP_STATUS
 bit 4 reserved        VERSION_MISMATCH
 bit 3 reserved        STUCK_BYPASS
 bit 2 reserved        FDDI_EVENT
 bit 1 reserved        RING_OP_CHANGE
 bit 0 reserved        reserved

Note:  EV_NETWORK_STATUS is not supported on Ethernet

This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson