mirror of
https://github.com/espressif/esp-nimble.git
synced 2026-08-30 05:40:03 +00:00
host/mesh: fix loopback in net
net_buf structure in Zephyr has field user_data, which was wrongly ported as os_mbuf->om_data. To stick with porting net_buf as os_mbuf we can base on old Zephyr's implementation, which was changed in commit dd09cbc1c455ab1e067b53f46bee7b6d50689bbc. Before it, user_data was part of data buffer of net_buf. We can implement this the same way, so data_buf is last N octets of os_mbuf->om_data. Accomodate mbuf allocation and freeing to NimBLE.
This commit is contained in:
committed by
Krzysztof Kopyściński
parent
a17ed2a1da
commit
bc142016bd
@@ -772,6 +772,10 @@
|
||||
#endif
|
||||
|
||||
/* Overridden by @apache-mynewt-nimble/porting/targets/linux_blemesh (defined by @apache-mynewt-nimble/nimble/host/mesh) */
|
||||
#ifndef MYNEWT_VAL_BLE_MESH_NET_BUF_USER_DATA_SIZE
|
||||
#define MYNEWT_VAL_BLE_MESH_NET_BUF_USER_DATA_SIZE (4)
|
||||
#endif
|
||||
|
||||
#ifndef MYNEWT_VAL_BLE_MESH_ADV_BUF_COUNT
|
||||
#define MYNEWT_VAL_BLE_MESH_ADV_BUF_COUNT (20)
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user