[posix-app] adopt new HDLC buffer models (#3371)

This commit updates the `HdlcInterface` and `RadioSpinel` to use the
new HDLC buffer model. In particular, for received spinel frames the
decoder uses an `Hdlc::MultiFrameBuffer` which is capable of storing
multiple frames in a FIFO queue manner.

With this model, the received and decoded spinel frames are directly
placed in the FIFO buffer. This allows `RadioSpinel` code during
`WaitResponse()` (when waiting for specific Spinel response frame) to
simply save/keep a notification frame in the queue buffer (without
requiring to copy the frame) so that it can read and process the
saved frame later. If a received frame can be processed at the time,
the frame is then simply discarded from the queue buffer.
This commit is contained in:
Abtin Keshavarzian
2018-12-21 14:33:35 -08:00
committed by Jonathan Hui
parent e96cc1b367
commit 34004c2c57
8 changed files with 126 additions and 451 deletions
-1
View File
@@ -205,7 +205,6 @@ LOCAL_SRC_FILES := \
src/ncp/spinel_decoder.cpp \
src/ncp/spinel_encoder.cpp \
src/posix/platform/alarm.c \
src/posix/platform/frame_queue.cpp \
src/posix/platform/hdlc_interface.cpp \
src/posix/platform/logging.c \
src/posix/platform/misc.c \