Statistics
| Branch: | Revision:

root / scripts @ 8d3bc517

# Date Author Comment
8d3bc517 12/27/2011 05:28 pm Avi Kivity

Fix qapi code generation wrt parallel build

Make's multiple output syntax

x.c x.h: x.template
gen < x.template

actually invokes the command once for x.c and once for x.h (with differing $@
in each invocation). During a parallel build, the two commands may be invoked...

058a96ed 12/21/2011 09:07 am Harsh Prateek Bora

scripts/analyse-9p-simpletrace.py: Add symbolic names for 9p operations.

Currently, we just print the numerical value of 9p operation identifier in
case of RERROR which is less meaningful for readability. Mapping 9p
operation ids to symbolic names provides a better tracelog:...

a3adb7ad 12/19/2011 06:27 pm Michael Ellerman

vl.c: In qemu -h output, only print options for the arch we are running as

Only print options in the help output that are accepted by our arch.
This is less confusing for users and also for other programs that
consume the help output.

The options affected are:...

5dbee474 12/15/2011 05:20 pm Anthony Liguori

qapi: allow a 'gen' key to suppress code generation

Signed-off-by: Anthony Liguori <>

e7d81004 12/14/2011 01:09 pm Stefan Weil

Fix spelling in comments, documentation and messages

accidently->accidentally
annother->another
choosen->chosen
consideres->considers
decriptor->descriptor
developement->development
paramter->parameter
preceed->precede
preceeding->preceding
priviledge->privilege...

68dfbcd4 12/02/2011 12:50 pm Dong Xu Wang

fix spelling in scripts sub directory

Signed-off-by: Dong Xu Wang <>
Signed-off-by: Stefan Hajnoczi <>

d8e1f214 11/30/2011 05:28 pm Michael Roth

qapi: fix guardname generation

Fix a bug in handling dotted paths, and exclude directory prefixes
from generated guardnames to avoid odd/pseudo-random guardnames in
generated headers.

Signed-off-by: Anthony Liguori <>

61669f9a 11/26/2011 11:47 am Florian Mickler

checkpatch.pl: fix CAST detection

We should only claim that something is a cast if we did not encouter a
token before, that did set av_pending.

This fixes the operator * in the line below to be detected as binary (vs
unary).

kmalloc(sizeof(struct alphatrack_ocmd) * true_size, GFP_KERNEL);...

e589728b 11/01/2011 11:52 pm Paolo Bonzini

checkpatch: remove rule on non-indented labels

There are 508 non-indented (non-default) labels, and 511 that are
indented. So the rule is debatable at least. Actually, in the
common case of labels at the outermost scope, there is really just
one place where to put the label, so the rule is just wrong IMHO....

96b3d73f 10/31/2011 06:02 pm Anthony Liguori

Merge remote-tracking branch 'qmp/queue/qmp' into staging

Conflicts:
ui/spice-core.c

549f808b 10/31/2011 06:00 pm Anthony Liguori

Merge remote-tracking branch 'qemu-kvm-tmp/uq/master' into staging

7999f7e1 10/30/2011 11:05 am Aneesh Kumar K.V

hw/9pfs: Make VirtFS tracing work correctly

this patch fix multiple issues with VirtFS tracing.
a) Add tracepoint to the correct code path. We handle error in complete_pdu
b) Fix indentation in python script
c) Fix variable naming issue in python script
...

694a099a 10/27/2011 04:48 pm Luiz Capitulino

qapi-commands.py: Don't call the output marshal on error

Today we generate something like this:

int qmp_marshal_input_query_foo(...)
...
retval = qmp_query_foo(errp);
qmp_marshal_output_query_foo(retval, ret, errp);
......
5f6caa4f 10/25/2011 02:26 am Jan Kiszka

kvm: Add tool for querying VMX capabilities

Taken from original qemu-kvm/kvm/scripts/vmxcap.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Avi Kivity <>

626c4276 10/25/2011 02:26 am Jan Kiszka

kvm: Add top-like kvm statistics script

Taken from original qemu-kvm/kvm/kvm_stat.

Signed-off-by: Jan Kiszka <>
Signed-off-by: Avi Kivity <>

49a88ce3 10/15/2011 01:00 pm Harsh Prateek Bora

scripts: Simpletrace log analysis script for pretty-printing 9p log.

This python script allows to pretty print 9p simpletrace logs and can be
further enhanced to filter 9p logs based on command line arguments.

Sample output:
TGETATTR (tag = 1 , fid = 0 , request_mask = 0x7ff )...

303b54b1 10/04/2011 05:00 pm Luiz Capitulino

qapi: Automatically generate a _MAX value for enums

It's the last value in the enum and is very useful for the C
implementation.

Signed-off-by: Luiz Capitulino <>

776574d6 10/04/2011 05:00 pm Anthony Liguori

qapi: add code generation support for middle mode

To get the ball rolling merging QAPI, this patch introduces a "middle mode" to
the code generator. In middle mode, the code generator generates marshalling
functions that are compatible with the current QMP server. We absolutely need...

15e43e64 10/04/2011 05:00 pm Anthony Liguori

qapi: fixup command generation for functions that return list types

Signed-off-by: Anthony Liguori <>
Signed-off-by: Luiz Capitulino <>

75b96aca 10/04/2011 05:00 pm Michael Roth

qapi: generate qapi_free_* functions for *List types

Reviewed-by: Anthony Liguori <>
Signed-off-by: Michael Roth <>
Signed-off-by: Luiz Capitulino <>

e1bc2f7b 10/04/2011 05:00 pm Michael Roth

qapi: modify visitor code generation for list iteration

Modify logic such that we never assign values to the list head argument
to progress through the list on subsequent iterations, instead rely only
on having our return value passed back in as an argument on the next...

d2a80d6b 10/04/2011 05:00 pm Luiz Capitulino

qapi: Don't use c_var() on enum strings

Otherwise if we have something like 'foo-bar' in the schema,
it will be generated as 'foo_bar' in the string lookup table.

c_var() is good for C variables, but not for enum strings.

Signed-off-by: Luiz Capitulino <>

913540a3 09/17/2011 06:14 pm Stefan Hajnoczi

trace: allow PRI*64 at beginning and ending of format string

The tracetool parser only picks up PRI*64 and other format string macros
when enclosed between double quoted strings. Lift this restriction by
extracting everything after the closing ')' as the format string:...

49926043 09/01/2011 12:34 pm Lluís

trace: generalize the "property" concept in the trace-events file

This adds/modifies the following functions:

  • get_name: Get only the event name
  • has_property: Return whether an event has a property (keyword before the event
    name)

Signed-off-by: Lluís Vilanova <>

dd215f64 09/01/2011 12:34 pm Lluís

trace: always use the "nop" backend on events with the "disable" keyword

Any event with the keyword/property "disable" generates an empty trace event
using the "nop" backend, regardless of the current backend.

Signed-off-by: Lluís Vilanova <>

03727e6a 09/01/2011 12:34 pm Lluís

trace: [simple] disable all trace points by default

Note that this refers to the backend-specific state (whether the output must be
generated), not the event "disabled" property (which always uses the "nop"
backend).

Signed-off-by: Lluís Vilanova <>

9a82b6a5 09/01/2011 12:34 pm Lluís

trace: [stderr] add support for dynamically enabling/disabling events

Uses the generic interface provided in "trace/control.h" in order to provide
a programmatic interface as well as command line and monitor controls.

Signed-off-by: Fabien Chouteau <>...

d8e8ef4e 09/01/2011 12:34 pm Stefan Hajnoczi

simpletrace: fix process() argument count

The simpletrace.process() function invokes analyzer methods with the
wrong number of arguments if a timestamp should be included. This patch
fixes the issue so that trace analysis scripts can make use of
timestamps....

edb47ec4 09/01/2011 12:34 pm Lluís

trace: move backend-specific code into the trace/ directory

Signed-off-by: Lluís Vilanova <>

01c4330b 08/27/2011 06:44 pm Pavel Borzenkov

checkpatch: fix braces {} handling

checkpatch.pl doesn't report warning for if/else statements with missing
'else' braces:

if (something) {
foo;
} else
bar;

The patch has been tested using the last 100 commits.

Signed-off-by: Pavel Borzenkov <>...

7534ba01 08/12/2011 04:31 pm Michael Roth

qapi: fix build issue due to missing newline in generated header

Fixes a build issue on RHEL5, and potentially other distros, where gcc
will generate an error due to us not writing a trailing "\n" when
generating *qmp-commands.h

Signed-off-by: Michael Roth <>...

e89ac222 07/21/2011 10:48 pm Michael Roth

qapi: add ordereddict.py helper library

We need this to parse dictionaries with schema ordering intact so that C
prototypes can be generated deterministically.

Signed-off-by: Michael Roth <>
Signed-off-by: Luiz Capitulino <>

0f923be2 07/21/2011 10:48 pm Michael Roth

qapi: add qapi.py helper libraries

Signed-off-by: Michael Roth <>
Signed-off-by: Luiz Capitulino <>

fb3182ce 07/21/2011 10:48 pm Michael Roth

qapi: add qapi-types.py code generator

This is the code generator for qapi types. It will generation the
following files:

$(prefix)qapi-types.h - C types corresponding to types defined in
the schema you pass in
$(prefix)qapi-types.c - Cleanup functions for the above C types...
06d64c62 07/21/2011 10:48 pm Michael Roth

qapi: add qapi-visit.py code generator

This is the code generator for qapi visiter functions used to
marshal/unmarshal/dealloc qapi types. It generates the following 2
files:

$(prefix)qapi-visit.c: visiter function for a particular c type, used
to automagically convert qobjects into the...
c17d9908 07/21/2011 10:48 pm Michael Roth

qapi: add qapi-commands.py code generator

This is the code generator for qapi command marshaling/dispatch.
Currently only generators for synchronous qapi/qmp functions are
supported. This script generates the following files:

$(prefix)qmp-marshal.c: command marshal/dispatch functions for each...
d0510af2 07/21/2011 12:07 am Blue Swirl

checkpatch: Fix bracing false positives on #if

789f88d0b21fedfd4251d56bb7a9fbfbda7a4ac7 only fixed #else,
fix also #if.

Reviewed-by: Stefan Hajnoczi <>
Signed-off-by: Blue Swirl <>

9fbe4784 07/17/2011 02:54 am Alexander Graf

checkpatch: don't error out on },{ lines

When having code like this:

static PCIDeviceInfo piix_ide_info[] = {
    {
.qdev.name = "piix3-ide",
.qdev.size = sizeof(PCIIDEState),
.qdev.no_user = 1,
.no_hotplug = 1,...
d6034a3a 06/22/2011 03:13 pm Anthony Liguori

Merge remote-tracking branch 'qemu-kvm/uq/master' into staging

87fdd476 06/20/2011 09:12 pm Jan Kiszka

Add kernel header update script

This helper pulls the required kernel headers for KVM and vhost into a
specified directory. The update is triggered via

scripts/update-linux-headers.sh LINUX_PATH

and will place the output under linux-headers/linux and linux-headers/asm-*....

990def58 06/16/2011 12:20 am Michael S. Tsirkin

get_maintainer: update to match qemu tree

Signed-off-by: Michael S. Tsirkin <>

c6a99b60 06/15/2011 06:32 pm Michael S. Tsirkin

get_maintainer.pl: copy utility from Linux

Our MAINTAINERS file format matches Linux so
get the utility to parse it from there.
Updated as of linux 3.0-rc3

Signed-off-by: Michael S. Tsirkin <>

a4c075f1 05/20/2011 06:35 pm Ulrich Hecht

s390x: s390x-linux-user support

This patch adds support for running s390x binaries in the linux-user emulation
code.

Signed-off-by: Ulrich Hecht <>
Signed-off-by: Alexander Graf <>

1a96dd47 04/26/2011 03:14 pm Paolo Bonzini

tracetool: allow ) in trace output string

Be greedy in matching the trailing "\)*" pattern. Otherwise, all the
text in the trace string up to the last closed parenthesis is taken as
part of the prototype.

Signed-off-by: Paolo Bonzini <>...

fa2d480a 04/26/2011 03:14 pm Lluís

trace: [ust] fix generation of 'trace.c' on events without args

Signed-off-by: Lluís Vilanova <>
Signed-off-by: Stefan Hajnoczi <>

36d8d02d 04/18/2011 08:46 pm Alex Williamson

PXE: Refresh all PXE ROMs from the ipxe submodule

Add script to make this easy to repeat later.

Signed-off-by: Alex Williamson <>

0b5538c3 03/07/2011 05:34 pm Stefan Hajnoczi

simpletrace: Thread-safe tracing

Trace events outside the global mutex cannot be used with the simple
trace backend since it is not thread-safe. There is no check to prevent
them being enabled so people sometimes learn this the hard way.

This patch restructures the simple trace backend with a ring buffer...

e323c93e 03/06/2011 09:38 pm Jes Sorensen

tracetool: Add optional argument to specify dtrace probe names

Optional feature allowing a user to generate the probe list to match
the name of the binary, in case they wish to install qemu under a
different name than qemu-{system,user},<arch>

Signed-off-by: Jes Sorensen <>...

59da6684 03/06/2011 08:06 pm Stefan Hajnoczi

simpletrace: Make simpletrace.py a Python module

The simpletrace.py script pretty-prints a binary trace file. Most of
the code can be reused by trace file analysis scripts, so turn it into a
module.

Here is an example script that uses the new simpletrace module:...

ad36ce8b 02/05/2011 03:18 pm Blue Swirl

checkpatch.pl: don't complain about old lines with tabs

Don't complain when the patch includes lines with tabs
only in the hunk's untouched context.

Signed-off-by: Blue Swirl <>

320fba2a 01/30/2011 12:52 am Fabien Chouteau

New trace-event backend: stderr

This backend sends trace events to standard error output during the emulation.

Also add a "--list-backends" option to tracetool, so configure script can
display the list of available backends.

Signed-off-by: Fabien Chouteau <>...

ba76a84d 01/23/2011 01:43 pm Blue Swirl

gdbstub-xml: avoid a warning from sparse

Include a header to get the declaration for xml_builtin. This
avoids a warning from sparse:
CC m68k-softmmu/gdbstub-xml.o
gdbstub-xml.c:244:12: warning: symbol 'xml_builtin' was not declared. Should it be static?...

789f88d0 01/21/2011 07:32 pm Jan Kiszka

checkpatch: Fix bracing false positives on #else

Signed-off-by: Jan Kiszka <>
Signed-off-by: Blue Swirl <>

b6469683 01/20/2011 10:58 pm Blue Swirl

checkpatch: adjust to QEMUisms

Change checkpatch.pl for QEMU use:
- Root directory detection
- Forbid tabs
- Indent at 4 spaces
- Allow typedefs
- Enforce brace use even for single statement blocks
- Don't suggest nonexistent cleanup tools

Mention the script in CODING_STYLE....

1ec3f6f9 01/20/2011 10:54 pm Blue Swirl

Add checkpatch.pl from Linux kernel

Unchanged import from
http://www.kernel.org/pub/linux/kernel/people/apw/checkpatch/checkpatch.pl-0.31

Signed-off-by: Blue Swirl <>

4c3b5a48 01/20/2011 10:54 pm Blue Swirl

Add scripts directory

Move build and user scripts into scripts directory.

Signed-off-by: Blue Swirl <>