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

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

commit 18c4c2ff00b68704899262d9c7bef6f835e08dfb
Author: wangyongrong <[email protected]>
AuthorDate: Wed Jul 1 10:22:31 2026 +0800

    drivers/clk/clk_rpmsg: drop the response flag from the message header
    
    The response field told the shared endpoint callback a request from a
    reply. With a separate callback per endpoint the endpoint already tells
    them apart, so remove the field and its uses.
    
    This changes the message layout: both sides of a clk rpmsg link must
    run the same version.
    
    Signed-off-by: wangyongrong <[email protected]>
---
 drivers/clk/clk_rpmsg.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/clk/clk_rpmsg.c b/drivers/clk/clk_rpmsg.c
index b016e7578e2..30aec3cdd99 100644
--- a/drivers/clk/clk_rpmsg.c
+++ b/drivers/clk/clk_rpmsg.c
@@ -86,7 +86,6 @@ struct clk_rpmsg_cookie_s
 begin_packed_struct struct clk_rpmsg_header_s
 {
   uint32_t                  command;
-  uint32_t                  response;
   int64_t                   result;
   uint64_t                  cookie;
 } end_packed_struct;
@@ -486,7 +485,6 @@ static int64_t clk_rpmsg_sendrecv(FAR struct rpmsg_endpoint 
*ept,
   int ret;
 
   msg->command  = command;
-  msg->response = 0;
   msg->cookie   = (uintptr_t)&cookie;
 
   nxsem_init(&cookie.sem, 0, 0);
@@ -610,7 +608,6 @@ static int clk_rpmsg_server_ept_cb(FAR struct 
rpmsg_endpoint *ept,
 
   if (cmd < nitems(g_clk_rpmsg_handler) && g_clk_rpmsg_handler[cmd])
     {
-      hdr->response = 1;
       ret = g_clk_rpmsg_handler[cmd](ept, data, len, src, priv);
     }
 
@@ -629,7 +626,7 @@ static int clk_rpmsg_client_ept_cb(FAR struct 
rpmsg_endpoint *ept,
   FAR struct clk_rpmsg_cookie_s *cookie =
     (FAR struct clk_rpmsg_cookie_s *)(uintptr_t)hdr->cookie;
 
-  if (hdr->response && cookie)
+  if (cookie)
     {
       cookie->result = hdr->result;
       nxsem_post(&cookie->sem);

Reply via email to