Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 18 additions & 4 deletions modules/openthread/platform/diag.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,16 @@ otError otPlatDiagProcess(otInstance *aInstance, uint8_t aArgsLength, char *aArg

void otPlatDiagModeSet(bool aMode)
{
otError error;

sDiagMode = aMode;

if (!sDiagMode) {
otPlatRadioSleep(NULL);
error = otPlatRadioSleep(NULL);
if (error != OT_ERROR_NONE) {
otPlatLog(OT_LOG_LEVEL_WARN, OT_LOG_REGION_PLATFORM,
"%s failed (%d)", "otPlatRadioSleep", error);
}
}
}

Expand Down Expand Up @@ -345,6 +351,7 @@ static otError startModCarrier(otInstance *aInstance, uint8_t aArgsLength, char
void otPlatDiagAlarmCallback(otInstance *aInstance)
{
uint32_t now;
otError error;
otRadioFrame *txPacket;
const uint16_t diag_packet_len = 30;

Expand All @@ -370,7 +377,11 @@ void otPlatDiagAlarmCallback(otInstance *aInstance)
txPacket->mPsdu[i] = i;
}

otPlatRadioTransmit(aInstance, txPacket);
error = otPlatRadioTransmit(aInstance, txPacket);
if (error != OT_ERROR_NONE) {
otPlatLog(OT_LOG_LEVEL_WARN, OT_LOG_REGION_PLATFORM,
"%s failed (%d)", "otPlatRadioTransmit", error);
}

if (sTxCount != -1) {
sTxCount--;
Expand Down Expand Up @@ -405,8 +416,11 @@ static otError processTransmit(otInstance *aInstance, uint8_t aArgsLength, char
otPlatAlarmMilliStop(aInstance);
diag_output("diagnostic message transmission is stopped\r\n");
sTransmitMode = DIAG_TRANSMIT_MODE_IDLE;
otPlatRadioReceive(aInstance, sChannel);

error = otPlatRadioReceive(aInstance, sChannel);
if (error != OT_ERROR_NONE) {
otPlatLog(OT_LOG_LEVEL_WARN, OT_LOG_REGION_PLATFORM,
"%s failed (%d)", "otPlatRadioReceive", error);
}
} else if (strcmp(aArgs[0], "start") == 0) {
if (sTransmitMode != DIAG_TRANSMIT_MODE_IDLE) {
return OT_ERROR_INVALID_STATE;
Expand Down
5 changes: 3 additions & 2 deletions subsys/net/openthread/rpc/server/ot_rpc_netdiag.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ static size_t ot_rpc_network_diag_tlv_size(otNetworkDiagTlv *aNetworkDiagTlv)
static void ot_rpc_encode_network_diag_tlv(struct nrf_rpc_cbor_ctx *ctx,
otNetworkDiagTlv *aNetworkDiagTlv)
{
uint8_t mode;
nrf_rpc_encode_uint(ctx, aNetworkDiagTlv->mType);

switch (aNetworkDiagTlv->mType) {
Expand All @@ -83,7 +84,7 @@ static void ot_rpc_encode_network_diag_tlv(struct nrf_rpc_cbor_ctx *ctx,
nrf_rpc_encode_buffer(ctx, aNetworkDiagTlv->mData.mEui64.m8, OT_EXT_ADDRESS_SIZE);
break;
case OT_NETWORK_DIAGNOSTIC_TLV_MODE:
uint8_t mode = 0;
mode = 0;

WRITE_BIT(mode, 0, aNetworkDiagTlv->mData.mMode.mRxOnWhenIdle);
WRITE_BIT(mode, 1, aNetworkDiagTlv->mData.mMode.mDeviceType);
Expand Down Expand Up @@ -210,7 +211,7 @@ static void ot_rpc_encode_network_diag_tlv(struct nrf_rpc_cbor_ctx *ctx,
nrf_rpc_encode_uint(ctx, aNetworkDiagTlv->mData.mChildTable.mCount);
zcbor_list_start_encode(ctx->zs, aNetworkDiagTlv->mData.mChildTable.mCount);
for (int i = 0; i < aNetworkDiagTlv->mData.mChildTable.mCount; i++) {
uint8_t mode = 0;
mode = 0;

nrf_rpc_encode_uint(ctx,
aNetworkDiagTlv->mData.mChildTable.mTable[i].mTimeout);
Expand Down
3 changes: 3 additions & 0 deletions subsys/nrf_security/src/drivers/cracen/cracenpsa/src/kmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -294,11 +294,14 @@ static psa_status_t get_kmu_slot_id_and_metadata(mbedtls_svc_key_id_t key_id,
return read_primary_slot_metadata(*slot_id, metadata);
}

#if defined(CONFIG_PSA_WANT_ALG_PURE_EDDSA) || defined(CONFIG_PSA_WANT_ALG_ED25519PH) || \
defined CONFIG_PSA_WANT_ALG_ECDSA || defined(CONFIG_PSA_WANT_ALG_HMAC)
static bool can_sign(const psa_key_attributes_t *key_attr)
{
return (psa_get_key_usage_flags(key_attr) & PSA_KEY_USAGE_SIGN_MESSAGE) ||
(psa_get_key_usage_flags(key_attr) & PSA_KEY_USAGE_SIGN_HASH);
}
#endif /* defined(CONFIG_PSA_WANT_ALG_PURE_EDDSA) || define(CONFIG_PSA_WANT_ALG_ED25519PH) */

/**
* @brief Check provisioning state, and delete slots that were not completely provisioned.
Expand Down
2 changes: 2 additions & 0 deletions subsys/nrf_security/src/drivers/cracen/cracenpsa/src/sign.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
#define SI_PSA_IS_KEY_FLAG(flag, attr) ((flag) == (psa_get_key_usage_flags((attr)) & (flag)))
#define SI_PSA_IS_KEY_TYPE(flag, attr) ((flag) == (psa_get_key_type((attr)) & (flag)))

#if PSA_MAX_RSA_KEY_BITS > 0
static int cracen_signature_set_hashalgo(const struct sxhashalg **hashalg, psa_algorithm_t alg)
{
return hash_get_algo(PSA_ALG_SIGN_GET_HASH(alg), hashalg);
Expand Down Expand Up @@ -81,6 +82,7 @@ static int cracen_signature_set_hashalgo_from_digestsz(const struct sxhashalg **

return SX_OK;
}
#endif /* PSA_MAX_RSA_KEY_BITS > 0 */

static int cracen_signature_prepare_ec_prvkey(struct si_sig_privkey *privkey, char *key_buffer,
size_t key_buffer_size,
Expand Down
4 changes: 2 additions & 2 deletions west.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ manifest:
# https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/guides/modules.html
- name: zephyr
repo-path: sdk-zephyr
revision: 9ad6673058ccaee61f976bcb3d6d203be94bfdc7
revision: 4ff1c3616aeecb52617d87bfdf2da0435f36fb17
import:
# In addition to the zephyr repository itself, NCS also
# imports the contents of zephyr/west.yml at the above
Expand Down Expand Up @@ -144,7 +144,7 @@ manifest:
- name: nrfxlib
repo-path: sdk-nrfxlib
path: nrfxlib
revision: b90a6248dcb5caa7e8b17d1e24b01703508170e4
revision: 5f9842bf8fa8e1ed1883c1e65e7a61fcb1c7e4e2
- name: trusted-firmware-m
repo-path: sdk-trusted-firmware-m
path: modules/tee/tf-m/trusted-firmware-m
Expand Down
Loading