zephyr/tests/net/nbuf
Ravi kumar Veeramally 58ba1d834e net: nbuf: Fix net_nbuf_compact() API
Current API description of net_nbuf_compact() is not very clear.
The first parameter needs to be the first net_buf in the chain.

The changes to this API are needed in order to clarify following
use cases:
1) User provides fragment that is not first of the chain and compact is
successfully done. In this case there is no free space in fragment list
after the input fragment. But there might be empty space in previous
fragments. So fragment chain is not completely compacted.

2) What if input fragment has been deleted and api returns the same
buf?

So this commit simplifies the API behavior. Now net_nbuf_compact()
expects the first parameter to be either TX or RX net_buf and then it
compacts it. It fails only if the input fragment is a data fragment.

Change-Id: I9e02dfcb6f3f2e2998826522a25ec207850a8056
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
2017-02-08 10:12:36 +02:00
..
src net: nbuf: Fix net_nbuf_compact() API 2017-02-08 10:12:36 +02:00
Makefile tests: introduce Makefile.test 2017-01-03 17:48:44 +00:00
prj.conf net: buf: Change NET_BUF_DEBUG to NET_BUF_LOG and add a level option 2017-01-02 10:03:17 +01:00
testcase.ini tests: net: Change the tag of network tests to net 2016-12-02 12:41:11 +02:00