mbox series

[0/5] trace: Remove and forbid newline characters in event format

Message ID 20240606103943.79116-1-philmd@linaro.org
Headers show
Series trace: Remove and forbid newline characters in event format | expand

Message

Philippe Mathieu-Daudé June 6, 2024, 10:39 a.m. UTC
Trace events aren't designed to be multi-lines.
Few format use the newline character: remove it
and forbid further uses.

Philippe Mathieu-Daudé (5):
  backends/tpm: Remove newline character in trace event
  hw/sh4: Remove newline character in trace events
  hw/usb: Remove newline character in trace events
  hw/vfio: Remove newline character in trace events
  tracetool: Forbid newline character in event format

 backends/tpm/tpm_util.c       | 5 +++--
 backends/tpm/trace-events     | 3 ++-
 hw/sh4/trace-events           | 4 ++--
 hw/usb/trace-events           | 6 +++---
 hw/vfio/trace-events          | 4 ++--
 scripts/tracetool/__init__.py | 2 ++
 6 files changed, 14 insertions(+), 10 deletions(-)

Comments

Mads Ynddal June 7, 2024, 10:46 a.m. UTC | #1
> 
> Trace events aren't designed to be multi-lines.
> Few format use the newline character: remove it
> and forbid further uses.
> 
> Philippe Mathieu-Daudé (5):
>  backends/tpm: Remove newline character in trace event
>  hw/sh4: Remove newline character in trace events
>  hw/usb: Remove newline character in trace events
>  hw/vfio: Remove newline character in trace events
>  tracetool: Forbid newline character in event format
> 
> backends/tpm/tpm_util.c       | 5 +++--
> backends/tpm/trace-events     | 3 ++-
> hw/sh4/trace-events           | 4 ++--
> hw/usb/trace-events           | 6 +++---
> hw/vfio/trace-events          | 4 ++--
> scripts/tracetool/__init__.py | 2 ++
> 6 files changed, 14 insertions(+), 10 deletions(-)
> 
> -- 
> 2.41.0
> 

Acked-by: Mads Ynddal <mads@ynddal.dk>
Stefan Hajnoczi June 10, 2024, 5:05 p.m. UTC | #2
On Thu, Jun 06, 2024 at 12:39:38PM +0200, Philippe Mathieu-Daudé wrote:
> Trace events aren't designed to be multi-lines.
> Few format use the newline character: remove it
> and forbid further uses.
> 
> Philippe Mathieu-Daudé (5):
>   backends/tpm: Remove newline character in trace event
>   hw/sh4: Remove newline character in trace events
>   hw/usb: Remove newline character in trace events
>   hw/vfio: Remove newline character in trace events
>   tracetool: Forbid newline character in event format
> 
>  backends/tpm/tpm_util.c       | 5 +++--
>  backends/tpm/trace-events     | 3 ++-
>  hw/sh4/trace-events           | 4 ++--
>  hw/usb/trace-events           | 6 +++---
>  hw/vfio/trace-events          | 4 ++--
>  scripts/tracetool/__init__.py | 2 ++
>  6 files changed, 14 insertions(+), 10 deletions(-)
> 
> -- 
> 2.41.0
> 

Thanks, applied to my tracing tree:
https://gitlab.com/stefanha/qemu/commits/tracing

Stefan
Philippe Mathieu-Daudé June 10, 2024, 5:59 p.m. UTC | #3
On 10/6/24 19:05, Stefan Hajnoczi wrote:
> On Thu, Jun 06, 2024 at 12:39:38PM +0200, Philippe Mathieu-Daudé wrote:
>> Trace events aren't designed to be multi-lines.
>> Few format use the newline character: remove it
>> and forbid further uses.
>>
>> Philippe Mathieu-Daudé (5):
>>    backends/tpm: Remove newline character in trace event
>>    hw/sh4: Remove newline character in trace events
>>    hw/usb: Remove newline character in trace events
>>    hw/vfio: Remove newline character in trace events
>>    tracetool: Forbid newline character in event format


> Thanks, applied to my tracing tree:
> https://gitlab.com/stefanha/qemu/commits/tracing

Thanks!