According Mesh Spec 1.0.1 Section 7.2.2.2.1 Advertising
A node that does not support the Proxy feature or has the Proxy
feature disabled shall not advertise with Network ID.
Signed-off-by: Lingao Meng <mengabc1086@gmail.com>
Be consistent in the permission handling of the discovered attribute
in the temporary object given in the discovery callback.
For characteristics the permission field was set to READ, while for
all other attributes it was set to 0.
Fixes: #29083
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Update check in the bt_gatt_attr_value_handle API function to use the
UUID of the function, in case the attribute has been declared with a
different read handler, or the attribute is a temporary object
where the read attribute has not been set.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Clip the timeout to 64 seconds, this avoids the timeout value to
increase to high values (e.g. several years).
Signed-off-by: Armand Ciejak <armand@riedonetworks.com>
This avoids code duplication. The same logic was present
in dhcpv4_send_request() and dhcpv4_send_discover().
Signed-off-by: Armand Ciejak <armand@riedonetworks.com>
The TCP2 was calling accept callback before actually finalizing
the connection attempt.
Fixes#29164
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
Refactor use of 16-bit common GATT UUID types where a complete UUID
object is declared on the stack only to use the 16-bit value.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Reduce the size of the disconnect pool required the full MTU
for a disconnect request.
Also completely remove the pool when not needed.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
OSDP secure channel require a truly random number generator
source. Make this dependency explicit.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
Fix the missing return statement when Auxiliary PDU
transmission is aborted because Primary PDU does not have
the aux pointer setup. Also, directly stop clocks and
post LLL done, like being done in other state/role LLL.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Minor Extended Advertising conditional compilation reorder
to better reflect the order Observer->Extended Scanning
dependency.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
NODE_RX_TYPE_EXT_ADV_TERMINATE is generated in ULL context
and shall not increment received PDU quota value.
Fixes#29101.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
A normal websocket close sequence:
close(websock) ->
websocket_close_vmeth() ->
websocket_disconnect()
close(ctx->sock) called in the function websocket_disconnect()
and cause websocket_close_vmeth() called again.
Finally stack overflow by loop close call.
It's maybe a side-effect by PR #27485
Signed-off-by: Jackie Ja <qazq.jackie@gmail.com>
The existing calculation of the BULK_EP size can sometimes result in a
bulk EP size that is not spec-compliant. The accepted BULK_EP sizes are
8, 16, 32 or 64 bytes.
Additionally, the INT_EP size is always set to the max EP size since
BT_BUF_RX_SIZE is always greater than that (min. 73 in Kconfig).
This commit sets the BULK and INT endpoint sizes to their maximum
supported values.
Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
Port minor anchor point synchronization drift implementation
changes.
Relates to changes in commit 732de50f67 ("Bluetooth:
controller: Refactor out drift compensation code").
Fixes#29062.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Default shell stack size is not always enough when used with
OpenThread. Increasing it to the found adequate value.
Signed-off-by: Eduardo Montoya <eduardo.montoya@nordicsemi.no>
Fix a compilation error when shell help feature was not selected and
but shell help command was compiled.
Fixes: #29042
Signed-off-by: Jakub Rzeszutko <jakub.rzeszutko@nordicsemi.no>
This patch adds Secure Channel capabilities to osdp Control Panel and
Peripheral Device modes.
Signed-off-by: Siddharth Chandrasekaran <siddharth@embedjournal.com>
Improve token handling by removing special meaning of tokenlen == 0,
which allows to handle server requests w/o a token (so far such
requests would cause the lwm2m engine to autogenerate token in the
response).
In order to autogenerate token during message initialization, use
special symbol `LWM2M_MSG_TOKEN_GENERATE_NEW`. If no token is wished to
be used, simply set the tokenlen to 0.
Additionally, fix an issue with token autogeneration, where invalid
token len was used (0 instead of 8).
Fixes#28299
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
LwM2M engine did not set response code for the Bootstrap-finish message,
hence it replied with the code copied from the request which is not
correct. Fix this by setting correct code for the Bootstrap-finish
reply.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
The error handling code currently has a couple of issues:
* It relies on ordered lists and upstream not changing any constants.
* Converted messages are not stored in constant memory which means
that log_strdup is needed whenever they are printed.
This change also factors out error handling to a separate file,
lw_priv.{c,h}, to facilitate reuse in a future secure element and
state storage implementation.
Signed-off-by: Andreas Sandberg <andreas@sandberg.pp.se>
For consistency with other parts of Zephyr, the public APIs available
in lorawan subsystem now returns error codes from the set defined in
errno.h.
Signed-off-by: Kuba Sanak <contact@kuba.fyi>
[mani: reworked the code and commit a bit for upstream]
Signed-off-by: Manivannan Sadhasivam <mani@kernel.org>
SystemMaxRxError is used to negotiate overall timing error for Rx
in the loramac-node library. Hence, add support for configuring this
parameter from Kconfig.
Signed-off-by: Kuba Sanak <contact@kuba.fyi>
Signed-off-by: Manivannan Sadhasivam <mani@kernel.org>
Add initial support for LoRaWAN based on Semtech's loramac-node
library. Current implementation only supports OTAA config and
sending data to LoRaWAN server like ThingsNetwork.
While at it, this commit also moves the "loramac-node" library
definition from drivers/lora to subsys/lorawan. This is required
because, subsys/lorawan gets processed before drivers/lora and
that creates issue while building.
Signed-off-by: Manivannan Sadhasivam <mani@kernel.org>
Add assert check to detect failure to enqueue ticker
operations. This will avoid HCI thread from stalling
forever on k_sem_take.
This assert will trigger on design fault, not defining
enough queued ticker operations count.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
The logging subsytsem had if else if constructs without final
else statement. This commit adds else {} to comply with
coding guideline 15.7.
Signed-off-by: Jennifer Williams <jennifer.m.williams@intel.com>
Added a missing NULL pointer dereference check and made the
structure member scan->per_scan.sync and timeout_reload as
volatile, as they are modified in ISR context.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Added link structure allocation explanation related to HCI
event generation by the controller.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Add Experimental keyword to LE Periodic Advertising in
Advertising and Synchronization state Kconfig title.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>