This is an automated email from the ASF dual-hosted git repository.

pkarashchenko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git


The following commit(s) were added to refs/heads/master by this push:
     new a16fb23dd lte/alt1250: Notice instance information
a16fb23dd is described below

commit a16fb23dd752e84849ffcf865fc5d6d5ac745e43
Author: SPRESENSE <41312067+sprese...@users.noreply.github.com>
AuthorDate: Thu Jun 15 05:57:15 2023 +0900

    lte/alt1250: Notice instance information
    
    Notice instance information of LwM2M server operation to application.
---
 include/lte/lte_lwm2m.h                     | 3 ++-
 lte/alt1250/callback_handlers/alt1250_evt.c | 6 ++++--
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/include/lte/lte_lwm2m.h b/include/lte/lte_lwm2m.h
index 4bbc793a5..c9fc564a1 100644
--- a/include/lte/lte_lwm2m.h
+++ b/include/lte/lte_lwm2m.h
@@ -250,7 +250,8 @@ typedef CODE void (*lwm2mstub_ovstart_cb_t)(int seq_no, int 
srv_id,
 typedef CODE void (*lwm2mstub_ovstop_cb_t)(int seq_no, int srv_id,
               FAR struct lwm2mstub_instance_s *inst, FAR char *token);
 
-typedef CODE void (*lwm2mstub_operation_cb_t)(int event);
+typedef CODE void (*lwm2mstub_operation_cb_t)(int event, int srv_id,
+                   FAR struct lwm2mstub_instance_s *inst);
 
 typedef CODE void (*lwm2mstub_fwupstate_cb_t)(int event);
 
diff --git a/lte/alt1250/callback_handlers/alt1250_evt.c 
b/lte/alt1250/callback_handlers/alt1250_evt.c
index a2ab7782a..73bf1a840 100644
--- a/lte/alt1250/callback_handlers/alt1250_evt.c
+++ b/lte/alt1250/callback_handlers/alt1250_evt.c
@@ -638,9 +638,10 @@ static FAR void *g_lwm2movstopargs[] =
 
 /* event argument for LTE_CMDID_LWM2M_SERVEROP_EVT */
 
+static struct lwm2mstub_instance_s g_lwm2msrvop_inst;
 static FAR void *g_lwm2moperationargs[] =
 {
-  NULL
+  NULL, NULL, &g_lwm2msrvop_inst
 };
 
 /* event argument for LTE_CMDID_LWM2M_FWUP_EVT */
@@ -1445,7 +1446,8 @@ static uint64_t lwm2m_operation_evt_cb(FAR void *cb, FAR 
void **cbarg,
 
   if (callback)
     {
-      callback((int)cbarg[0]);
+      callback((int)cbarg[0], (int)cbarg[1],
+               (FAR struct lwm2mstub_instance_s *)cbarg[2]);
     }
 
   return 0ULL;

Reply via email to