qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: qemu-devel@nongnu.org
Cc: Janosch Frank <frankja@linux.vnet.ibm.com>
Subject: [Qemu-devel] [PULL 36/49] scripts/kvm/kvm_stat: Read event values as u64
Date: Tue, 26 Jan 2016 14:47:08 +0100	[thread overview]
Message-ID: <1453816041-36362-37-git-send-email-pbonzini@redhat.com> (raw)
In-Reply-To: <1453816041-36362-1-git-send-email-pbonzini@redhat.com>

From: Janosch Frank <frankja@linux.vnet.ibm.com>

The struct read_format, which denotes the returned values on a read
states that the values are u64 and not long long which is used for
struct unpacking.

Therefore the 'q' long long formatter was exchanged with 'Q' which is
the format for u64 data.

Signed-off-by: Janosch Frank <frankja@linux.vnet.ibm.com>
Message-Id: <1452525484-32309-31-git-send-email-frankja@linux.vnet.ibm.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 scripts/kvm/kvm_stat | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/kvm/kvm_stat b/scripts/kvm/kvm_stat
index ce97046..611f82a 100755
--- a/scripts/kvm/kvm_stat
+++ b/scripts/kvm/kvm_stat
@@ -358,7 +358,7 @@ class Group(object):
 
     def read(self):
         length = 8 * (1 + len(self.events))
-        read_format = 'xxxxxxxx' + 'q' * len(self.events)
+        read_format = 'xxxxxxxx' + 'Q' * len(self.events)
         return dict(zip([event.name for event in self.events],
                         struct.unpack(read_format,
                                       os.read(self.events[0].fd, length))))
-- 
1.8.3.1

  parent reply	other threads:[~2016-01-26 13:48 UTC|newest]

Thread overview: 55+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-26 13:46 [Qemu-devel] [PULL 00/49] chardev, NBD, cpus, scripts/ changes for 2015-01-26 Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 01/49] char: remove fixed length filename allocation Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 02/49] char: convert from GIOChannel to QIOChannel Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 03/49] char: don't assume telnet initialization will not block Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 04/49] char: introduce support for TLS encrypted TCP chardev backend Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 05/49] docs: Style the command and its options in the synopsis Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 06/49] qemu-char: avoid leak in qemu_chr_open_pp_fd Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 07/49] scripts/kvm/kvm_stat: Cleanup of multiple imports Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 08/49] scripts/kvm/kvm_stat: Replaced os.listdir with os.walk Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 09/49] scripts/kvm/kvm_stat: Make constants uppercase Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 10/49] scripts/kvm/kvm_stat: Removed unneeded PERF constants Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 11/49] scripts/kvm/kvm_stat: Mark globals in functions Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 12/49] scripts/kvm/kvm_stat: Invert dictionaries Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 13/49] scripts/kvm/kvm_stat: Cleanup of path variables Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 14/49] scripts/kvm/kvm_stat: Improve debugfs access checking Paolo Bonzini
2016-02-02 14:02   ` Christian Borntraeger
2016-02-02 14:25     ` Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 15/49] scripts/kvm/kvm_stat: Introduce main function Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 16/49] scripts/kvm/kvm_stat: Fix spaces around keyword assignments Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 17/49] scripts/kvm/kvm_stat: Rename variables that redefine globals Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 18/49] scripts/kvm/kvm_stat: Moved DebugfsProvider Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 19/49] scripts/kvm/kvm_stat: Fixup syscall error reporting Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 20/49] scripts/kvm/kvm_stat: Set sensible no. files rlimit Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 21/49] scripts/kvm/kvm_stat: Cleanup of platform detection Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 22/49] scripts/kvm/kvm_stat: Make cpu detection a function Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 23/49] scripts/kvm/kvm_stat: Rename _perf_event_open Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 24/49] scripts/kvm/kvm_stat: Introduce properties for providers Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 25/49] scripts/kvm/kvm_stat: Cleanup of TracepointProvider Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 26/49] scripts/kvm/kvm_stat: Cleanup cpu list retrieval Paolo Bonzini
2016-01-26 13:46 ` [Qemu-devel] [PULL 27/49] scripts/kvm/kvm_stat: Encapsulate filters variable Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 28/49] scripts/kvm/kvm_stat: Cleanup of Stats class Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 29/49] scripts/kvm/kvm_stat: Cleanup of Groups class Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 30/49] scripts/kvm/kvm_stat: Cleanup of Event class Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 31/49] scripts/kvm/kvm_stat: Group arch specific data Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 32/49] scripts/kvm/kvm_stat: Remove unneeded X86_EXIT_REASONS Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 33/49] scripts/kvm/kvm_stat: Make tui function a class Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 34/49] scripts/kvm/kvm_stat: Fix output formatting Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 35/49] scripts/kvm/kvm_stat: Cleanup and pre-init perf_event_attr Paolo Bonzini
2016-01-26 13:47 ` Paolo Bonzini [this message]
2016-01-26 13:47 ` [Qemu-devel] [PULL 37/49] scripts/kvm/kvm_stat: Fix rlimit for unprivileged users Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 38/49] scripts/kvm/kvm_stat: Fixup filtering Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 39/49] scripts/kvm/kvm_stat: Add interactive filtering Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 40/49] scripts/kvm/kvm_stat: Add optparse description Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 41/49] cpus: use broadcast on qemu_pause_cond Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 42/49] memory: exit when hugepage allocation fails if mem-prealloc Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 43/49] nbd: add missed aio_context_acquire in nbd_export_new Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 44/49] scripts/dump-guest-memory.py: Move constants to the top Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 45/49] scripts/dump-guest-memory.py: Make methods functions Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 46/49] scripts/dump-guest-memory.py: Improve python 3 compatibility Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 47/49] scripts/dump-guest-memory.py: Cleanup functions Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 48/49] scripts/dump-guest-memory.py: Introduce multi-arch support Paolo Bonzini
2016-01-26 13:47 ` [Qemu-devel] [PULL 49/49] scripts/dump-guest-memory.py: Fix module docstring Paolo Bonzini
2016-01-26 14:38 ` [Qemu-devel] [PULL 00/49] chardev, NBD, cpus, scripts/ changes for 2015-01-26 Peter Maydell
2016-01-26 15:29   ` Daniel P. Berrange
2016-01-26 16:06   ` [Qemu-devel] [PATCH] char: make io_channel_send be used unconditionally Daniel P. Berrange

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1453816041-36362-37-git-send-email-pbonzini@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=frankja@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).