From patchwork Tue Apr 19 19:55:26 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eduardo Habkost X-Patchwork-Id: 8883161 Return-Path: X-Original-To: patchwork-qemu-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id BD18CBF29F for ; Tue, 19 Apr 2016 20:02:16 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2D6AE202EC for ; Tue, 19 Apr 2016 20:02:15 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 834E1202C8 for ; Tue, 19 Apr 2016 20:02:14 +0000 (UTC) Received: from localhost ([::1]:35706 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1asbqf-0000dR-VA for patchwork-qemu-devel@patchwork.kernel.org; Tue, 19 Apr 2016 16:02:13 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37756) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1asbkZ-0003Ae-C5 for qemu-devel@nongnu.org; Tue, 19 Apr 2016 15:55:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1asbkY-0007e5-E1 for qemu-devel@nongnu.org; Tue, 19 Apr 2016 15:55:55 -0400 Received: from mx1.redhat.com ([209.132.183.28]:39520) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1asbkY-0007dy-8T for qemu-devel@nongnu.org; Tue, 19 Apr 2016 15:55:54 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D1D3EE77BC for ; Tue, 19 Apr 2016 19:55:53 +0000 (UTC) Received: from localhost (vpn1-5-236.gru2.redhat.com [10.97.5.236]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u3JJtqXc015282; Tue, 19 Apr 2016 15:55:53 -0400 From: Eduardo Habkost To: qemu-devel@nongnu.org Date: Tue, 19 Apr 2016 16:55:26 -0300 Message-Id: <1461095728-22055-11-git-send-email-ehabkost@redhat.com> In-Reply-To: <1461095728-22055-1-git-send-email-ehabkost@redhat.com> References: <1461095728-22055-1-git-send-email-ehabkost@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Tue, 19 Apr 2016 19:55:53 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH for-2.7 v3 10/12] vl: Make display_type a local variable X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Marcel Apfelbaum , Paolo Bonzini Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Now display_type is only used inside main(), and don't need to be a global variable. Signed-off-by: Eduardo Habkost --- include/sysemu/sysemu.h | 1 - vl.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h index 6076b80..7e9f93e 100644 --- a/include/sysemu/sysemu.h +++ b/include/sysemu/sysemu.h @@ -155,7 +155,6 @@ extern int vga_interface_type; extern int graphic_width; extern int graphic_height; extern int graphic_depth; -extern DisplayType display_type; extern int display_opengl; extern const char *keyboard_layout; extern int win2k_install_hack; diff --git a/vl.c b/vl.c index c59cf0a..5867c0f 100644 --- a/vl.c +++ b/vl.c @@ -127,7 +127,6 @@ static const char *data_dir[16]; static int data_dir_idx; const char *bios_name = NULL; enum vga_retrace_method vga_retrace_method = VGA_RETRACE_DUMB; -DisplayType display_type = DT_DEFAULT; int request_opengl = -1; int display_opengl; static int display_remote; @@ -2961,6 +2960,7 @@ int main(int argc, char **argv, char **envp) bool defconfig = true; bool userconfig = true; bool nographic = false; + DisplayType display_type = DT_DEFAULT; const char *log_mask = NULL; const char *log_file = NULL; char *trace_file = NULL;