From nobody Wed May 8 04:22:48 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1606269727; cv=none; d=zohomail.com; s=zohoarc; b=S6w3TUpEi23w4s39V7P+y8pVULt3vMohKZRFZH6CnflhlcXYqNZL4yE6OwdcSROW+wvb818gzRk5nfCB6RNFgs4G5BD4B+pIylvsFCzYbCIBfIjF4pLswO3PAOxXT3FBsgek51oX5PMQVM7m3CziY6jezuSjjdYid8rKh8JeqXE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1606269727; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=EE0goE6UCco7mSpICheD7Ed8npKZGY0oqA7ZohoEvI0=; b=PzKC7NN880crG5oBEvb1j3R5mn26oXaVm/o5Xxs+P9ouBUwJazDQYvN5o0lsUYizoYmRALelVI6hpdcm5UfS8BBpkygxlMnmvz6sJIIxY7AUdPWUKmA++3ByknYWJiSIxIbhUFYshdaY+ykmnsonF4SZ8/sr1FusV6JKkto9Xxw= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1606269727022225.2509635240525; Tue, 24 Nov 2020 18:02:07 -0800 (PST) Received: from localhost ([::1]:54586 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1khk85-000272-9S for importer@patchew.org; Tue, 24 Nov 2020 21:01:57 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:37074) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1khk43-0007nr-OI for qemu-devel@nongnu.org; Tue, 24 Nov 2020 20:57:47 -0500 Received: from szxga04-in.huawei.com ([45.249.212.190]:2866) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1khk41-0007OX-37 for qemu-devel@nongnu.org; Tue, 24 Nov 2020 20:57:47 -0500 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.58]) by szxga04-in.huawei.com (SkyGuard) with ESMTP id 4CgkXg20wPz15Rgf; Wed, 25 Nov 2020 09:57:07 +0800 (CST) Received: from huawei.com (10.175.124.27) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.487.0; Wed, 25 Nov 2020 09:57:21 +0800 From: Yutao Ai To: , Subject: [PATCH 1/3] monitor:open brace '{' following struct go on the same line Date: Wed, 25 Nov 2020 01:45:12 +0000 Message-ID: <20201125014514.55562-2-aiyutao@huawei.com> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20201125014514.55562-1-aiyutao@huawei.com> References: <20201125014514.55562-1-aiyutao@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.175.124.27] X-CFilter-Loop: Reflected Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=45.249.212.190; envelope-from=aiyutao@huawei.com; helo=szxga04-in.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alex.chen@huawei.com, aiyutao@huawei.com, qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" Move the open brace '{' following struct go on the same line Signed-off-by: Yutao Ai --- monitor/hmp-cmds.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c index 8d7f5fee7e..64188c9fa2 100644 --- a/monitor/hmp-cmds.c +++ b/monitor/hmp-cmds.c @@ -1548,8 +1548,7 @@ end: hmp_handle_error(mon, err); } =20 -typedef struct HMPMigrationStatus -{ +typedef struct HMPMigrationStatus { QEMUTimer *timer; Monitor *mon; bool is_block_migration; --=20 2.19.1 From nobody Wed May 8 04:22:48 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1606269585; cv=none; d=zohomail.com; s=zohoarc; b=WMQPF5eQvYsPPVCTcQcbPFtb31dv7bt0dmqCKmk3Q0z1XYNbBVcZwQOoO/K1kcI8M6GrdM7WTwb7vX+Euj5SaBYVoIA/szXD29F0z8zUPaThanShuDqr7YAmeU5GlbWNpcaGxBcdJZYx+F6eo0Mf2a8BbhqooCgeWLlDqRADns0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1606269585; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=6PI7T73vNlcirsQiXLN2cSQVfwyPIkBFvkIU24FSEjQ=; b=AG6YdekIxQKj+TIDiUxRiTHS+X+gH4R+vB70xD5Xw9LE6vba4BKQoL6DTngm/GmAX0Or0X516/tsWvl6t68C5aOw4AXdZeoh0areakqVvYIJ2sa570D7mOuNA94+CIGyBPS24fyHLda7swbPYqp0nuZQQ/D7L2uN9yJyy3HdC/s= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1606269585502649.315664986373; Tue, 24 Nov 2020 17:59:45 -0800 (PST) Received: from localhost ([::1]:51196 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1khk5w-0000Wf-7f for importer@patchew.org; Tue, 24 Nov 2020 20:59:44 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:37092) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1khk44-0007o8-VU for qemu-devel@nongnu.org; Tue, 24 Nov 2020 20:57:49 -0500 Received: from szxga06-in.huawei.com ([45.249.212.32]:2099) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1khk41-0007P9-3n for qemu-devel@nongnu.org; Tue, 24 Nov 2020 20:57:48 -0500 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga06-in.huawei.com (SkyGuard) with ESMTP id 4CgkXs2Vl5zhYm4; Wed, 25 Nov 2020 09:57:17 +0800 (CST) Received: from huawei.com (10.175.124.27) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.487.0; Wed, 25 Nov 2020 09:57:22 +0800 From: Yutao Ai To: , Subject: [PATCH 2/3] monitor:braces {} are necessary for all arms of this statement Date: Wed, 25 Nov 2020 01:45:13 +0000 Message-ID: <20201125014514.55562-3-aiyutao@huawei.com> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20201125014514.55562-1-aiyutao@huawei.com> References: <20201125014514.55562-1-aiyutao@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.175.124.27] X-CFilter-Loop: Reflected Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=45.249.212.32; envelope-from=aiyutao@huawei.com; helo=szxga06-in.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alex.chen@huawei.com, aiyutao@huawei.com, qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" Fix the errors by add {} Signed-off-by: Yutao Ai --- monitor/misc.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/monitor/misc.c b/monitor/misc.c index 398211a034..7588f12053 100644 --- a/monitor/misc.c +++ b/monitor/misc.c @@ -492,8 +492,10 @@ static void hmp_singlestep(Monitor *mon, const QDict *= qdict) static void hmp_gdbserver(Monitor *mon, const QDict *qdict) { const char *device =3D qdict_get_try_str(qdict, "device"); - if (!device) + if (!device) { device =3D "tcp::" DEFAULT_GDBSTUB_PORT; + } + if (gdbserver_start(device) < 0) { monitor_printf(mon, "Could not open gdbserver on device '%s'\n", device); @@ -559,10 +561,11 @@ static void memory_dump(Monitor *mon, int count, int = format, int wsize, } =20 len =3D wsize * count; - if (wsize =3D=3D 1) + if (wsize =3D=3D 1) { line_size =3D 8; - else + } else { line_size =3D 16; + } max_digits =3D 0; =20 switch(format) { @@ -583,10 +586,11 @@ static void memory_dump(Monitor *mon, int count, int = format, int wsize, } =20 while (len > 0) { - if (is_physical) + if (is_physical) { monitor_printf(mon, TARGET_FMT_plx ":", addr); - else + } else { monitor_printf(mon, TARGET_FMT_lx ":", (target_ulong)addr); + } l =3D len; if (l > line_size) l =3D line_size; --=20 2.19.1 From nobody Wed May 8 04:22:48 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1606269938; cv=none; d=zohomail.com; s=zohoarc; b=n1USHmnKHsDm+guf9/GbAEBEoLN0aDAJMtl8M1uooEAVYvN8y2DJ94vOGhC3yhnICJWDmwZdudMX2t/1C7KHEfe24yKVJrfMFY+ieWfrHaU3dYZBoHeI08GfRwKcOnp5e72z0bcTHyv3DzwIxksf3dz1qBz3Seav+edc+hGy0nw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1606269938; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=aZ7P2vnzPRECGL5EL8cWVQW4lA/4j6zDcgp21lDknKQ=; b=MfY8C/zfvxK11GzzOq/oD+SY1axlbLHGt+vDlDQ9USiztJ+YoYAbEQQxuV9dyr3tTRDhHEdSYVLkegaMOyogZXdZovcB7BLndgs9VtN12239ZDTGu8aNohHv5SzeIcenLv8FYl1yCjZsuNcryZafYFlI9DomBTLjPO1FnVz1lCg= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTP id 1606269938527413.05596099727995; Tue, 24 Nov 2020 18:05:38 -0800 (PST) Received: from localhost ([::1]:57034 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1khkBH-0003RB-Mg for importer@patchew.org; Tue, 24 Nov 2020 21:05:15 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:37094) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1khk45-0007o9-1m for qemu-devel@nongnu.org; Tue, 24 Nov 2020 20:57:49 -0500 Received: from szxga06-in.huawei.com ([45.249.212.32]:2100) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1khk41-0007PA-3r for qemu-devel@nongnu.org; Tue, 24 Nov 2020 20:57:48 -0500 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga06-in.huawei.com (SkyGuard) with ESMTP id 4CgkXs2ggkzhZrK; Wed, 25 Nov 2020 09:57:17 +0800 (CST) Received: from huawei.com (10.175.124.27) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.487.0; Wed, 25 Nov 2020 09:57:22 +0800 From: Yutao Ai To: , Subject: [PATCH 3/3] monitor:Don't use '#' flag of printf format ('%#') in format strings Date: Wed, 25 Nov 2020 01:45:14 +0000 Message-ID: <20201125014514.55562-4-aiyutao@huawei.com> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20201125014514.55562-1-aiyutao@huawei.com> References: <20201125014514.55562-1-aiyutao@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.175.124.27] X-CFilter-Loop: Reflected Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=45.249.212.32; envelope-from=aiyutao@huawei.com; helo=szxga06-in.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alex.chen@huawei.com, aiyutao@huawei.com, qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" Delete '#' and use '0x' prefix instead Signed-off-by: Yutao Ai Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- monitor/misc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/monitor/misc.c b/monitor/misc.c index 7588f12053..2eb563f6f3 100644 --- a/monitor/misc.c +++ b/monitor/misc.c @@ -910,7 +910,7 @@ static void hmp_ioport_read(Monitor *mon, const QDict *= qdict) suffix =3D 'l'; break; } - monitor_printf(mon, "port%c[0x%04x] =3D %#0*x\n", + monitor_printf(mon, "port%c[0x%04x] =3D 0x%0*x\n", suffix, addr, size * 2, val); } =20 --=20 2.19.1