Skip to content

Commit

Permalink
[nrf fromlist] manifest: net: openthread: Regular openthread upmerge …
Browse files Browse the repository at this point in the history
…to `e10a925`.

Regular openthread upmerge to `e10a92570f94ff1e0bc5e0da9ecf0ee135d955a6`.

Additionally commit aligns platform implementation with diag changes:
openthread/openthread#10354

based on:
openthread/ot-nrf528xx#822

Upstream PR: zephyrproject-rtos/zephyr#75088

Signed-off-by: Maciej Baczmanski <[email protected]>
  • Loading branch information
maciejbaczmanski committed Jul 29, 2024
1 parent 8733cdc commit 17f0600
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 9 deletions.
36 changes: 28 additions & 8 deletions modules/openthread/platform/diag.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,39 @@
*
*/
static bool sDiagMode;
static void *sDiagCallbackContext;
static otPlatDiagOutputCallback sDiagOutputCallback;

otError otPlatDiagProcess(otInstance *aInstance,
uint8_t argc,
char *argv[],
char *aOutput,
size_t aOutputMaxLen)
static void diag_output(const char *aFormat, ...)
{
va_list args;

va_start(args, aFormat);

if (sDiagOutputCallback != NULL) {
sDiagOutputCallback(aFormat, args, sDiagCallbackContext);
}

va_end(args);
}

void otPlatDiagSetOutputCallback(otInstance *aInstance,
otPlatDiagOutputCallback aCallback,
void *aContext)
{
OT_UNUSED_VARIABLE(aInstance);

sDiagOutputCallback = aCallback;
sDiagCallbackContext = aContext;
}

otError otPlatDiagProcess(otInstance *aInstance, uint8_t aArgsLength, char *aArgs[])
{
ARG_UNUSED(argc);
ARG_UNUSED(aInstance);
ARG_UNUSED(aArgsLength);

/* Add more platform specific diagnostics features here. */
snprintk(aOutput, aOutputMaxLen,
"diag feature '%s' is not supported\r\n", argv[0]);
diag_output("diag feature '%s' is not supported\r\n", aArgs[0]);

return OT_ERROR_NOT_IMPLEMENTED;
}
Expand Down
2 changes: 1 addition & 1 deletion west.yml
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ manifest:
revision: da78aea63159771956fe0c9263f2e6985b66e9d5
path: modules/lib/open-amp
- name: openthread
revision: 3873c6fcd5a8a9dd01b71e8efe32ef5dc7923bb1
revision: e10a92570f94ff1e0bc5e0da9ecf0ee135d955a6
path: modules/lib/openthread
- name: percepio
path: modules/debug/percepio
Expand Down

0 comments on commit 17f0600

Please sign in to comment.