From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36291) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gLOP8-00046D-KQ for qemu-devel@nongnu.org; Sat, 10 Nov 2018 03:14:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gLOP7-00012E-OI for qemu-devel@nongnu.org; Sat, 10 Nov 2018 03:14:06 -0500 From: Luc Michel Date: Sat, 10 Nov 2018 09:11:46 +0100 Message-Id: <20181110081147.4027-16-luc.michel@greensocs.com> In-Reply-To: <20181110081147.4027-1-luc.michel@greensocs.com> References: <20181110081147.4027-1-luc.michel@greensocs.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] [PATCH v5 15/16] gdbstub: add multiprocess extension support List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Luc Michel , qemu-arm@nongnu.org, Peter Maydell , saipava@xilinx.com, edgari@xilinx.com, alistair@alistair23.me, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , mark.burton@greensocs.com, Eduardo Habkost Add multiprocess extension support by enabling multiprocess mode when the peer requests it, and by replying that we actually support it in the qSupported reply packet. Signed-off-by: Luc Michel Reviewed-by: Philippe Mathieu-Daud=C3=A9 Acked-by: Alistair Francis --- gdbstub.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gdbstub.c b/gdbstub.c index c662ada6ff..93a7c956c2 100644 --- a/gdbstub.c +++ b/gdbstub.c @@ -1721,10 +1721,16 @@ static int gdb_handle_packet(GDBState *s, const c= har *line_buf) snprintf(buf, sizeof(buf), "PacketSize=3D%x", MAX_PACKET_LEN= GTH); cc =3D CPU_GET_CLASS(first_cpu); if (cc->gdb_core_xml_file !=3D NULL) { pstrcat(buf, sizeof(buf), ";qXfer:features:read+"); } + + if (strstr(p, "multiprocess+")) { + s->multiprocess =3D true; + } + pstrcat(buf, sizeof(buf), ";multiprocess+"); + put_packet(s, buf); break; } if (strncmp(p, "Xfer:features:read:", 19) =3D=3D 0) { const char *xml; --=20 2.19.1