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

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

commit 28cf56ce4f85d3f32bfd1703ae56e736aa2cf4ce
Author: Neo Xu <neo.xu1...@gmail.com>
AuthorDate: Wed Feb 5 11:29:28 2025 +0800

    gdbstub: fix memory binary upload on latest GDB
    
    GDB release 16.2 recently to fix the incompatibility issue with LLDB.
    For us, the only change is stub must report it support feature 
'binary-upload' before GDB will use this feature.
    For more information, find bug report and discussion in 
https://sourceware.org/bugzilla/show_bug.cgi?id=32593
    
    Use GDB 16.2, now it works with binary upload.
    ```
      [remote] Sending packet: $x39c,4#a7
      [remote] Received Ack
      [remote] Packet received: b\000\203
    ```
    
    Signed-off-by: Neo Xu <neo.xu1...@gmail.com>
---
 libs/libc/gdbstub/lib_gdbstub.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libs/libc/gdbstub/lib_gdbstub.c b/libs/libc/gdbstub/lib_gdbstub.c
index bbc5a8e0c8..ca72821c98 100644
--- a/libs/libc/gdbstub/lib_gdbstub.c
+++ b/libs/libc/gdbstub/lib_gdbstub.c
@@ -1387,11 +1387,11 @@ static int gdb_query(FAR struct gdb_state_s *state)
     {
 #ifdef CONFIG_ARCH_HAVE_DEBUG
       state->pkt_len = sprintf(state->pkt_buf,
-                               "hwbreak+;PacketSize=%zx",
+                               "binary-upload+;hwbreak+;PacketSize=%zx",
                                sizeof(state->pkt_buf));
 #else
       state->pkt_len = sprintf(state->pkt_buf,
-                               "PacketSize=%zx",
+                               "binary-upload+;PacketSize=%zx",
                                sizeof(state->pkt_buf));
 #endif
       gdb_send_packet(state);

Reply via email to