diff options
author | Harald Welte <laforge@gnumonks.org> | 2015-12-05 11:54:08 +0100 |
---|---|---|
committer | Harald Welte <laforge@gnumonks.org> | 2015-12-05 11:54:08 +0100 |
commit | 2d5481da278f8b09c4772d54f044ba2b26eeef14 (patch) | |
tree | 1f32dd61bc9eee7b3123e5ce97129941d8f383eb /doc | |
parent | 44bc9408b1dcc4d07f8aff9800d8fcf317954231 (diff) |
l1sap: Ensure we only pass PHY primitives of active lchans
In some situations, a PHY might send us a primitive for a logical
channel that is not (or no longer) active. Passing such primitives
higher up the stack is asking for trouble. Specifically, LAPDm
instances cannot accept messages once their instance has been released.
We introduce two new helper functions: get_lchan_by_chan_nr() as well as
get_active_lchan_by_chan_nr(). The former just centralizes the look-up
of the lchan by timeslot number and sub-slot number. The latter also
checks to ensure the lchan is active, which is used for PH-DATA / PH-RTS
primitives. To the contrary, MPH primitives generally don't require the
cahnnel to be active for processing.
Diffstat (limited to 'doc')
0 files changed, 0 insertions, 0 deletions