Вы находитесь на странице: 1из 15

CAN WE TRUST IN HDLC ?

ABSTRACT: in spite of the theoretical error detecting capability of its CRC, the actual degree
of data integrity provided by HDLC is quite low .

The paper gives a quantitative assessment of HDLC's deficiencies and of their reasons paying
particular attention to actual applications of the HDLC family of standards.

Finally, we look at some strategies that have been suggested to allow the use of HDLC in the
most demanding applications.

1. INTRODUCTION

HDLC is probably the most widespread data link protocol [IS089a, IS089b, IS090] : it is used
as LAPB-X .2 5[CCIT85] in packet switched data networks, as LAPD in ISDN and TMN
(Telecommunion Management Network) [CCI88a, CCI88b], and as SDLC it is part of IBM
SNA and of Intel Bitbus, a widely used network architecture for industrial applications [IBM79,
Inte84] . Through PPP it has also become an Internet standard protocol [Perk89].

Despite the success, its use in critical applications such as process control and 'decontrol has
been so severely criticized that ad hoc protocols have been standardized [Funk78, SeRi80,
Funk82. IEC89]: a main reason of criticism has been HDLC vulnerability to transmission errors.

It is however hard to think that HDLC may be kept out of critical applications, for instance
because they may conveniently use packet switched public data networks (PSPDN) . Therefore
it is important to have a clear understanding of HDLC deficiencies, and of methods to confront
them.

It is also important to understand how protocols and line encoding methods affect the theoretical
error detecting properties of different frame check sequences when we want to compare them
[Flet82, Naka88].

This paper presents a summary and a pragmatic view of results that are sparse and in some cases
may be hardly accessible [Funk78, SeRi80, Cole, FiSa92, ChTr93] . It gives also some original
results on specific HDLC applications of high practical interest:

 Networks with NRZI line encoding. Unlike NRZ or Manchester, NRZI uses a
differential encoding/decoding process and therefore is memory based : the signal that
represents a bit depends also on the preceeding bit. NRZI, in conjunction with HDLC,
represents the most effective self clocking line encoding, and is therefore widely used in
bandwidth constrained applications ;
 octet aligned networks, where the number of bits between opening and closing flag of a
frame must be multiple of eight : this additional constraint to the standard is typical of
most implementations, including LAPB and SDLC , and is relevant since it increases
'significantly the data integrity characteristics of the protocol;
 Networks where interframe time fill is implemented by transmitting an HDLC idle
sequence (or by not transmitting anything if the physical layer provides a steady 1
signal) rather than flags. A frame is closed by 1 flag before the idle sequence, and if this
flag is lost the frame is aborted (discarded): this is typical of networks with a half-
duplex and/or multipoint physical layer, as in most telecontrol and data acquisition
applications.

Finally, the paper discusses some strategies that have been suggested to overcome the HDLC
fragility, and shows how, often and until recently, this fragility has not been taken into account
in the design of networks that make use of HDLC based data links.

1 .1. Data Integrity

The noise characteristics of a data transmission link can be described by the average relative
number of erroneous bits, or Bit Error Rate (BER) of the link . Process and telecontrol
applications may work in env ironments where BER ≥ 10-4.

Protocols are introduced to improve the reliability of a link by detecting and recovering
(through retransmission) errors. A measure of the reliability of a protocol is its Residual Error
Rate (RER), defined as the number of undetected wrong messages divided by the total number
of messages received. Generally RER is an increasing function of BER: [Fuji85] shows an
exception to this rule and some HDLC related exceptions are shown in [Funk82], but in all
cases their practical effect is small since they occur for very high BER (> 10-3) and/or very short
frames (< 128 bits).

IEC (the International Electrotechnical Commission) has defined 3 data Integrity Classes (I1,
12, 13) for telecontrol data transmission, related to the reliability requirements of different types
of messages (e .g. commands, measures . . .)

[IEC89]. Fig. 1 shows the upper limits of RER as a function of BER for these Classes. Since
diagrams are logarithmic the slope of the curves for sufficiently low BER represents the
Hamming Distance (HD) required to protocols: HD ≥ 2 for Class I1, and HD ≥ 4 for Classes 12
and 13.
1.2. HDLC Dialects

HDLC is a broad-scoped standard, providing "a guideline and a framework in which to develop
and design specific protocols" [Car180]: not only it allows different procedure elements and
classes, but also quite different frame formats.

This has led to the development of several dialects (or derived standards) claiming conformance
to HDLC but hearing scarce similarities with each other [Calr80] : to name some, CCITT LAP,
LAPB and LAPD, ANSI ADCCP, IBM SDLC, Internet PPP, each with its own subdialects.

The basic frame structure is always the same [IS089a]:

Imagemx

But several variants are possible. The address field may be fixed (1 byte) or variable length, the
control field (normally 1 byte) may he extended to accomodate modulo-128 sequence numbers,
the FCS, which is of cyclic redundancy check (CRC) type, may be 16 or 32 bits.

Interfrane time till may be implemented either by a continuous sequence of flags or by an idle
sequence (a string of 1 of at least 15 bits: the physical level might also provide a stable 1 in the
absence of signal). Idle interframe is used when the physical level is half-duplex, or in case of
multipoint links : the closing flag is needed by the receiver to detect the end of frame, but
following flags are useless, so in this case we assume that the closing flag is followed by the
address field of a new frame or by an idle sequence .

Some HDLC dialects like SDLC, or most of their implementations (like LAPB of real
PSPNDs), require a frame to be an integral number of octets: a frame which is not octet aligned
is discarded as erroneous, independently of the FCS.

Inplementations of HDLC networks may also differ in the line encoding of bits. Many baseband
techniques (such as NRZ, NRZI, Manchester. etc.) may be used to implement the physical level
of HDLC networks. Bandpass techniques do not introduce anything new, so they will not be
considered here.

An encoding method may be with or without memory. In the second case the signal that
encodes a bit depends only on the hit itself. In the first case it depends also on the previous bit.
An example of rnemoryless encoding is NRZ : I and 0 may be typically represented respectively
by constant high and low voltage levels. NRZI is a memory based encoding method: it
represents a 1 as no level change and a 0 as a change. A string of Is is encoded as a constant
signal by both NRZ and NRZI, whilst a string of Os is a constant signal with NRZ and an
alternating level signal with NRZI.

The choice of the par ticular line encoding method in real networks depends on several practical
issues:

 Compatibility or standardization: for PSPDN, X .2 .5 specifies that the physical level


must use NRZ [CCIT85].
 Bandwidth constraints: Manchester must sometimes be avoided because its bandwith
requirement are twice as high than those of NRZ and NRZI.
 Clock recovery: NRZI may he used to recover clock information from the data stream,
avoiding the explicit transmission of bit synchronization information and the related
loss of bandwith . Clock recovery is achieved through a phase adjustment of the local
clock whenever an edge is detected and HDLC guarantees that inside a frame no string
of contiguous 1-bits is longer than 5: in NRZI a 0-bit causes a level change, therefore
edges in a data stream cannot he separated by more than 5 bits.

NRZI, in conjunction with HDLC, results in a self-clocking encoding, whilst NRZ is not, since
a long string of 0 bits may lead to the loss of synchronization: NRZI is the most efficient
solution whenever no explicit bi t synchronization is provided and, at the same time, bandwith
constraints are strict.

We will consider frames with address and control fields of 8 bits and, mainly, a 16-bit FCS
since the 32-bit FCS is not allowed by the most important HDLC dialects and is not widely
supported by HDLC oriented controllers.

Four network configurations will be considered, corresponding to two pairs of options:

1. A network may be octet aligned or not;

2. The line coding method may be memoryless or not (NRZ and NRZI will be taken as the
related paradigms).

The interframe time fill method will appear to be irrelevant from the standpoint of data integrity.

1.3. Error Detection Mechanisms

We assume that error detection is performed only through the FCS and through frame length
constraints: for instance, it is not considered that error detection may occur because the HDLC
procedures reveal an illegal control field (this, provides a pessimistic estimate of RER since 34
out of 256 configurations of the control field are illegal) . When this assumption is too
pessimistic, the case is treated explicitly.

With these hypotheses the error generation and detection processes are described in Fig.2. Here
and throughout the paper N is the frame length, including the FCS, before bit stuffing, while Ns
is the frame length after bit stuffing.

Each bit error can be created by adding 1 modulo-2 to an original bit. So, the received frame can
be obtained from the transmitted frame by adding a bit stream, called error pattern, having the
same length of the frame (Ns).

We assume an equiprobable, memoryless channel error events distribution, which is easy to


analyze even if it is not an accurate approximation of the behaviour of most real channels
(Binary Syrmnetric Channel Model of [HBL75]).

1.4. Properties of HDLC's FCS

The 16-bit FCS is generated using the CCITT V.41 polynomial [1]:

g(x)= x 16 +x 12 +x5 +1=(x+1) g'(x)= (x+1)•(x 15 +x14 +x13 +x 12 +x4 +x3 +x2 +x+1)

This CRC type FCS guarantees an HD of 4 for all frames of length less or equal to the so called
natural length of the polynomial, thus it can detect any erroneous frame of length up to 2 15 bits
with up to 3 wrong bits. More precisely, each message is a codeword of a shortened, distance-4
cyclic Hamming code generated by g(x).

Because (x+l) is a factor of the generator polynomial, the HDLC FCS provides a parity check:
any odd number of erroneous bits will always be detected . An erroneous frame may be
undetected only if it contains an even number of erroneous bits (so that the parity bit in the FCS
is ineffective) and the other 15 FCS bits fail to detect the error.

Moreover, the FCS is able to detect any single burst of errors not longer than 16 bits. In fact no
error pattern of the form:

E(x) = ak. xk + ak- l. xk-1 + ... + ak-m . xk-m = xk-m . (a k . xm + … + ak-m+ 1 . x + ak-m)

with 0 ≤ m ≤ 15 is divided by g(x) for any value of the coefficients al.

In case of m erroneous bits (1n even and m>4), the error detecting power of the FCS is,
approximately [FiSa92], related only to its length. Therefore the probability that an erroneous
frame is not detected is roughly 2- 15 (the parity check is obviously satisfied). Pr{FCS fails} is
directly related to the probability of 4 bit errors taking place, since the contribution of larger
numbers of errors (6, 8, . . .) is negligible for a sufficiently small BER. So, an asymptotical
approximation of Pr{FCS fails} is:

(1) {FCS fails} = 2-15. (𝑁4) . BER4. (1 - BER)N-4

If we ignore higher order errors, a better approximation is given by [ChTr93]:

(1') Pr {FCS fails} = A4. BER4. (1-BER)N- 4

Where A4 is the number of codewords generated by g(x) having distance 4 from the all-zero
codeword (A 4 depends on N: see Table 1 for some of its values) . The difference with (1) is
negligible (order of 1%) and this is true also for the corresponding expressions given in
[SeRi80, AgIv92, Fuji85] ([Fuji85] takes into account the effects of code shortening, i.e. of
using frames of length strictly lower than the natural length of the FCS).

Because the HDLC FCS relates RER to BER4, it seems that we have a good starting point for
satisfying even the most demanding IEC requirements.

Unfortunately we will see that the framing and bit stuffing mechanism of HDLC make (1) and
(1') not applicable. But they may also be inapplicable because of line coding techniques: when
NRZI is used, independently of HDLC related problems that make these expressions
inapplicable for any line encoding. For NRZI, because of memory, every channel error affects 2
adjacent bits producing a pair of erroneous bits (the term channel error is used here to
distinguish transmission errors from their interpretation as hit error patterns) . If we neglect
some tail effects and contiguous channel errors, the error pattern will always present an even
number of erroneous bits. This makes the FCS parity check ineffective: however, although 2
channel errors produce 4 (2 pairs of) bit errors, the corrupted frame is always detected [ChTr93]
. In fact no error pattern of the form:

E(x) = (xk+l + xk ) + (xrn+l + xm) = xm • (x + 1) (xk-m + 1) is divided by g'(x).

It can be shown [ChTr93] that the code behaves, with respect to channel error events, as a
distance-3 Hamming code of length 215-1: FCS may fail with 3 or more channel errors. So,
using NRZI, we have:

(1 ") Pr {FCS fails} = B3 • CER3 (1-CER) N-3 + B4 CER4 • (l -CER) N-4


Where CER is the channel er ror rate, B 3 is the number of codewords in the distance-3
Hamming code generated by g'(x) having distance 3 from the all-zero codeword (see Table 1 for
its value) . The values of B3 show that more than 3 channel errors are necessary to generate an
undetectably erroneous frame for frame lengths up to 182 bits. The contribution of a larger
number of channel errors (5, 6, …) is negligible for a sufficiently small BER.

1.5. Framing and Bit Stuffing

The RER to BER relationships just established apply if the FCS check is performed on the bit
string obtained from the original message concatenated with the FCS. Unfortunately this is not
always the case in HDLC.

Beginning and end of frames are marked in HDLC by a unique 8-bit pattern (01111110) called
flag, without any explicit frame length field. To avoid the simulation of a flag within a frame,
HDLC provides an escape mechanism called bit stuffing: the transmitter inserts a 0 (insertion 0-
bit) after any 5 contiguous 1-bits in the frame, and the receiver deletes any 0-bit following 5
contiguous 1-bit (if there are more than 5 contiguous 1-bit this will be a flag, an abort or an idle
sequence).

A single error that changes any one of 5 contiguous 1-bit causes the hit stuffing mechanism to
fail, so the following 0 is not deleted, and a (one bit) longer frame is received . An error can also
lead to a 0-bit deletion after an erroneus sequence of 5 contiguous 1-bits. If the single error
changes an insertion 0-bit into a 1, a flag may be simulated, and a shortened frame is received; a
flag can be simulated by a single error even without interference with bit stuffing.

Because of framing (frame boundary recognition) and bit stuffing a single bit error may become
a landslide: the received frame is not derived from the original one by any number of bit
inversions (the received frame may not be obtained from the transmitted one through the
addition of an error pattern), and the properties of the FCS may be lost. Because a single
channel error may change a legal frame into another, the actual HD provided by HDLC is only 1
instead of 4 (or 3 with NRZI) [Funk82].

When computing the RER to BER relationship for HDLC we must consider not only the
intrinsic weakness of the FCS but also its failures due to the combined effects of transmission
errors and framing or bit stuffing.

A secondary effect of bit stuffing is that, since it introduces a 0-bit after any string of 5
contiguous 1-bit, a n equiprobable source becomes non equiprobable. For an equiprobable
memoryless source it is Pr {01 = 0 .5 and Pr {l} = 0 .5, where Pr{X} is the probability of event
X. Bit stuffing introduces a 0-bit every average 62 bits of the message [Funk82], therefore, after
bit stuffing, we have Pr {0} = 32/63 and Pr{ 1} = 31/63 and the transmission of a frame of
length N takes Ns = N . (63/62) bits.

The probabilities of all possible configurations of 8 contiguously transmitted bits are also
changed [Funk82] (e.g. Pr (11111111) = O), and this affects the probability that a single hit
error can simulate a flag within a frame (a mathematical discussion of all issues appears in
[ChTr93, FiSa92], that are available on demand from the authors).

2. UNDETECTED ERRORS

It has been shown that there are 2 modes in which HDLC fails to detect an erroneous frame:

1. because of the intrinsic limits of the FCS capabilities.

2. because the combined effects of transmission errors and framing or bit stuffing offset the FCS
capabilities.

It will be shown that, for all HDLC implementations and for most significant values of BER and
of the frame length, the first failure mode is less important than the second, and thus that the
HDLC error detection mechanism is rathe r

Ineffective.

The second failure mode is related to 3 types of errors, whose relative importance depends on
the particular HDLC implementation:

• Simulation of a flag within a frame;


• Loss of an Opening or Closing Flag (OF, CF);
• Insertion or deletion of a bit within a frame.

All these HDLC specific errors can occur either alone or in combination, with each other or
with normal bit errors . In the following, as a particularly relevant example of double error, we
have examined the case of

• simultaneous insertion and deletion of a 0-bit within a frame.

Simulation of a Flag (Reason A )

This event occurs when a flag is simulated inside the frame because of one or more bit errors,
and at least one of the resulting shortened subframes represents a valid frame [Funk82] . We
will consider only the case of a flag simulated by a single channel error .
If NRZ is used, a single channel error results in a single bit error . Therefore, the parity of all
bits between the original OF and CF is changed, and because the number of 1-bits in the
simulated flag is even, at least one of the 2 derived subframes will have a wrong parity, and thus
will be detected as erroneous.

If NRZI is used the previous argument doesn't hold, because a single channel error results in a
pair of bit errors, and thus the global parity, and the parity of both derived subframes is
preserved . However, it can be shown that, because of the intrinsic properties of the HDLC FCS,
at most one of the two derived subframes may appear to be legal [ChTr93].

In both cases if a single error simulates a flag inside a frame, thus generating 2 derived
subframes, at most one of these may be legal : from now on we will consider only this single
subframe.

It has been shown that, for the subframe to be undetected, the lost prolog or epilog of the frame
must be longer than 16 bits [ChTr93, FiSa92] : because an HDLC frame must be at least 32 bits
long, frames not longer than 48 (=32+16) bits are immune from this problem.

Moreover, in case of octet aligned transmission there are (N-32-16)/8 possible positions for a
simulated flag, otherwise the number of possible positions is (N-32-16).

The probability that a shortened subframe is not detected is given by the following asymptotical,
union bound, approximation, which holds both for NRZ and NRZI, and for leading and trailing
subframes [ChTr93]:

The probability that a shortened subframe is not detected is given by the following asymptotical,
union bound, approximation, which holds both for NRZ and NRZI, and for leading and trailing
subframes [ChTr93] :

• (3) Pr(undetected subframe} = (1-BER)16 . (C l . 2- 23 + C2 . 2- 16 . (N-56)) • BER (1-


BER)Ns- 1

Where constants C I and C2 are different in the different cases: their values are shown in Table
2 (a sketch of the proof of (3) is shown in the Appendix : other formulae of the paper can be
proved along the same lines).

The first factor is the probability of valid OF and CF (single error hypothesis), and the last two
the probability that exactly one channel error affects the frame: these or similar factors are
present in all formula.
The intermediate factor accounts for the probability that a single bit error changes 8 contiguous
bits into a flag and that the FCS does not reveal this error . It also takes into account the
probability to appear in the frame, after hit stuffing, of bit patterns that may be transformed by a
single error into a flag.

The first term of the intennediate factor accounts for a simulated flag near the original OF
(trailing subframe) or CF (leading subframe), and the second for a simulated flag in the
remaining (N-56) possible positions.

If the octet constraint is introduced C I becomes 0 and the resulting expression must be divided
by 8 . (3) becomes:

• (3') Pr{undetected subframe} (1-BER) 16 . (C 2 . 2- 16 . ( (𝑁−56


8
)+ 1)) • BER (1-BER) Ns- 1

The probability that a single bit error simulates a flag in the middle of a frame, and that one of
the two subframes is not detected is:

• (4) Pr { event Al = Pr { undetected leading subframe } + Pr {undetected trailing


subframe }

The first order approximation of (4) shows that Pr{ event Al is directly related to BER and to
the frame length.

Although leading and trailing subframes are almost symmetrical from the standpoint of FCS and
length checks, they are very different from the standpoint of the correctness of the logical link
control protocol . The leading subframe has address and protocol header equal to those of the
original frame, so that they are obviously correct . For the trailing frame not to be revealed,
beside a correct FCS, it must have a proper address, a proper control field, and an overall
congruent frame structure (e .g . an RR-frame must be exactly 32 bits long, including the CRC
[IS089a]) : address and control field are derived from information field bits of the original
frame, so that their value is unpredictable.

For instance the address has a probability 1/128 to be valid in a point-to-point configuration,
and depends on the number of secondary stations in a multipoint configuration. The 8 bits that
represent the HDLC control field may have one of the unused (illegal) 34 configurations
[IS089a] ; moreover the sequence numbers or a legal control field may be inconsistent with the
state of the connection.

Therefore we may expect that, due to the implicit error revealing capabilities of the HDLC link
control procedures, an erroneous trailing subframe has a much lower probability to be
undetected than the leading subframe. The fact that we have related error detection only to the
FCS and to length constraints yields a pessimistic estimate. A more realistic probability of
undetected erroneous frames due to the simulation of a flag approximately coincides with the
probability that the leading subfrarne remains undetected.

2.2. Loss of an Opening or Closing Flag (Reason B)

This event occurs when the OF or the CF are lost because of one or more bit errors. We
consider only the most significant case in which no additional errors occur beside the loss of the
flag (for which a single bit error suffices).

The frame that is actually received depends on the interframe time fill strategy adopted and on
the possible adjacency of another frame, separated only by the lost flag.

In case of idle interframe, with no adjacent frames, if the OF or the CF are lost, then the frame is
not received at all.

In case of flag interframe, with no adjacent frames, the received frame is 8 bits longer than the
original one. However, it can be shown that if we extend a legal frame with a prolog or an
epilog of up to 11 bits, whatever the value of these bits, the resulting frame is recognized as
erroneous [ChTr93, FiSa92]. Therefore the loss of a flag is always revealed.

In case of loss of the flag separating 2 adjacent frames we receive a single frame, union of the
two and of the corrupted flag. The minimum length bit string that, inserted between 2 legal
frames, allows the creation of a joint legal frame is 15 [ChTr93]: therefore, however corrupted
the flag may be, the resulting frame is recognized as erroneous.

In conclusion, no single error that implies the loss of an OF or CF may remain undetected.

Insertion of a 0 Bit (Reason C')

This event occurs when a 0-bit generated by the bit stuffing mechanism is inserted in the frame
(actually not discarded) because of at least an error in a sequence of 5 contiguous 1-bit . We
consider only the case of a single error.

For octet aligned transmission (both Idle and Flag interframe, and for all line codings) only a
simultaneous erroneous deletion of a 0-bit may generate an undetectable erroneous frame (see
next sections) .
If no octect constraint is present, all depends on the line encoding method. A single channel
error generates a single bit error in NRZ and a pair of bit errors in NRZI: in the second case the
parity of the frame is preserved, in the first it is not. Because the HDLC FCS provides a parity
check, a single channel error causing the insertion of a 0-bit will always be detected if NRZ is
used: the same may not be guaranteed, and in fact is not true, if NRZI is used. For NRZI and for
frames larger than 40 bits, the probability of an undetected 0-insertion is given by [ChTr93]:

(5) Pr {event C' } = ( 1-BER) 16 • (5 .3 . 10- 4 + 2.9 . 10-6 • (N-40)) . BER . (1-BER)Ns- 1

where the first factor accounts for valid OF and CF, the last factor for the fact that a single
channel error affects the frame, and the intermediate factor accounts for the average number of
bit stuffing 0-bits present in the frame that may be inserted by the error, and for the probability
that the corrupted frame is not detected.

The first order approximation of (5) shows that Pr{event C'} is roughly directly related to BER
and to the frame length, but that the dependency on the frame length is significant only for
frames larger than 256 bits.

An approximate value of Pr(event C') can be computed by counting the probability of an


insertion and multiplying it by 2-15 , which is the probability that the modified frame is not
revealed by the FCS if CRC properties are lost:

6𝑁
• (5') Pr(event C') = (1-BER) 16 • BER . (1-BER)Ns-1 . 2-15
62

(5 ') is an acceptable approximation of (5), especially for long frames (for frames of 1024 bits
the difference is about 10%, The two expressions are asymptotically identical), and this shows
that in fact all properties of the CRC are lost in case of insertion of a 0-bit [FiSa92].

2.4 . Deletion of a 0 Bit (Reason C")

This event occurs when a 0-bit is interpreted as an escape bit and deleted from the frame
because of a preceding erroneously generated sequence of 5 contiguous 1-bits .We consider
only the case of a single error.
The arguments presented in the preceding section hold also in this case. Which is
complementary to the preceeding one: whenever a charnel error may insert a bit in a frame of n
bits, the same error may delete a bit in a frame n+ l bits.
Obviously the number of frames of length n+ l is twice as large as that of frames of length n,
and therefore the probability that a frame with a deleted 0-bit looks legal is half the probability
of a frame with an inserted 0-bit.For nonoctet aligned transmission using NRZI, and for frames
larger than 41 bits it is.
0000
2.5 . Simultaneous Insertion and Deletion of a 0 bit (Reason D)

For octet aligned transmission events C' and C" must occur in equal number in order to simulate a valid
frame . The probability of 8 deletions or 8 insertions is negligible, so we consider only the case of one
insertion and one deletion.
The exact analysis of this case is very difficult, but a good estimate is easily obtained in the hypotheses
that the insertion and deletion events are unrelated, and that all FCS properties are offset by these errors.
The second hypothesis is reasonable for what we said in the preceding sections, and both hypotheses
apply better for long frames. For NRZI we have therefore

A Comprehensive Case Analysis


An approximate RER to BER relationship is obtained from the preceding formulae by adding
all contributions:
(9) RER = Pr { event A } + Pr { event C } + Pr { eventD } + Pr { reason E }
We have computed relation (9) for four different HDLC architectures (the interframe time fill
policy is irrelevant):

• A1 : not octet aligned, NRZ line coding ,

• A2 : not octet aligned, NRZI line coding ,

• A3: octet aligned, NRZ line coding ,

• A4: octet aligned, NRZI line coding .

Even if HDLC does not achieve HD=2, Fig . 4 shows that it can conform to IBC Integrity Class
I1 within a limited but significant range of BER, depending on the HDLC implementation and,
to some extent, on the maximum frame size.

Octet aligned architectures A3 and A4 are conformant to Class I1 for BER ≥ 10 -6


even for
frames of 1024 bits, and for BER ≥ 10-7 for frames of up to 128 hits. The conformance domain
for non octet aligned architectures A l and A2 is more restricted by a factor of almost 100, for
all frame lengths : fortunately these architectures are not very common nowadays, and are not
adopted in PSPDN .

HDLC can conform also to Class I2, but only for overly limited conditions : all architectures
have similar performances because of the slope of the curve that defines Class I2 . HDLC does
not conform to Class I3 for any range of BER . Fig . 5 shows how the frame length affects
different protocol architectures : only octet constrained ar chitectures are considered. Class I2 is
not achieved at BER=10- 4 even for frames of as few as 64 hits . Even if the behavior of 1-DL
C improves by shortening the maximum frame length, this strategy is of no use for BER<l0 -4
(at least from the standpoint of conformance to LEC standards) . Fig . 6 provides a better insight
of the differences between octet aligned architectures A4 and A3 : they are significant only for
high values of BER and of frame length, but remain fundamentally irrelevant in most practical
cases . The dependency of RER on the frame length is quite weak except for very high BER: it
becomes noticeable only for short frames (less than 200 bits), but very short frames may he
impractical because of the high protocol overhead (32 bits, OF and CF for HDLC, but higher
level protocols must also be taken into account) .

3. DISCUSSION

There are several ways to deal with the problems of HDLC, but some of them imply that
conformance to the standard is abandoned, which is often too expensive a price to pay . In other
cases, though, conformance to the generic HDLC standard may be deceptive.

We have so outlined three different strategies to deal with the fragility of HDLC, although the
first two cannot be used in systems that are connected to preexisting or open networks:

1. among the options allowed by the standard. we can select those that provide the highest
reliability ;

2. the implementation may he non conformant to the standard ;

3. we can deal with the problem at a higher protocol level (e .g . the user can )

3.2. Limiting the Maximum Frame Size

In all architectures the probability of undetected errors grows with the frame length, so the
HDLC client can increase its confidence by limiting the packets size . Because the dominant
failure reason (flag simulation) is directly related to the frame length by limiting the maximum
size from 1024 to 128 bits the improvement is of an order of magnitude. This strategy is
compatible with existing networks and is especially suitable for control applications, where
frames are usually intrinsically short.

However, the increasing use of higher level protocols even in special purpose networks (e .g .
[IST92]) makes very short frames useless. Futhermore, this strategy has a very limited scope
since, for instance, it appears effective only to reach integrity Class I1 for values of BER in the
range 10- 7< BER<10-6, or to reach Integrity Class I2 for BER>10- 4 .
A 32-bit FCS has been adopted in Ethernet and in proposals for a standard fieldbus . HDLC
allows the option of a 32 - bit FCS but because of framing and bit stuffing the actual HD
provided by a longer FCS is still 1, so that for BER-a 0 the asymptotic behaviour is of the same
order : RER improves by a factor of about 2- 16 , quite significant for a wid e range of BER.

Unfortunately a 32-bit FCS is not allowed by the most widespread I-IDLC dialects (LAPB and
SDLC) . It is also not generally supported by HDLC oriented components, and this can lead to
implementation difficulties and inefficiencies. Internet PPP, for instance, allows the 32-bit FCS,
but indicates as normal the 16-bit FCS: in fact it gives a fast example implementation only of
the 16-bit FCS algorithm [Perk89].

4. CONCLUSIONS

The paper has shown how the combined effects of transmission errors and of framing or bit
stuffing preempt the error detecting power of the HDLC FCS : RER decreases linearly with
BER rather than with its fourth power, as it should be thanks to the properties of the CRC.

Also the absolute value of RER appears quite unsatisfactory if we consider the 16 bits version
of the FCS that is adopted by the most important HDLC dialects and supported by several
available HDLC controllers.

No practical, evolutionary way seems to exist, that can make HDLC implementions more robust
while keeping conformance to the standard. The 32-bit FCS option is neither adopted, nor
largely supported in practice, and all mechanisms to strongly delimit a frame require substantial
changes to the frame format and the protocol procedures. The most feasible approach, although
suitable only in particular cases, is to add length information to the frame.

Unfortunately the problems due to HDLC framing end escape mechanisms have been
overlooked even in the design of recent protocols such as PPP [Perk89], where nothing has been
done to improve data integrity characteristics (e .g. along the lines discussed in section 3) : the
use of the 32 bit-FCS is allowed but, for practical reasons, not mandated.

The most general approach to achieve higher data integrity in systems involving HDLC based
(sub-) networks, is to let higher level protocols deal with the problem.

Вам также может понравиться