Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP DLPI Programmer's Guide: HP-UX 11i v2 > Chapter 2 DLPI Primitives

Local Management Primitives

» 

Technical documentation

Complete book in PDF
» Feedback
Content starts here

 » Table of Contents

 » Glossary

 » Index

This section describes the local management service primitives. These primitives support the information reporting, Attach, and Bind. Once a stream has been opened by a DLS user, these primitives initialize the stream, preparing it for use.

PPA Initialization and De-initialization

The PPA associated with each stream must be initialized before the DLS provider can transfer data over the medium. The initialization and de-initialization of the PPA is a network management issue, but DLPI must address the issue because of the impact such actions have on a DLS user. More specifically, DLPI requires the DLS provider to initialize the PPA associated with a stream at some point before it completes the processing of the DL_BIND_REQ. Guidelines for initialization and de-initialization of a PPA by a DLS provider are presented here.

A DLS provider may initialize a PPA using one of the following methods:

  • Preinitialized by some network management mechanism before the DL_BIND_REQ is received

  • Automatic initialization on receipt of a DL_BIND_REQ or DL_ATTACH_REQ

A specific DLS provider may support either of these methods, or possibly combination of the two, but the method implemented has no impact on the DLS user. From the DLS user’s viewpoint, the PPA is guaranteed to be initialized on receipt of a DL_BIND_ACK. For automatic initialization, it implies that the DL_BIND_ACK may not be issued until the initialization is complete.

If pre-initialization is not performed and/or automatic initialization fails, the DLS provider will fail the DL_BIND_REQ. Two errors, DL_INITFAILED and DL_NOTINIT, may be returned in the DL_ERROR_ACK response to a DL_BIND_REQ if PPA initialization fails.

DL_INITFAILED is returned when a DLS provider supports automatic PPA initialization, but the initialization attempt failed. DL_NOTINIT is returned when the DLS provider requires pre-initialization, but the PPA is not initialized before the DL_BIND_REQ is received.

A DLS provider may handle PPA de-initialization using one of the following methods:

  • Automatic de-initialization upon receipt of the final DL_DETACH_REQ (for style 2 providers), DL_UNBIND_REQ (for style 1 providers), or upon closing of the last stream associated with the PPA

  • Automatic de-initialization after expiration of a timer following the last DL_DETACH_REQ, DL_UNBIND_REQ, or close as appropriate

  • No automatic de-initialization; administrative intervention is required to de-initialize the PPA at some point after it is no longer accessed

A specific DLS provider may support any of these methods, or possibly combination of them, but the method implemented has no impact on the DLS user. From the DLS user’s viewpoint, the PPA is guaranteed to be initialized and available for transmission until it closes or unbinds the stream associated with the PPA.

DLS provider specific addendum documentation should describe the method chosen for PPA initialization and de-initialization.

DL_HP_PPA_REQ

This primitive is used to obtain a list of all the valid PPAs currently installed in the system.

This message consists of one M_PCPROTO message block which contains the following structure.

Format

typedef struct {
u_long     dl_primitive;
} dl_hp_ppa_req_t;

Parameters

dl_primitive

  • DL_HP_PPA_REQ

State

The message is valid in any State in which a local acknowledgment is not pending, as described in Appendix B, Allowable Sequence of DLPI Primitives, of the DLPI 2.0 specification.

New State

The resulting state is unchanged.

Response

The DLPI driver responds to this request with a DL_HP_PPA_ACK.

DL_HP_PPA_ACK

This primitive is sent in response to a DL_HP_PPA_REQ; it conveys information on each valid PPA currently installed in the system.

This message consists of one M_PCPROTO message block, which contains the following structure and information:

Format

typedef struct {
u_long    dl_primitive;
u_long    dl_length;
    u_long     dl_count;
u_long    dl_offset;
} dl_hp_ppa_ack_t;

Parameters

dl_primitive

  • DL_HP_PPA_ACK

dl_length

  • length of the data area following the DL_HP_PPA_ACK primitive. The data area is formatted as one or more dl_hp_ppa_info_t structures.

dl_count

  • number of PPAs in the list.

dl_offset

  • offset from the beginning of the M_PCPROTO block where the dl_hp_ppa_info_t information begins.

    /* info area in DL_HP_PPA_ACK */
    typedef struct {
            u_long  dl_next_offset;
    u_long dl_ppa;
    u_char  dl_hw_path[100];
            u_long dl_mac_type;
    u_char dl_phys_addr[20];
    u_long  dl_addr_length;
    u_long dl_mjr_num;
    u_char  dl_name[64]
            u_long  dl_instance_num
            u_long  dl_mtu;
            u_long  dl_hdw_state;
            u_char  dl_module_id_1[64];
            u_char  dl_module_id_2[64];
            u_char  dl_arpmod_name[64];
            u_char  dl_nmid;
            u_long  dl_reserved1;
            u_long  dl_reserved2;
        } dl_hp_ppa_info_t; 

dl_next_offset

  • offset of next ppa info structure from start of info area.

dl_ppa

  • PPA # assigned to LAN interface.

dl_hw_path

  • hardware path of LAN interface.

dl_mac_type

  • MAC type of LAN interface.

dl_phys_addr

  • station address.

dl_addr_length

  • length of station address.

dl_mjr_num

  • major number of interface driver.

dl_name

  • name of driver.

dl_instance_num

  • instance number of device.

dl_mtu

  • MTU

dl_hdw_state

  • hardware state

dl_module_id_1

  • default module ID name for the stream. The default name is “lan.” This value is used as the interface name when executing the ifconfig command.

dl_module_id_2

  • optional module ID name for streams that support multiple encapsulation types. If the user is attached to a stream that supports ETHER and IEEE8023, then this name is set to “snap”. Otherwise, the field is set to NULL. This value is used as the interface name when executing the ifconfig command.

dl_arpmod_name

  • identifies the ARP helper module for the network interface. If the driver does not have an ARP helper, this field will be NULL.

dl_nmid

  • identifies the network management ID value for a specific interface.

dl_reserved[1,2]

  • reserved fields

State

The message is valid in any State in response to a DL_PPA_REQ.

New State

The resulting state is unchanged.

DL_INFO_REQ

Requests information of the DLS provider about the DLPI stream. This information includes a set of provider-specific parameters, as well as the current state of the interface.

The message consists of one M_PCPROTO message block, which contains the following structure.

Format

typedef struct {
ulong dl_primitive;
} dl_info_req_t;

Parameters

dl_primitive

  • DL_INFO_REQ

State

The message is valid in any state in which a local acknowledgment is not pending, as described in Appendix B, Allowable Sequence of DLPI Primitives, of the DLPI 2.0 specification.

New State

The resulting state is unchanged.

DL_INFO_ACK

This message is sent in response to DL_INFO_REQ; it conveys information about the DLPI stream to the DLS user.

This message consists of one M_PCPROTO message block, which contains the following structure.

Format

typedef struct {
ulong dl_primitve;
ulong dl_max_sdu;
ulong dl_min_sdu;
ulong dl_addr_length;
ulong dl_mac_type;
ulong dl_reserved;
ulong dl_current_state;
ulong dl_sap_length;
ulong dl_service_mode;
ulong dl_qos_length;
ulong dl_qos_offset;
ulong dl_qos_range_length;
ulong dl_provider_style;
ulong dl_addr_offset;
ulong dl_version;
ulong dl_brdcst_addr_length;
ulong dl_brdcst_addr_offset;
ulong dl_growth;
} dl_info_ack_t;

Parameters

dl_primitive

  • DL_INFO_ACK

dl_max_sdu

  • maximum number of bytes that may be transmitted in a data link service data unit (DLSDU). This value must be a positive integer that is greater than or equal to the value of dl_min_sdu.

dl_min_sdu

  • minimum number of bytes that may be transmitted in a DLSDU. The value is never less than one.

dl_addr_length

  • length, in bytes, of the provider’s DLSAP address.

dl_mac_type

  • type of medium supported. Possible values:

    DL_CSMACD

    • Carrier Sense Multiple Access with Collision Detection (ISO 8802/3).

    DL_TPB

    • Token-Passing Bus (ISO 8802/4).

    DL_TPR

    • Token-Passing Ring (ISO 8802/5).

    DL_METRO

    • Metro Net (ISO 8802/6).

    DL_ETHER

    • Ethernet Bus.

    DL_HDLC

    • bit synchronous communication line.

    DL_CHAR

    • character synchronous communication line.

    DL_CTCA

    • channel-to-channel adapter.

    DL_FDDI

    • Fiber Distributed Data Interface.

    DL_OTHER

    • any other medium not listed above.

    NOTE: dl_mac_type is not valid until after a dl_attach_req has been issued.

dl_reserved

  • reserved field whose value must be set to zero.

dl_current_state

  • state of the DLPI interface for the stream when the DLS provider issued this acknowledgment.

dl_sap_length

  • current length of the SAP component of the DLSAP address. It may have a negative, zero or positive. A positive value indicates the ordering of the SAP and PHSYCAL component within the DLSAP address as SAP component followed by PHYSICAL component. A negative value indicates PHYSICAL followed by the SAP. A zero value indicates that no SAP has yet been bound. The absolute value of the dl_sap_length provides the length of the SAP component within the DLSAP address.

dl_service_mode

  • if returned before the DL_BIND_REQ is processed, this conveys which services modes the DLS provider can support. It contains a bit-mask specifying on or more than one of the following values:

    DL_CODLS

    • connection-oriented data link service

    DL_CLDLS

    • connection-less data link service

    DL_HP_RAWDLS

    • raw-mode service

    DL_ACLDLS

    • acknowledged connectionless data link service

    Since ATM is a connection-oriented link, the value of this field will always be DL_CODLS.

dl_qos_length

  • length, in bytes, of the negotiated/selected values of the quality of service (QOS) parameters. The returned values are those agreed during the negotiation. If QOS has not yet been negotiated, default values will be returned; these values correspond to those that will be applied by the DLS provider on a connect request.

    The QOS values are conveyed in the structures defined in the above sections in this chapter. For any parameter the DLS provider does not support or cannot determine, the corresponding entry will be set to DL_UNKNOWN.

dl_qos_offset

  • offset from the beginning of the M_PCPROTO block where the current QOS parameters begin.

dl_qos_range_length

  • length, in bytes, of the available range of QOS parameter values supported by the DLS provider. This the range available to the caller in a connect request. The range of available QOS values is conveyed in the structures defined in the following section in this chapter. For any parameter the DLS provider does not support or cannot determine, the corresponding entry will be set to DL_UNKNOWN.

dl_qos_range_offset

  • offset from the beginning of the M_PCPROTO block where the available range of quality of service parameters begins.

dl_provider_style

  • style of DLS provider associated with the DLPI stream. The following provider classes are defined.

    DL_STYLE1

    • PPA is implicitly attached to the DLPI stream by opening the appropriate major/minor device number.

    DL_STYLE2

    • DLS user must explicitly attach a PPA to the DLPI stream using DL_ATTACH_REQ.

    NOTE: ATM DLPI supports DL_STYLE2 only.

    HP-UX DLPI described in this document is Style 2.

dl_addr_offset

  • offset of the address that is bound to the associated stream. If the DLS user issues a DL_INFO_REQ prior to binding a DLSAP, the value of dl_addr_len will be 0 and consequently indicate that there has been no address bound.

dl_version

  • current supported version of the DLPI.

dl_brdcst_addr_length

  • length of the physical broadcast address. ATM DLPI does not support broadcast addresses and therefore, the value of this field will be zero.

dl_brdcst_addr_offset

  • not applicable to ATM DLPI.

dl_growth

  • growth field for future use. The value of this field will be zero.

State

The message is valid in any state in response to a DL_INFO_REQ.

New State

The resulting state is unchanged.

DL_HP_NOTIFY_EVENT_REQ

DL_HP_NOTIFY_EVENT_REQ requests for notification of link DOWN and link UP events. The DLS user who requests for DL_HP_LINK_STATE_CHANGE receives DL_LINK_DOWN_IND and DL_LINK_UP_IND when the link state changes.

For more information on DL_LINK_DOWN_IND and DL_LINK_UP_IND, refer to “DL_LINK_DOWN_IND” and “DL_LINK_UP_IND”, respectively.

This message consists of one M_PROTO message block, which contains the following structure:

Format

typedef struct { uint32_t dl_primitive; dl_hp_event_t dl_event; uint32_t dl_reserved1; uint32_t dl_reserved2;} dl_hp_notify_event_req_t;

Parameters

dl_primitive

  • DL_HP_NOTIFY_EVENT_REQ

dl_event

Table 2-1 dl_hp_event_t Enumeration

ConstantValue

Description

DL_HP_DISABLE_EVENTS0x00

This value disables all the event notifications.

DL_HP_LINK_STATE_CHANGE0x01

This value notifies the DLS user about the DL_LINK_DOWN_IND and DL_LINK_UP_IND events when the link state changes.

 

dl_reserved1

  • This parameter must be set to 0 (zero).

dl_reserved2

  • This parameter must be set to 0 (zero).

State

The message is valid in DL_IDLE or DL_UNBOUND state.

New State

The resulting state is unchanged.

Response

If the notify request is successful, DL_OK_ACK is sent to the DLS user. If the request fails, DL_ERROR_ACK is returned, and the resulting state is unchanged.

Reason for Failure

DL_OUTSTATE

  • The primitive is issued from an invalid state.

DL_SYSERR

DL_LINK_DOWN_IND

DLPI sends this event upstream to the streams that have requested for the link state change notifications using the DL_NOTIFY_LINK_STATE_REQ primitive.

The receipt of this event indicates that the physical driver instance has entered the DOWN operational state.

This message consists of one M_PCPROTO message block, which contains the following structure:

Format

typedef struct{
uint32_t dl_primitive;
} dl_link_down_ind_t;

Parameters

dl_primitive

  • DL_LINK_DOWN_IND

DL_LINK_UP_IND

DLPI sends this event upstream to the streams that have requested for the link state change notifications using the DL_NOTIFY_LINK_STATE_REQ primitive.

The receipt of this event indicates that the physical driver instance has entered the UP operational state.

This message consists of one M_PCPROTO message block, which contains the following structure.

Format

typedef struct {
uint32_t dl_primitive;
} dl_link_up_ind_t;

Parameters

dl_primitive

  • DL_LINK_UP_IND

DL_ATTACH_REQ

Requests the DLS provider to associate a physical point of attachment (PPA) with a stream.

The message consists of one M_PROTO message block, which contains the following structure.

Format

typedef struct {
ulong dl_primitive;
ulong dl_ppa;
} dl_attach_req_t;

Parameters

dl_primitive

  • DL_ATTACH_REQ

dl_ppa

  • identifier of the physical point of attachment to be associated with the stream.

State

The message is valid in state DL_UNATTACHED.

New State

The resulting state is DL_ATTACH_PENDING.

Response

If the attach request is successful, DL_OK_ACK is sent to the DLS user resulting in state DL_UNBOUND.

If the request fails, DL_ERROR_ACK is returned and the resulting state is unchanged.

Reasons for Failure

DL_BADPPA

  • The specified PPA is invalid.

DL_ACCESS

  • The DLS user did not have proper permission to use the requested PPA.

DL_OUTSTATE

  • The primitive was issued from an invalid state.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

Table 2-2 Error Return Values

Error

Criteria

EPERM

Permission for the control request is incorrect.

ENXIO

Invalid device

ENOMEM

Insufficient memory

EBUSY

Control information is already enabled (multicast, VLAN IDs, and so on), or the driver is unable to handle the request.

EINVAL

One of the parameters has invalid value.

ENOBUFS

Inadequate buffer space

ENOTSUP

Unsupported request/event/call

ENOLINK

Interface is not connected.

 

DL_DETACH_REQ

Requests the DLS provider to disassociate a physical point of attachment (PPA) with a stream.

The message consists of one M_PROTO message block, which contains the following structure.

Format

typedef struct {
ulong dl_primitive;
} dl_detach_req_t;

Parameters

dl_primitive

  • DL_DETACH_REQ

State

The message is valid in state DL_UNBOUND.

New State

The resulting state is DL_DETACH_PENDING.

Response

If the detach request is successful, DL_OK_ACK is sent to the DLS user resulting in state DL_UNATTACHED.

If the request fails, DL_ERROR_ACK is returned and the resulting state is unchanged.

Reasons for Failure

DL_OUTSTATE

  • The primitive was issued from an invalid state.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

DL_BIND_REQ

Requests the DLS provider to bind a DLSAP to the stream. The DLS user must identify the address of the DLSAP to be bound to the stream. The DLS user also indicates whether it will accept incoming connection requests on the stream. Finally, the request directs the DLS provider to activate the stream associated with the DLSAP.

The message consists of one M_PROTO message block, which contains the following structure.

Format

typedef struct {
ulong dl_primitive;
ulong dl_sap;
ulong dl_max_conind;
ushort dl_service_mode;
ushort dl_conn_mgmt;
ulong dl_xidtest_flg;
} dl_bind_req_t;

Parameters

dl_primitive

  • DL_BIND_REQ

dl_sap

  • DLSAP that will be bound to the DLPI stream.

dl_max_conind

  • maximum number of outstanding DL_CONNECT_IND messages allowed on the DLPI stream. If the value is zero, the stream cannot accept any DL_CONNECT_IND messages. If greater than zero, the DLS user will accept DL_CONNECT_IND messages up to the given value before having to respond with a DL_CONNECT_RES or a DL_DISCONNECT_REQ.

dl_service_mode

  • desired mode of service for this stream. This field should be set to one of the following:

    DL_CODLS

    • connection-mode service

    DL_CLDLS

    • connectionless-mode service

    DL_HP_RAWDLS

    • raw-mode service

dl_conn_mgmt

  • indicates that the stream is the “connection management” stream for the PPA to which the stream is attached. This field should be set to zero.

dl_xidtest_flg

  • indicates to the DLS provider that XID and/or TEST responses for this stream are to be automatically generated by the DLS Provider.

State

The message is valid in state DL_UNBOUND.

New State

The resulting state is DL_BIND_PENDING.

Response

If the bind request is successful, DL_BIND_ACK is sent to the DLS user resulting in state DL_IDLE.

If the request fails, DL_ERROR_ACK is returned and the resulting state is unchanged.

Reasons for Failure

DL_BADADDR

  • The DLSAP address information was invalid or was in an incorrect format.

DL_INITFAILED

  • Automatic initialization of the PPA failed.

DL_NOTINIT

  • The PPA had not been initialized prior to this request.

DL_ACCESS

  • The DLS user did not have proper permission to use the requested DLSAP address.

DL_BOUND

  • The DLS user attempted to bind a second stream to a DLSAP with dl_max_conind greater than zero, or the DLS user attempted to bind a second “connection management” stream to a PPA.

DL_OUTSTATE

  • The primitive was issued from an invalid state.

DL_NOADDR

  • The DLS provider could not allocate a DLSAP address for this stream.

DL_UNSUPPORTED

  • The DLS provider does not support requested service mode on this stream.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

DL_NOAUTO

  • Automatic handling of XID and TEST responses not supported.

DL_NOXIDAUTO

  • Automatic handling of XID response not supported.

DL_OUTSTATE

  • The primitive was issued from an invalid state.

Security Containment

With the Security Containment product version B.11.23.01 or later, HP DLPI will perform additional checks for DL_BIND_REQ primitive, namely:

  • DLPI will allow binding of IPv4, IPv6, and ARP Ethertype SAPs protocols only for users with PRIV_NETADMIN privilege.

  • DLPI will allow raw mode service only for users with PRIV_NETRAWACCESS privilege.

See “Fine-grained Privileges with Security Containment Release” for more details.

DL_BIND_ACK

Reports the successful bind of a DLSAP to a stream, and returns the bound DLSAP address to the DLS user. This primitive is generated in response of a DL_BIND_REQ.

The message consists of one M_PCPROTO message block, which contains the following structure.

Format

typedef struct {
ulong dl_primitive;
ulong dl_sap;
ulong dl_addr_length;
ulong dl_addr_offset;
ulong dl_max_conind;
ulong dl_xidtest_flg;
} dl_bind_ack_t;

Parameters

dl_primitive

  • DL_BIND_ACK

dl_sap

  • DLSAP address information associated with the bound DLSAP. It corresponds to the dl_sap field of the associated DL_BIND_REQ, which contains part of the DLSAP address.

dl_addr_length

  • length of the complete DLSAP address that was bound to the DLPI stream.

dl_addr_offset

  • offset from the beginning of the M_PCPROTO block where the DLSAP address begins.

dl_max_conind

  • allowed maximum number of outstanding DL_CONNECT_IND messages to be supported on the DLPI stream.

dl_xidtest_flg

  • XID and TEST responses supported by the provider.

State

The message is valid in state DL_BIND_PENDING.

New State

The resulting state is DL_IDLE.

DL_UNBIND_REQ

Requests the DLS provider to unbind the DLSAP that had been bound by a previous DL_BIND_REQ from this stream.

The message consists of one M_PROTO message block, which contains the following structure.

Format

typedef struct {
ulong dl_primitive;
} dl_unbind_req_t;

Parameters

dl_primitive

  • DL_UNBIND_REQ

State

The message is valid in state DL_IDLE.

New State

The resulting state is DL_UNBIND_PENDING.

Response

If the unbind request is successful, DL_OK_ACK is sent to the DLS user resulting in state DL_UNBOUND.

If the request fails, DL_ERROR_ACK is returned and the resulting state is unchanged.

Reasons for Failure

DL_OUTSTATE

  • The primitive was issued from an invalid state.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

DL_SUBS_BIND_REQ

Requests the DLS provider bind a subsequent DLSAP to the stream. The DLS user must identify the address of the subsequent DLSAP to be bound to the stream.

Format

The message consists of one M_PROTO message block, which contains the following structure.

typedef struct {
     ulong        dl_primitive;
     ulong        dl_subs_sap_offset;
     ulong        dl_subs_sap_length;
     ulong        dl_subs_bind_class;
} dl_subs_bind_req_t;

Parameters

dl_primitive

  • DL_SUBS_BIND_REQ

dl_subs_sap_offset

  • offset of the DLSAP from the beginning of the M_PROTO block.

dl_subs_sap_length

  • length of the specified DLSAP.

dl_subs_bind_class

  • specifies either peer or hierarchical addressing.

    DL_PEER_BIND

    • specifies peer addressing. The DLSAP specified is used in lieu of the DLSAP bound in the BIND request.

    DL_HIERARCHICAL_BIND

    • specifies hierarchical addressing. The DLSAP specified is used in addition to the DLSAP specified using the BIND request.

State

The message is valid in state DL_IDLE.

New State

The resulting state is DL_SUBS_BIND_PND.

Response

If the subsequent bind request is successful, DL_SUBS_BIND_ACK is sent to the DLS user resulting in state DL_IDLE.

Reasons for Failure

DL_BADADDR

  • The DLSAP address information was invalid or was in an incorrect format.

DL_ACCESS

  • The DLSAP user did not have proper permission to use the requested DLSAP address.

DL_OUTSTATE

  • Primitive was issued from an invalid state.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

DL_UNSUPPORTED

  • Requested addressing class not supported.

DL_TOOMANY

  • Limit exceeded on the maximum number of DLSAPs per stream.

Security Containment

With the Security Containment release, DLPI will perform additional checks for DL_SUBS_BIND_REQ primitive, namely:

  • DLPI will allow binding of IPv4, IPv6 and ARP Ethertype and SNAP SAPs protocols only for users with PRIV_NETADMIN privilege.

See “Fine-grained Privileges with Security Containment Release” for more details.

DL_SUBS_BIND_ACK

Reports the successful bind of a subsequent DLSAP to a stream, and returns the bound DLSAP address to the DLS user. This primitive is generated in response to a DL_SUBS_BIND_REQ.

Format

The message consists of one M_PROTO message block, which contains the following structure.

typedef struct {
ulong dl_primitive;
ulong dl_subs_sap_offset;
ulong dl_subs_sap_length;
} dl_subs_bind_ack_t;

Parameters

dl_primitive

  • DL_SUBS_BIND_ACK

dl_subs_sap_offset

  • offset of the DLSAP from the beginning of the M_PCPROTO block.

dl_subs_sap_length

  • length of the specified DLSAP.

State

The message is valid in state DL_SUBS_BIND_PND.

New State

The resulting state is DL_IDLE.

DL_SUBS_UNBIND_REQ

Requests the DLS provider to unbind the DLSAP that had been bound by a previous DL_SUBS_BIND_REQ from this stream.

Format

The message consists of one M_PROTO message block, which contains the following structure.

typedef struct {
ulong dl_primitive;
ulong dl_subs_sap_offset;
ulong dl_subs_sap_length;
} dl_subs_unbind_req_t;

Parameters

dl_primitive

  • DL_SUBS_UNBIND_REQ

dl_subs_sap_offset

  • offset of the DLSAP from the beginning of the M_PROTO block.

dl_subs_sap_length

  • length of the specified DLSAP.

State

The message is valid in state DL_IDLE.

New State

The resulting state is DL_SUBS_UNBIND_PND.

Response

If the unbind request is successful, a DL_OK_ACK is sent to the DLS User. The resulting state is DL_IDLE.

If the request fails, DL_ERROR_ACK is returned and the resulting state is unchanged.

Reasons for Failure

DL_OUTSTATE

  • Primitive was issued from an invalid state.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

DL_BADADDR

  • The DLSAP address information was invalid or was in an incorrect format.

DL_ENABMULTI_REQ

Requests the DLS Provider to enable specific multicast addresses on a per Stream basis. It is invalid for a DLS Provider to pass upstream messages that are destined for any address other than those explicitly enabled on that Stream by the DLS User.

Format

The message consists of one M_PROTO message block, which contains the following structure:

typedef struct {
ulong dl_primitive;
ulong dl_addr_length;
ulong dl_addr_offset;
} dl_enabmulti_req_t;

Parameters

dl_primitive

  • DL_ENABMULTI_REQ

dl_addr_length

  • length of the multicast address.

dl_addr_offset

  • offset from the beginning of the M_PROTO message block where the multicast address begins.

State

This message is valid in any state in which a local acknowledgment is not pending with the exception of DL_UNATTACHED.

New State

The resulting state is unchanged.

Response

If the enable request is successful, a DL_OK_ACK is sent to the DLS user. If the request fails, DL_ERROR_ACK is returned and the resulting state is unchanged.

Reasons for Failure

DL_BADADDR

  • Address information was invalid or was in an incorrect format.

DL_TOOMANY

  • Too many multicast address enable attempts. Limit exceeded.

DL_OUTSTATE

  • Primitive was issued from an invalid state.

DL_NOTSUPPORTED

  • Primitive is known, but not supported by the DLS Provider.

DL_SYSERR

DL_DISABMULTI_REQ

Requests the DLS Provider to disable specific multicast addresses on a per Stream basis.

Format

The message consists of one M_PROTO message block, which contains the following structure:

typedef struct {
ulong dl_primitive;
ulong dl_addr_length;
ulong dl_addr_offset;
} dl_disabmulti_req_t;

Parameters

dl_primitive

  • DL_DISABMULTI_REQ

dl_addr_length

  • length of the physical address.

dl_addr_offset

  • offset form the beginning of the M_PROTO message block where the multicast address begins.

State

This message is valid in any state in which a local acknowledgment is not pending with the exception of DL_UNATTACHED.

New State

The resulting state is unchanged.

Response

If the disable request is successful, a DL_OK_ACK is sent to the DLS user. If the request fails, DL_ERROR_ACK is returned and the resulting state is unchanged.

Reasons for Failure

DL_BADADDR

  • Address information was invalid or in an incorrect format.

DL_NOTENAB

  • Address specified is not enabled.

DL_OUTSTATE

  • Primitive was issued from an invalid state.

DL_NOTSUPPORTED

  • Primitive is known, but not supported by the DLS Provider.

DL_SYSERR

DL_PROMISCON_REQ

This primitive requests the DLS Provider to enable promiscuous mode on a per Stream basis, either at the physical level or at the SAP level.

The DL Provider will route all received messages on the media to the DLS User until either a DL_DETACH_REQ or a DL_PROMISCOFF_REQ is received or the Stream is closed.

NOTE: A DLS user cannot enable multiple promiscuous modes at the same time. Therefore, the DLS user must disable the existing promiscuous mode before enabling a new promiscuous mode.

Format

The message consists of one M_PROTO message block, which contains the following structure.

typedef struct {
ulong dl_primitive;
ulong dl_level;
} dl_promiscon_req_t;

Parameters

dl_primitive

  • DL_PROMISCON_REQ

dl_level

  • indicates promiscuous mode at the physical or SAP level.

    DL_PROMISC_PHYS

    • Before or after the STREAM has been bound, the DLPI user receives all traffic on the wire regardless of protocol or physical address.

    DL_PROMISC_SAP

    • Before or after the STREAM has been bound, the DLPI user receives all traffic destined for this interface (physical addresses, broadcast addresses or bound multicast addresses) that matches any protocol enabled on that interface.

    DL_PROMISC_MULTI

    • Before or after the STREAM has been bound, the DLPI user receives all multicast packets on the wire regardless of the protocol it is destined for.

State

The message is valid in any state when there is no pending acknowledgment.

New State

The resulting state is unchanged.

Response

If enabling of promiscuous mode is successful, a DL_OK_ACK is returned. Otherwise, a DL_ERROR_ACK is returned.

Reasons for Failure

DL_OUTSTATE

  • Primitive was issued from an invalid state.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

DL_NOTSUPPORTED

  • Primitive is known but not supported by the DLS Provider.

DL_UNSUPPORTED

  • Requested service is not supplied by the provider.

Security Containment

With the Security Containment product version B.11.23.01 or later, HP DLPI will allow enabling and disabling of promisucous mode only for users with PRIV_NETPROMISCUOUS privilege.

See “Fine-grained Privileges with Security Containment Release” for more details.

DL_PROMISCOFF_REQ

This primitive requests the DLS Provider to disable promiscuous mode on a per Stream basis, either at the physical level or at the SAP level.

NOTE: DLS User cannot disable a promiscuous mode without enabling it.

Format

The message consists of one M_PROTO message block, which contains the following structure.

typedef struct {
ulong dl_primitive;
ulong dl_level;
} dl_promiscoff_req_t;

Parameters

dl_primitive

  • DL_PROMISCOFF_REQ

dl_level

  • indicates promiscuous mode at the physical or SAP level.

    DL_PROMISC_PHYS

    • Before or after the STREAM has been bound, the DLPI user receives all traffic on the wire regardless of protocol or physical address.

    DL_PROMISC_SAP

    • Before or after the STREAM has been bound, the DLPI user receives all traffic destined for this interface (physical addresses, broadcast addresses or bound multicast addresses) that matches any protocol enabled on that interface.

    DL_PROMISC_MULTI

    • Before or after the STREAM has been bound, the DLPI user receives all multicast packets on the wire regardless of the protocol it is destined for.

State

The message is valid in any state in which the promiscuous mode is enabled and there is no pending acknowledgment.

New State

The resulting state is unchanged.

Response

If the promiscuous mode disabling is successful, a DL_OK_ACK is returned. Otherwise, a DL_ERROR_ACK is returned.

Reasons for Failure

DL_OUTSTATE

  • Primitive was issued from an invalid state.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

DL_NOTSUPPORTED

  • Primitive is known but not supported by the DLS Provider.

DL_NOTENAB

  • Mode not enabled.

Security Containment

With the Security Containment product version B.11.23.01 or later, HP DLPI will allow enabling and disabling of promiscuous mode only for users with PRIV_NETPROMISCUOUS privilege.

See “Fine-grained Privileges with Security Containment Release” for more details.

DL_HP_HW_RESET_REQ

DL_HP_HW_RESET_REQ resets the physical interface.

Format

The message consists of one M_PROTO message block, which contains the following structure:

typedef struct {
uint32_t dl_primitive;
} dl_hp_hw_reset_req_t;

Parameters

dl_primitive

  • DL_HP_HW_RESET_REQ

State

The message is valid in DL_IDLE or DL_UNBOUND state.

New State

The resulting state is unchanged.

Response

If the request is successful, DL_OK_ACK is returned.

If the request fails, DL_ERROR_ACK is returned.

Reason for Failure

DL_OUTSTATE

  • The primitive is issued from an invalid state.

DL_BADPRIM

  • The primitive is not formatted properly.

DL_SYSERR

  • A system error has occurred, because the driver returned an error. The driver error is present in the dl_unix_errno element of the dl_error_ack_t structure.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”. The possible errors can be (but not limited to) ENOBUFS and EBUSY.

Security Containment

With the Security Containment product version B.11.23.01 or later, HP DLPI will allow network related administrative tasks such as resetting the statistics on the interface only for users with PRIV_NETADMIN privilege.

See “Fine-grained Privileges with Security Containment Release” for more details.

NOTE: APA PPAs do not support the DL_HP_HW_RESET_REQ primitive. The EOPNOTSUPP Unix error is returned when the DL_HP_HW_RESET_REQ primitive is sent down the APA PPA.

DL_HP_RESET_STATS_REQ

DL_HP_RESET_STATS_REQ resets the statistics of an interface (physical or logical).

Format

The message consists of one M_PROTO message block, which contains the following structure:

typedef struct {
uint32_t dl_primitive;
} dl_hp_reset_stats_req_t;

Parameters

dl_primitive

  • DL_HP_RESET_STATS_REQ

State

The message is valid in DL_IDLE or DL_UNBOUND state.

New State

The resulting state is unchanged.

Response

If the request is successful, DL_OK_ACK is returned.

If the request fails, DL_ERROR_ACK is returned.

Reason for Failure

DL_OUTSTATE

  • The primitive is issued from an invalid state.

DL_BADPRIM

  • The primitive is not formatted properly.

DL_SYSERR

  • A system error has occurred, because the driver returned an error. The driver error is present in the dl_unix_errno element of the dl_error_ack_t structure.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”. The possible errors can be (but not limited to) ENOBUFS and EBUSY.

Security Containment

With the Security Containment product version B.11.23.01 or later, HP DLPI will allow network related administrative tasks such as resetting the statistics on the interface only for users with PRIV_NETADMIN privilege.

See “Fine-grained Privileges with Security Containment Release” for more details.

DL_OK_ACK

Acknowledges to the DLS user that a previously issued request primitive was received successfully. It is only initiated for those primitives that require a positive acknowledgment.

Format

The message consists of one M_PCPROTO message block, which contains the following structure.

typedef struct {
ulong dl_primitive;
ulong dl_correct_primitve;
} dl_ok_ack_t;

Parameters

dl_primitive

  • DL_OK_ACK

dl_correct_primitive

  • identifies the successfully received primitive that is being acknowledged.

State

The message is valid in response to a DL_ATTACH_REQ, DL_DETACH_REQ, DL_UNBIND_REQ, DL_CONNECT_RES, DL_RESET_RES, DL_DISCON_REQ, DL_SUBS_UNBIND_REQ, DL_PROMISCON_REQ, DL_ENABMULTI_REQ, DL_DISADMULTI_REQ, DL_HP_HW_RESET_REQ, DL_HP_RESET_STATS_REQ, or DL_PROMISCOFF_REQ from any of several states as defined in Appendix B, Allowable Sequence of DLPI Primitives, of the DLPI 2.0 specification.

New State

The resulting state depends on the current state and is defined fully in Appendix B, Allowable Sequence of DLPI Primitives, of the DLPI 2.0 specification.

DL_ERROR_ACK

Informs the DLS user that the previous request or response was invalid.

Format

The message consists of one M_PCPROTO message block, which contains the following structure:

typedef struct {
ulong dl_primitive;
ulong dl_error_primitive;
ulong dl_errno;
ulong dl_unix_errno;
} dl_error_ack_t;_

Parameters

dl_primitive

  • DL_ERROR_ACK

dl_error_primitive

  • primitive that is in error.

dl_errno

  • DLPI error code associated with the failure.

dl_unix_errno

  • UNIX system error code associated with the failure. This value should be non-zero only when dl_errno is set to DL_SYSERR. It is used to report UNIX system failures that prevent the processing of a given request or response.

State

The message is valid in every state where an acknowledgement or confirmation of a previous request or response is pending.

New State

The resulting state is that from which the acknowledged request or response was generated.

Optional Primitives to Perform Essential Management Functions

This section describes optional primitives. Some of these primitives may not be supported by the DLS provider.

DL_PHYS_ADDR_REQ

Requests the DLS provider to return the physical address associated with the stream depending upon the value of the address type selected in the request.

Format

The message consists one M_PROTO message block containing the structure shown below.

typedef struct {
ulong dl_primitive;
ulong dl_addr_type;
} dl_phys_addr_req_t;

Parameters

dl_primitive

  • DL_PHYS_ADDR_REQ

dl_addr_type

  • type of address requested - factory physical address or current physical address

    DL_FACT_PHYS_ADDR

    NOTE: APA PPAs do not support the DL_FACT_PHYS_ADDR primitive. The EOPNOTSUPP Unix error is returned when the DL_FACT_PHYS_ADDR primitive is sent down the APA PPA.

    DL_CURR_PHYS_ADDR

State

The message is valid in any attached state in which a local acknowledgement is not pending. For a style 2 provider, this would be after a PPA is attached using the DL_ATTACH_REQ. For a style 1 provider, the PPA is implicitly attached after the stream is opened.

New State

The resulting state is unchanged.

Response

The provider responds to the request with a DL_PHYS_ADDR_ACK if the request is supported. Otherwise, a DL_ERROR_ACK is returned.

Reasons for Failure

DL_NOTSUPPORTED

  • The primitive is known, but not supported by the DLS provider.

DL_OUTSTATE

  • The primitive was issued from an invalid state.

DL_PHYS_ADDR_ACK

This primitive returns the value for the physical address to the link user in response to a DL_PHYS_ADDR_REQ.

Format

The message consists one M_PROTO message block containing the structure shown below.

typedef struct {
ulong dl_primitive;
ulong dl_addr_length;
ulong dl_addr_offset;
} dl_phys_addr_ack_t;

Parameters

dl_primitive

  • DL_PHYS_ADDR_ACK

dl_addr_length

  • length of the requested hardware address.

dl_addr_offset

  • offset from beginning of the M_PROTO message block.

State

The message is valid in any state in response to a DL_PHYS_ADDR_REQ.

New State

The resulting state is unchanged.

DL_SET_PHYS_ADDR_REQ

Sets the physical address value for all streams for that provider for a particular PPA. DLPI requires applications using this exported API to run as root.

Format

The message consists one M_PROTO message block containing the structure shown below.

typedef struct {
ulong dl_primitive;
ulong dl_addr_length;
ulong dl_addr_offset;
} dl_set_phys_addr_req_t;

Parameters

dl_primitive

  • DL_SET_PHYS_ADDR_REQ

dl_addr_length

  • length of the requested hardware address.

dl_addr_offset

  • offset from beginning of the M_PROTO message block.

State

The message is valid in any attached state in which a local acknowledgement is not pending. For a style 2 provider, this would be after a PPA is attached using the DL_ATTACH_REQ. For a style 1 provider, the PPA is implicitly attached after the stream is opened.

New State

The resulting state is unchanged.

Response

The provider responds to the request with a DL_OK_ACK on successful completion. Otherwise, a DL_ERROR_ACK is returned.

Reasons for Failure

DL_BADADDR

  • The address information was invalid or was in an incorrect format.

DL_NOTSUPPORTED

  • The primitive is known, but not supported by the DLS provider.

DL_SYSERR

DL_OUTSTATE

  • The primitive was issued from an invalid state.

DL_BUSY

  • One or more streams for that particular PPA are in the DL_BOUND state.

Security Containment

With the Security Containment product version B.11.23.01 or later, HP DLPI will allow network related administrative tasks such as setting the physical address of an interface only for users with PRIV_NETADMIN privilege.

See “Fine-grained Privileges with Security Containment Release” for more details.

NOTE: APA PPAs do not support the DL_SET_PHYS_ADDR_REQ primitive. The EOPNOTSUPP Unix error is returned when the DL_SET_PHYS_ADDR_REQ primitive is sent down the APA PPA.

DL_GET_STATISTICS_REQ

Directs the DLS provider to return statistics.

Format

The message consists one M_PROTO message block containing the structure shown below.

typedef struct {
ulong        dl_primitive;
} dl_get_statistics_req_t;

Parameters

dl_primitive

  • DL_GET_STATISTICS_REQ

State

The message is valid in any attached state in which a local acknowledgement is not pending.

New State

The resulting state is unchanged.

Response

The DLS provider responds to the request with a DL_GET_STATISTICS_ACK if the primitive is supported. Otherwise, a DL_ERROR_ACK is returned.

Reasons for Failure

DL_NOTSUPPORTED

  • The primitive is known, but not supported by the DLS provider.

DL_GET_STATISTICS_ACK

Returns statistics in response to the DL_GET_STATISTICS_REQ. The content of this statistics block is the following:

Format

The message consists one M_PROTO message block containing the structure shown below.

typedef struct {
ulong       dl_primitive;
ulong       dl_stat_length;
ulong       dl_stat_offset;
} dl_get_statistics_ack_t;

Parameters

dl_primitive

  • DL_GET_STATISTICS_ACK

dl_stat_length

  • length of the statistics structure.

dl_stat_offset

  • offset from the beginning of the M_PCPROTO message block where the statistics information resides.

State

The message is valid in any state in response to a DL_GET_STATISTICS_REQ.

New State

The resulting state is unchanged.

The DL_GET_STATISTICS_ACK returns standard mib and optionally extended mib information for all HP supported networking interfaces. It is up to the DLPI user to check the interface-specific field of the Interface MIB to determine whether there is a transmission MIB.

DL_HP_GET_64BIT_STATS_REQ

Directs the DLS provider to return 64-bit statistics.

Format

The message consists one M_PROTO message block that contains the following structure:

typedef struct{
    uint32_t        dl_primitive;
    uint32_t        dl_reserved1;
    uint32_t        dl_reserved2;
}dl_hp_get_64bit_stats_req_t;

Parameters

dl_primitive

  • DL_HP_GET_64BIT_STATS_REQ

dl_reserved1

  • Reserved for future use; set to 0.

dl_reserved2

  • Reserved for future use; set to 0.

State

The message is valid in any attached state in which a local acknowledgement is not pending.

New State

The resulting state is unchanged.

Response

The DLS provider responds to the request with DL_HP_GET_64BIT_STATS_ACK if the primitive is supported and successful; otherwise, DL_ERROR_ACK is returned.

Reasons for Failure

DL_NOTSUPPORTED

  • Indicates that the primitive is known to the DLS provider, but the particular PPA does not support it.

DL_SYSERR

  • Indicates that a system error has occurred.

DL_OUTSTATE

  • Indicates that the primitive was issued from an invalid state.

DL_HP_GET_64BIT_STATS_ACK

Returns 64-bit statistics in response to the DL_HP_GET_64BIT_STATS_REQ request.

Format

The message consists one M_PCPROTO message block that contains the following structure:

typedef struct{
    uint32_t    dl_primitive;
    uint32_t    dl_stat_length;
    uint32_t    dl_stat_offset;
    uint32_t    dl_reserved1;
    uint32_t    dl_reserved2;
    uint32_t    dl_reserved3;
}dl_hp_get_64bit_stats_ack_t;

Parameters

dl_primitive

  • DL_HP_GET_64BIT_STATS_ACK

dl_stat_length

  • Indicates length of the 64-bit statistics structure.

dl_stat_offset

  • Indicates offset from the beginning of the M_PCPROTO message block where the 64-bit statistics information resides.

dl_reserved1

  • Reserved for future use; set to 0.

dl_reserved2

  • Reserved for future use; set to 0.

dl_reserved3

  • Reserved for future use; set to 0.

State

The message is valid in any state in response to a DL_HP_GET_64BIT_STATS_REQ request.

New State

The resulting state is unchanged.

DL_HP_GET_64BIT_STATS_ACK returns standard 64-bit statistics and 32-bit MIB-II statistics. In addition, it returns optionally extended interface-specific MIB information for all the interfaces that support the DL_HP_GET_64BIT_STATS_REQ request.

The statistics is structured as Ext_64bit_mib_t, which is defined in <sys/mib.h>. DLPI users can determine whether it includes an interface-specific MIB. Normally, if an interface does not support interface-specific MIB, that part of the statistics is zero.

NOTE: DLPI users must follow relevant RFC (for standard 64-bit statistics, it is RFC2863) to interpret the statistics

DL_HP_MULTICAST_LIST_REQ

Requests the DLS Provider to return a list of all currently enabled multicast addresses on a specific LAN interface.

Format

The message consists one M_PROTO message block containing the structure shown below.

typedef struct {
ulong       dl_primitive;
} dl_hp_multicast_list_req_t;

Parameters

dl_primitive

  • DL_HP_MULTICAST_LIST_REQ

State

The message is valid in any state in which there is not a local acknowledgment pending with the exception of DL_UNATTACHED.

New State

The resulting state is unchanged.

Response

If the multicast request is successful, a DL_HP_MULTICAST_LIST_ACK is sent to the DLS user. If the requests fails, DL_ERROR_ACK is returned and the resulting state is unchanged.

Reasons for Failure

DL_OUTSTATE

  • Primitive was issued from an invalid state.

DL_SYSERR

  • A system error has occurred and the UNIX system error is indicated in the DL_ERROR_ACK.

    The UNIX error returned may be set to (not limited to) errors listed in Table 2-2 “Error Return Values”.

NOTE: APA PPAs do not support the DL_HP_MULTICAST_LIST_REQ primitive. The EOPNOTSUPP Unix error is returned when the DL_HP_MULTICAST_LIST_REQ primitive is sent down the APA PPA.

DL_HP_MULTICAST_LIST_ACK

Reports the successful completion of a DL_HP_MULTICAST_LIST_REQ primitive. A complete list of the multicast addresses for a specific LAN interface are returned after the control message header.

Format

The message consists one M_PROTO message block containing the structure shown below.

typedef struct {
       ulong     dl_primitive;
       ulong     dl_offset;
       ulong     dl_length;
       ulong     dl_count;
} dl_hp_multicast_list_ack_t;

Parameters

dl_primitive

  • DL_HP_MULTICAST_LIST_ACK

dl_offset

  • offset to the data in the multicast acknowledgment.

dl_length

  • length of data area, in bytes.

dl_count

  • total number of 6 byte multicast addresses in the data area of the multicast acknowledgment.

State

The message is valid in any state in response to a DL_HP_MULTICAST_LIST_REQ.

New State

The resulting state is unchanged.

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 2007 Hewlett-Packard Development Company, L.P.