hw/gpio/omap_gpio: Use CamelCase for TYPE_OMAP1_GPIO type name
[qemu.git] / qapi / trace.json
blob6c6982a58730df8001366b732926f231552240c5
1 # -*- mode: python -*-
2 # vim: filetype=python
4 # Copyright (C) 2011-2016 LluĂ­s Vilanova <vilanova@ac.upc.edu>
6 # This work is licensed under the terms of the GNU GPL, version 2 or later.
7 # See the COPYING file in the top-level directory.
9 ##
10 # = Tracing
14 # @TraceEventState:
16 # State of a tracing event.
18 # @unavailable: The event is statically disabled.
20 # @disabled: The event is dynamically disabled.
22 # @enabled: The event is dynamically enabled.
24 # Since: 2.2
26 { 'enum': 'TraceEventState',
27   'data': ['unavailable', 'disabled', 'enabled'] }
30 # @TraceEventInfo:
32 # Information of a tracing event.
34 # @name: Event name.
35 # @state: Tracing state.
36 # @vcpu: Whether this is a per-vCPU event (since 2.7).
38 # An event is per-vCPU if it has the "vcpu" property in the "trace-events"
39 # files.
41 # Since: 2.2
43 { 'struct': 'TraceEventInfo',
44   'data': {'name': 'str', 'state': 'TraceEventState', 'vcpu': 'bool'} }
47 # @trace-event-get-state:
49 # Query the state of events.
51 # @name: Event name pattern (case-sensitive glob).
52 # @vcpu: The vCPU to query (any by default; since 2.7).
54 # Returns: a list of @TraceEventInfo for the matching events
56 #          An event is returned if:
58 #          - its name matches the @name pattern, and
59 #          - if @vcpu is given, the event has the "vcpu" property.
61 #          Therefore, if @vcpu is given, the operation will only match per-vCPU events,
62 #          returning their state on the specified vCPU. Special case: if @name is an
63 #          exact match, @vcpu is given and the event does not have the "vcpu" property,
64 #          an error is returned.
66 # Since: 2.2
68 # Example:
70 # -> { "execute": "trace-event-get-state",
71 #      "arguments": { "name": "qemu_memalign" } }
72 # <- { "return": [ { "name": "qemu_memalign", "state": "disabled", "vcpu": false } ] }
75 { 'command': 'trace-event-get-state',
76   'data': {'name': 'str', '*vcpu': 'int'},
77   'returns': ['TraceEventInfo'] }
80 # @trace-event-set-state:
82 # Set the dynamic tracing state of events.
84 # @name: Event name pattern (case-sensitive glob).
85 # @enable: Whether to enable tracing.
86 # @ignore-unavailable: Do not match unavailable events with @name.
87 # @vcpu: The vCPU to act upon (all by default; since 2.7).
89 # An event's state is modified if:
90 # - its name matches the @name pattern, and
91 # - if @vcpu is given, the event has the "vcpu" property.
93 # Therefore, if @vcpu is given, the operation will only match per-vCPU events,
94 # setting their state on the specified vCPU. Special case: if @name is an exact
95 # match, @vcpu is given and the event does not have the "vcpu" property, an
96 # error is returned.
98 # Since: 2.2
100 # Example:
102 # -> { "execute": "trace-event-set-state",
103 #      "arguments": { "name": "qemu_memalign", "enable": true } }
104 # <- { "return": {} }
107 { 'command': 'trace-event-set-state',
108   'data': {'name': 'str', 'enable': 'bool', '*ignore-unavailable': 'bool',
109            '*vcpu': 'int'} }