From patchwork Fri Jan 22 12:08:40 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Janosch Frank X-Patchwork-Id: 8089451 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 D68F3BEEE5 for ; Fri, 22 Jan 2016 12:13:40 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 40661203F7 for ; Fri, 22 Jan 2016 12:13:40 +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 84280203E5 for ; Fri, 22 Jan 2016 12:13:39 +0000 (UTC) Received: from localhost ([::1]:52946 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMaaw-0003De-QU for patchwork-qemu-devel@patchwork.kernel.org; Fri, 22 Jan 2016 07:13:38 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53269) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMaYv-0000bp-Ga for qemu-devel@nongnu.org; Fri, 22 Jan 2016 07:11:38 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aMaYl-0007P5-3K for qemu-devel@nongnu.org; Fri, 22 Jan 2016 07:11:28 -0500 Received: from e06smtp16.uk.ibm.com ([195.75.94.112]:42741) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aMaYk-0007Oh-RA for qemu-devel@nongnu.org; Fri, 22 Jan 2016 07:11:23 -0500 Received: from localhost by e06smtp16.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 22 Jan 2016 12:11:21 -0000 Received: from d06dlp03.portsmouth.uk.ibm.com (9.149.20.15) by e06smtp16.uk.ibm.com (192.168.101.146) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Fri, 22 Jan 2016 12:11:19 -0000 X-IBM-Helo: d06dlp03.portsmouth.uk.ibm.com X-IBM-MailFrom: frankja@linux.vnet.ibm.com X-IBM-RcptTo: qemu-devel@nongnu.org Received: from b06cxnps3075.portsmouth.uk.ibm.com (d06relay10.portsmouth.uk.ibm.com [9.149.109.195]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id 39A911B0804B for ; Fri, 22 Jan 2016 12:11:24 +0000 (GMT) Received: from d06av02.portsmouth.uk.ibm.com (d06av02.portsmouth.uk.ibm.com [9.149.37.228]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id u0MCBITA852334 for ; Fri, 22 Jan 2016 12:11:18 GMT Received: from d06av02.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id u0MCBI0P002184 for ; Fri, 22 Jan 2016 05:11:18 -0700 Received: from s38lp20.boeblingen.de.ibm.com (dyn-9-152-224-160.boeblingen.de.ibm.com [9.152.224.160]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id u0MCBGUJ002067; Fri, 22 Jan 2016 05:11:18 -0700 From: Janosch Frank To: qemu-devel@nongnu.org Date: Fri, 22 Jan 2016 13:08:40 +0100 Message-Id: <1453464520-3882-7-git-send-email-frankja@linux.vnet.ibm.com> X-Mailer: git-send-email 2.3.0 In-Reply-To: <1453464520-3882-1-git-send-email-frankja@linux.vnet.ibm.com> References: <1453464520-3882-1-git-send-email-frankja@linux.vnet.ibm.com> X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 16012212-0025-0000-0000-000008B14587 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 195.75.94.112 Cc: pbonzini@redhat.com, drjones@redhat.com, lersek@redhat.com, frankja@linux.vnet.ibm.com Subject: [Qemu-devel] [PATCH 6/6] scripts/dump-guest-memory.py: Fix module docstring X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org 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 The module docstring is changed into a multi-line comment to comply with pep 257. The comment about the docstring that gets used by gdb to print the help is moved to the location of the docstring. Signed-off-by: Janosch Frank --- scripts/dump-guest-memory.py | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/scripts/dump-guest-memory.py b/scripts/dump-guest-memory.py index 7acce65..f274bf8 100644 --- a/scripts/dump-guest-memory.py +++ b/scripts/dump-guest-memory.py @@ -1,20 +1,17 @@ -# This python script adds a new gdb command, "dump-guest-memory". It -# should be loaded with "source dump-guest-memory.py" at the (gdb) -# prompt. -# -# Copyright (C) 2013, Red Hat, Inc. -# -# Authors: -# Laszlo Ersek -# Janosch Frank -# -# This work is licensed under the terms of the GNU GPL, version 2 or later. See -# the COPYING file in the top-level directory. -# -# The leading docstring doesn't have idiomatic Python formatting. It is -# printed by gdb's "help" command (the first line is printed in the -# "help data" summary), and it should match how other help texts look in -# gdb. +""" +This python script adds a new gdb command, "dump-guest-memory". It +should be loaded with "source dump-guest-memory.py" at the (gdb) +prompt. + +Copyright (C) 2013, Red Hat, Inc. + +Authors: + Laszlo Ersek + Janosch Frank + +This work is licensed under the terms of the GNU GPL, version 2 or later. See +the COPYING file in the top-level directory. +""" import ctypes @@ -431,6 +428,10 @@ def get_guest_phys_blocks(): return guest_phys_blocks +# The leading docstring doesn't have idiomatic Python formatting. It is +# printed by gdb's "help" command (the first line is printed in the +# "help data" summary), and it should match how other help texts look in +# gdb. class DumpGuestMemory(gdb.Command): """Extract guest vmcore from qemu process coredump.