From patchwork Wed Mar 17 03:22:16 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Michael Roth X-Patchwork-Id: 12144643 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE, SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7451CC433E0 for ; Wed, 17 Mar 2021 03:27:49 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id EBCFB64F8B for ; Wed, 17 Mar 2021 03:27:48 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EBCFB64F8B Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=amd.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:47748 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lMMqa-000280-2U for qemu-devel@archiver.kernel.org; Tue, 16 Mar 2021 23:27:48 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37060) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lMMlp-0005Sf-DO for qemu-devel@nongnu.org; Tue, 16 Mar 2021 23:22:53 -0400 Received: from mail-eopbgr750053.outbound.protection.outlook.com ([40.107.75.53]:4470 helo=NAM02-BL2-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lMMln-00011A-GK for qemu-devel@nongnu.org; Tue, 16 Mar 2021 23:22:53 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RvOykYVJMraVmM1xVrdnmzXoeeJLOZtkyAj/b/QkE3R11g+j8k3CnRKnG2vMvrYbjWJTPWFCC0ZZC/MycYmOEA+85uthCVF9q7ks+4wyTq33BT7y7a6XVjLhhGCfsvMfvgOyRzDj55X36W8U6R0cNY7BZ7fSBxJOC3wuToSYGualiFL/uX3Gx2VS9p5TQtMO1KoO0gNwsXLcbSLDDwKYTD33WNK7tP/iDcqNR9D6syNk9SVpvTeL360Y21gSexqHPzXho8w108e1uj7h95IuSHyXpkrL3rTbSBjHHN7AZivtRcbBhlkw7jtyusOikoKUwVIzeNdS5GHJj7XqlcYPYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2j7K2uII9kt9fbDXY5phqFNWi31+gNgB6t4dXN0Oabo=; b=WF1jzio/psTxwj05B3PxhTjTe8E4AayObsX3XxGqlWcqoR5KKRXFLhDOCOu2FcRYNPxGuB0iotp2Zb1NtBQT58crePh/tU6MjWxBCmDUUhm4aBhmOKkQF204Iu+AMMZ3SHuYdaD7U4ovwWzCW0tFRsrvDtJt3oXlisXVRVhcAlBEynbvMN6N3Iou5tB/Rwh7Ye7/6lnjteVdmu4+T/hw0QZ45jhSCMB+N45RyVK0CzyQuWxJa8wkVoRvOk85TGxXsgmuKsn1V2JsDfz66wX6FjjaWpy8c268x7jKV/9dywqM+4UBMRuUQ37DlS2V4YUY07UTrka+lyxmgWc84k8UhQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2j7K2uII9kt9fbDXY5phqFNWi31+gNgB6t4dXN0Oabo=; b=knoYHs33GI5EkVjh6pzKxNPGTlNr/bQaT73hiJvPn1yiOCeC9RFAQe6GB7/aoAxDhOJhB7iYhHEiwnw3kM+wffN3kcrOdJOiealfnzEf+oNwBcAaUCDM+jLSkbYDdKxP9DDBqX1+f/EolgkdELrqwSdAQbuFPv2kcUUUzqZguNo= Authentication-Results: nongnu.org; dkim=none (message not signed) header.d=none;nongnu.org; dmarc=none action=none header.from=amd.com; Received: from CH2PR12MB4133.namprd12.prod.outlook.com (2603:10b6:610:7a::13) by CH2PR12MB4954.namprd12.prod.outlook.com (2603:10b6:610:63::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3955.18; Wed, 17 Mar 2021 03:22:49 +0000 Received: from CH2PR12MB4133.namprd12.prod.outlook.com ([fe80::81f6:605c:f345:b99f]) by CH2PR12MB4133.namprd12.prod.outlook.com ([fe80::81f6:605c:f345:b99f%3]) with mapi id 15.20.3955.018; Wed, 17 Mar 2021 03:22:49 +0000 From: Michael Roth To: qemu-devel@nongnu.org Subject: [PULL for-6.0 5/6] qga: Switch and case should be at the same indent Date: Tue, 16 Mar 2021 22:22:16 -0500 Message-Id: <20210317032217.1460684-6-michael.roth@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210317032217.1460684-1-michael.roth@amd.com> References: <20210317032217.1460684-1-michael.roth@amd.com> X-Originating-IP: [165.204.84.11] X-ClientProxiedBy: BN0PR03CA0009.namprd03.prod.outlook.com (2603:10b6:408:e6::14) To CH2PR12MB4133.namprd12.prod.outlook.com (2603:10b6:610:7a::13) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost (165.204.84.11) by BN0PR03CA0009.namprd03.prod.outlook.com (2603:10b6:408:e6::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3955.18 via Frontend Transport; Wed, 17 Mar 2021 03:22:49 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 806d260f-8c01-4c60-9e62-08d8e8f3f12a X-MS-TrafficTypeDiagnostic: CH2PR12MB4954: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:262; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: cgmNN3Wjcz1DQtBaxQyELBMSCOgTj9IcsKw7msVArhfBDELDF0ivfVDLcA8Q84k8bUY9EAwEo4476AW0TX/W2Kg82rW4e3Xdn2+eXjufOH8tPj7xJ4mofPwR+B3sUF1bgHksJXQcq928Ec+M0/fs3KpVpjG10UWkRe8qvBxqvWFF67HXeJBFrOj85tFH0EspuHEg1JakpwICDBTKidI4EY4wg3s7Pd1ClWDB7yc2rtYWWqIujLzldSjfPcisS01pNN9+X8mw5UvhnXDWk7zEJZggBmpOLNB/dlYiivrxeapaB0g24p3ZN+tQmxfMgiWRlw3ClW9aG/H/N54IIw/Iwuij7WR0jw/KSqsuaDfO7HD0Por266z0liAHg/v1TdhjMjGiaAs4RRdvO7yhJAOutZDrDMl4imZcZUO05KeGyCrguxIEM5wMkhEy04g9tp/Qk+iF/sgdJZPAvEsFUcwdlNbaykggJMZOj82DpnfgZQO3RCEof5iRm1TekNU7WElkKNekpIYWer+aF8zE9YeOnoNXwX9b037XoiKCu6UpyrmubIGyFwLxREgCgmOS0nyV X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CH2PR12MB4133.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(396003)(376002)(136003)(39860400002)(346002)(366004)(186003)(8676002)(8936002)(4326008)(478600001)(316002)(26005)(66946007)(54906003)(83380400001)(1076003)(2616005)(66476007)(956004)(66556008)(86362001)(6916009)(36756003)(44832011)(6666004)(6486002)(52116002)(16526019)(6496006)(5660300002)(2906002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: =?utf-8?q?aKj0eEH/Rg5KIuX5LbMmcZqoy0QFfF?= =?utf-8?q?4q6u5OZAf+gkbbE4IDr8xSNLgu0GZgXXSmrOZYfQ59UOCbyIhkQdiy3fBoHNi0hIM?= =?utf-8?q?4GPHjBmkdYm9XVEsa1xHd/Bs2CQdCSwsMm0u99E+YvrAH6tqRnykW/6ne2Y8v2tqt?= =?utf-8?q?sNbZCENdLYJ2DGudqcC8XeR9Ab8If3XSlUDTx/jYlBS9tweOHOhXDVQ0exvcDuA1O?= =?utf-8?q?AwgwXDjY+xjLCxHqyLHTB3AhC54DcrwZ6EMAxCm2IiqtwIaGNUbfELHVxIyr/CkCQ?= =?utf-8?q?eWxK1NuIyAscbe9x+uF25OpNklSGNg8Lybfg9oKq4b23efpclYWRnFRs8JvUm+tPG?= =?utf-8?q?n2HWmfGZgWKnv1Gqw8r/3d3JiZlk4flRpDGc9NMrtCWgX2AKd2AvJiCeTLdL3VvjV?= =?utf-8?q?XnHHJYHjKf9JrbKEo/qPYGdhzqjKqNKzIzzhJSC7mKgothcVkyvMBr397DvCnYVAp?= =?utf-8?q?J6Asi2o+a6GMUw8AJCtHvYbLFWs/w0ol/AZ/h7qEDG0j4MQiTt+WGnkTFfLnsELZh?= =?utf-8?q?RIYxtm6LVYppInqtBF8PKgmGcNhf9eTsjvrGw9OHOinmY5bm5NZw1sR9iQnSR8dTI?= =?utf-8?q?S9k7sU3fYgzOyWOgBDBcpXkkK5b04DY6diIIGUs3KBtPtKM6LJZN2F1qEt+1/3+NF?= =?utf-8?q?u5pAbh9A6RPQ/qj3gv49yBHtKZHn9/WULRFwdGoICb++1LeB+upCdAhIknFAo55h9?= =?utf-8?q?avr3lwGxiEgoCxppd/o0C3794nTm12G72cvxfZALhfzsBu+LqTs6OWI0Lo/GWYrXO?= =?utf-8?q?pMCUTzzPuZ9foGqVUSGGb8MCRquEaJRuzBtIrw7AUJyrmFVlvzkXUBTzw2E7osrZ1?= =?utf-8?q?vgDMk5MxKBKVW44GGVufl9EU2WtECf0WNQpWqdHJZU1Jj8/7AteMQVbomyjcDDC6f?= =?utf-8?q?yoxhtuCLxhP8ZwQeYjyR0a2B224w1HUCbqqXhr7Ed8iWPDcPWgfb0xu7HGsrWk2dN?= =?utf-8?q?zYq4ZLP9n99T/U9eY685Wl61HwHx76zA/M4QN/G6Nt2ddu1KCENguSsDTvgEl0iHB?= =?utf-8?q?DhPX2OghDEp+M60z9UKey0ivI4QwjrlIz1HswjgCnIdD1Z5q8J682v+WKAFogMZ0Z?= =?utf-8?q?ejoTdZHbcguRTptQ2doMEJR76ILPCnbUYKKdX3rVOK2NRiqM0mbDsWIdugZ84FBYq?= =?utf-8?q?NV5qJPvZIunYyNXWhyD0VBnx2D0HTFJyBUrfV0+wtFmoJRbveHYvX2Y6VJ9kUsa8D?= =?utf-8?q?qssTVWMYlf+464QC5BKW+6xFY1WaalOvx/smWsuov45GVB6xfEXwGqMlllmtENQGn?= =?utf-8?q?Ca8jSKdG1Esz9a?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 806d260f-8c01-4c60-9e62-08d8e8f3f12a X-MS-Exchange-CrossTenant-AuthSource: CH2PR12MB4133.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Mar 2021 03:22:49.6054 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 9+Qi8n1e9ouswJgx+VvtAiJYiADhTCISflmSDaVmSVjPsOZ1fU6QNWirkZFBZk5mEXMMc7cXsUDa4SJVcXCS9Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH2PR12MB4954 Received-SPF: softfail client-ip=40.107.75.53; envelope-from=Michael.Roth@amd.com; helo=NAM02-BL2-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MSGID_FROM_MTA_HEADER=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-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: AlexChen , peter.maydell@linaro.org, =?utf-8?q?Mar?= =?utf-8?q?c-Andr=C3=A9_Lureau?= , Euler Robot Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" From: AlexChen Reported-by: Euler Robot Signed-off-by: AlexChen Reviewed-by: Marc-André Lureau Signed-off-by: Michael Roth --- qga/main.c | 52 ++++++++++++++++++++++++++-------------------------- 1 file changed, 26 insertions(+), 26 deletions(-) diff --git a/qga/main.c b/qga/main.c index 20db0058db..ebb910773b 100644 --- a/qga/main.c +++ b/qga/main.c @@ -279,20 +279,20 @@ QEMU_HELP_BOTTOM "\n" static const char *ga_log_level_str(GLogLevelFlags level) { switch (level & G_LOG_LEVEL_MASK) { - case G_LOG_LEVEL_ERROR: - return "error"; - case G_LOG_LEVEL_CRITICAL: - return "critical"; - case G_LOG_LEVEL_WARNING: - return "warning"; - case G_LOG_LEVEL_MESSAGE: - return "message"; - case G_LOG_LEVEL_INFO: - return "info"; - case G_LOG_LEVEL_DEBUG: - return "debug"; - default: - return "user"; + case G_LOG_LEVEL_ERROR: + return "error"; + case G_LOG_LEVEL_CRITICAL: + return "critical"; + case G_LOG_LEVEL_WARNING: + return "warning"; + case G_LOG_LEVEL_MESSAGE: + return "message"; + case G_LOG_LEVEL_INFO: + return "info"; + case G_LOG_LEVEL_DEBUG: + return "debug"; + default: + return "user"; } } @@ -687,19 +687,19 @@ DWORD WINAPI service_ctrl_handler(DWORD ctrl, DWORD type, LPVOID data, GAService *service = &ga_state->service; switch (ctrl) { - case SERVICE_CONTROL_STOP: - case SERVICE_CONTROL_SHUTDOWN: - quit_handler(SIGTERM); - SetEvent(ga_state->wakeup_event); - service->status.dwCurrentState = SERVICE_STOP_PENDING; - SetServiceStatus(service->status_handle, &service->status); - break; - case SERVICE_CONTROL_DEVICEEVENT: - handle_serial_device_events(type, data); - break; + case SERVICE_CONTROL_STOP: + case SERVICE_CONTROL_SHUTDOWN: + quit_handler(SIGTERM); + SetEvent(ga_state->wakeup_event); + service->status.dwCurrentState = SERVICE_STOP_PENDING; + SetServiceStatus(service->status_handle, &service->status); + break; + case SERVICE_CONTROL_DEVICEEVENT: + handle_serial_device_events(type, data); + break; - default: - ret = ERROR_CALL_NOT_IMPLEMENTED; + default: + ret = ERROR_CALL_NOT_IMPLEMENTED; } return ret; }