From patchwork Tue Apr 12 17:54:11 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sasha Levin X-Patchwork-Id: 701531 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p3CHsXuR009936 for ; Tue, 12 Apr 2011 17:54:34 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755946Ab1DLRyX (ORCPT ); Tue, 12 Apr 2011 13:54:23 -0400 Received: from mail-ww0-f44.google.com ([74.125.82.44]:39627 "EHLO mail-ww0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754725Ab1DLRyW (ORCPT ); Tue, 12 Apr 2011 13:54:22 -0400 Received: by mail-ww0-f44.google.com with SMTP id 36so8203154wwa.1 for ; Tue, 12 Apr 2011 10:54:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references; bh=EKPNQDwHENslMWeTf68zGgwZHwiTLC6dCmgc/M1Vc8Q=; b=cb8cBi9IReQHlTwxys/jbdEupb+TupelRcSk9Aoi8BUvybgLLWOrsOVQyrvMpkML0k fJofjPLfU0zJ7KbHcJkDQD8szE22FRQtctC6Vm7+kj4ppDdhoh2M1HoqloAMkPMHPc6q 8qmSN4wcA15GgLTqXrgYeaVjQzW05CrIUQHFg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; b=B1RvpxHHX2t8Gsu9MwELhfHszWIW5KdHCXWGW4D3Sj/tVK9zhUHoArsbC/l+vxh1/e sz33yhrruYXhv3aEPwc9oMBlV4rpvkg1YGP9VxVKE0/gusXMiGrseWVjIc+qAY3vSjIk PAifq75guJRnIjSS89HpkcY9r2vRxwLlyABAk= Received: by 10.227.36.203 with SMTP id u11mr7189953wbd.162.1302630861997; Tue, 12 Apr 2011 10:54:21 -0700 (PDT) Received: from localhost.localdomain ([94.230.81.151]) by mx.google.com with ESMTPS id o23sm4184823wbc.44.2011.04.12.10.54.20 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 12 Apr 2011 10:54:21 -0700 (PDT) From: Sasha Levin To: penberg@kernel.org Cc: kvm@vger.kernel.org, Sasha Levin Subject: [PATCH 2/2] kvm tools: Arrange cmdline help menu Date: Tue, 12 Apr 2011 20:54:11 +0300 Message-Id: <1302630851-19440-2-git-send-email-levinsasha928@gmail.com> X-Mailer: git-send-email 1.7.5.rc1 In-Reply-To: <1302630851-19440-1-git-send-email-levinsasha928@gmail.com> References: <1302630851-19440-1-git-send-email-levinsasha928@gmail.com> Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 12 Apr 2011 17:54:34 +0000 (UTC) Group the cmdline menu into simple groups instead of one messy list. Signed-off-by: Sasha Levin --- tools/kvm/kvm-run.c | 23 ++++++++++++++--------- 1 files changed, 14 insertions(+), 9 deletions(-) diff --git a/tools/kvm/kvm-run.c b/tools/kvm/kvm-run.c index ba02172..06a31ed 100644 --- a/tools/kvm/kvm-run.c +++ b/tools/kvm/kvm-run.c @@ -73,24 +73,29 @@ static const char * const run_usage[] = { }; static const struct option options[] = { + OPT_GROUP("Basic options:"), + OPT_INTEGER('\0', "cpus", &nrcpus, "Number of CPUs"), OPT_U64('m', "mem", &ram_size, "Virtual machine memory size in MiB."), - OPT_STRING('p', "params", &kernel_cmdline, "params", - "Kernel command line arguments"), - OPT_STRING('r', "initrd", &initrd_filename, "initrd", - "Initial RAM disk image"), - OPT_STRING('k', "kernel", &kernel_filename, "kernel", - "Kernel to boot in virtual machine"), OPT_STRING('i', "image", &image_filename, "image", "Disk image"), OPT_BOOLEAN('\0', "readonly", &readonly_image, "Don't write changes back to disk image"), + OPT_STRING('c', "console", &console, "serial or virtio", + "Console to use"), + + OPT_GROUP("Kernel options:"), + OPT_STRING('k', "kernel", &kernel_filename, "kernel", + "Kernel to boot in virtual machine"), + OPT_STRING('r', "initrd", &initrd_filename, "initrd", + "Initial RAM disk image"), + OPT_STRING('p', "params", &kernel_cmdline, "params", + "Kernel command line arguments"), + + OPT_GROUP("Debug options:"), OPT_STRING('d', "kvm-dev", &kvm_dev, "kvm-dev", "KVM device file"), OPT_BOOLEAN('s', "single-step", &single_step, "Enable single stepping"), OPT_BOOLEAN('g', "ioport-debug", &ioport_debug, "Enable ioport debugging"), - OPT_STRING('c', "console", &console, "serial or virtio", - "Console to use"), - OPT_INTEGER('\0', "cpus", &nrcpus, "Number of CPUs"), OPT_END() };