On the network side, by definition all PVCs are always active. Only the
user side detects the active PVCs from the network side. In order to
make higher-layer code agnostic, we need to spoof the related status
events up the stack.
Change-Id: I791a7739e5ee6301ee5c24e5824a15a7b380a655
In quickly repeated test case executions we have the problem that
both the Q.933 LMI detection of link outage/interruption, as well as
the NS-ALIVE mechanism are too slow to detect the outage, and in fact
don't detect the outage. This leads to inconsistent state on both
sides, with one side thinking NS-VCs are still ALIVE/UNBLOCKED, while
the other side considers them DEAD.
A Q.933 conforming transmittere would never send a sequece number of
zero, but always start from one. This means we can use this as
a flag to force the peer to assume a "service affecting condition"
which will make it tell NS that the link went down, etc.
Related: OS#4974
Change-Id: I3e38ade112e11c86db906da9846a966cb33ac1bd
If the link is dead, there's no point in having timers running. T392
will be re-started when the first Q.933 STATUS ENQUIRY is received.
Change-Id: I59b57d123d947cc358c670bc46f8c5df4597815e
AF_PACKET sockets have these incredibly useful semantics in where
for both non-blocking and blocking I/O, they will tell you the
socket is rwite-able, but then still return -1 and sett errno=ENOBUFS
if the current socket buffer / transmit queue is full.
All we can do is usleep and retry. The new module parameter, if set
to non-zero, determines the number of microseconds we shall sleep before
any retry. If set to zero, the existing behavior is preserved:
TTCN_error().
Related: SYS#5343
Change-Id: I1608403d94a10ae52c7e1de0f1b02687b048c01e
An AF_PACKET socket will immediately receive packets of _all_ interfaces
until it is bound to one specific interface. This introduces a race
condition between the socket() and the bind() syscall.
Let's use the ifindex passed for each packet in recvmsg() to drop
any packets received for other interfaces.
Change-Id: Icd0b23eb1d6f75ca3a05e5dd1a569fa389903fdf
Before this patch, we would accidentially detect service-affecting
conditions at start-up until at least N393 cycles of T391 had expired.
Change-Id: I8bd8aa053a8d1ea3f1d366afdff2ceb69341e049