mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
19235: pkg/nimble/autoadv: fix flag comparisons r=benpicco a=kaspar030 19236: sys/vfs: vfs.c missing includes r=benpicco a=kaspar030 19237: sys/net/crosslayer/inet_csum: add missing "modules.h" include r=benpicco a=kaspar030 19238: sys/net/grnc/netreg: avoid creating an infinite loop r=benpicco a=benpicco Co-authored-by: Kaspar Schleiser <kaspar@schleiser.de> Co-authored-by: Benjamin Valentin <benjamin.valentin@ml-pa.com>
This commit is contained in:
commit
247b8d0a47
@ -192,11 +192,11 @@ void nimble_autoadv_start(ble_addr_t *addr)
|
||||
if (addr != NULL) {
|
||||
mode = BLE_GAP_CONN_MODE_DIR;
|
||||
}
|
||||
else if (_cfg.flags && NIMBLE_AUTOADV_FLAG_CONNECTABLE) {
|
||||
else if (_cfg.flags & NIMBLE_AUTOADV_FLAG_CONNECTABLE) {
|
||||
mode = BLE_GAP_CONN_MODE_UND;
|
||||
}
|
||||
uint8_t disc = (_cfg.flags && NIMBLE_AUTOADV_FLAG_SCANNABLE) ? BLE_GAP_CONN_MODE_DIR
|
||||
: BLE_GAP_CONN_MODE_UND;
|
||||
uint8_t disc = (_cfg.flags & NIMBLE_AUTOADV_FLAG_SCANNABLE) ? BLE_GAP_CONN_MODE_DIR
|
||||
: BLE_GAP_CONN_MODE_UND;
|
||||
struct ble_gap_adv_params advp = {
|
||||
.conn_mode = mode,
|
||||
.disc_mode = disc,
|
||||
|
@ -14,6 +14,8 @@
|
||||
|
||||
#include <inttypes.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#include "modules.h"
|
||||
#include "od.h"
|
||||
#include "net/inet_csum.h"
|
||||
|
||||
|
@ -152,6 +152,13 @@ int gnrc_netreg_register(gnrc_nettype_t type, gnrc_netreg_entry_t *entry)
|
||||
}
|
||||
|
||||
_gnrc_netreg_acquire_exclusive();
|
||||
|
||||
/* don't add the same entry twice */
|
||||
gnrc_netreg_entry_t *e;
|
||||
LL_FOREACH(netreg[type], e) {
|
||||
assert(entry != e);
|
||||
}
|
||||
|
||||
LL_PREPEND(netreg[type], entry);
|
||||
_gnrc_netreg_release_exclusive();
|
||||
|
||||
|
@ -23,6 +23,8 @@
|
||||
#include <fcntl.h> /* for O_ACCMODE, ..., fcntl */
|
||||
#include <unistd.h> /* for STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO */
|
||||
|
||||
#include "container.h"
|
||||
#include "modules.h"
|
||||
#include "vfs.h"
|
||||
#include "mutex.h"
|
||||
#include "thread.h"
|
||||
|
Loading…
Reference in New Issue
Block a user