DLPI Programmer's Guide

22 Chapter 1
Introduction to DLPI
The Data Link Layer
A PPA is identified by a unique PPA identifier. For media that support
physical layer multiplexing of multiple channels over a single physical
medium (such as the B and D channels of ISDN), the PPA identifier must
identify the specific channel over which communication will occur.
Two styles of DLS provider are defined by DLPI, distinguished by the
way they enable a DLS user to choose a particular PPA. The style 1
provider assigns a PPA based on the major/minor device the DLS user
opened. This style of provider is appropriate when few PPAs will be
supported.
If the number of PPAs a DLS provider will support is large, a style 2
provider implementation is more suitable. The style 2 provider requires
a DLS user to explicitly identify the desired PPA using a special attach
service primitive. For a style 2 driver, the open(2) creates a stream
between the DLS user and DLS provider, and the attach primitive then
associates a particular PPA with that stream. The format of the PPA
identifier is specific to the DLS provider.
DLPI provides a mechanism to get and/or modify the physical address.
The primitives to handle these functions are described in Chapter 2. The
physical address value can be modified in a post-attached state. This
modifies the value for all streams for that provider for a particular PPA.
The physical address cannot be modified if even a single stream for that
PPA is in the bound state.
The DLS user uses the supported primitives DL_ATTACH_REQ,
DL_BIND_REQ, DL_ENABMULTI_REQ, and DL_PROMISCON_REQ
to define a set of enabled physical and SAP address components on a per
stream basis. It is invalid for a DLS provider to ever send upstream a
data message for which the DLS user on that stream has not requested.
The burden is on the provider to enforce the isolation of SAP and
physical address space effects on a per-stream basis by any means that it
chooses.
HP PPA Format
The PPA number which is passed in the DL_ATTACH_REQ primitive
should correspond to the network management ID (NMID) of the
interface being attached to. The network management ID is obtainable
in one of two ways: 1) the lanscan(1M) command, and 2)
programmatically via the HP_PPA_REQ primitive (see Chapter 2).