Skip to content

IDE: replace printfs with tracing

John Snow qemu-devel 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest9 patches 5 repliesIn review
  2. v29 patches 11 repliesSuperseded
  3. v19 patches 25 repliesSuperseded

Changes in v3 from the cover letter

===

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9IDE: replace DEBUG_IDE with tracing systemMakefile.objs hw/ide/cmd646.c hw/ide/core.c +5 more+80 -700 replies
2/9IDE: Add register hints to tracinghw/ide/core.c hw/ide/trace-events+72 -240 replies
3/9IDE: add tracing for data portshw/ide/core.c hw/ide/trace-events+16 -10 replies
4/9ATAPI: Replace DEBUG_IDE_ATAPI with tracing eventshw/ide/atapi.c hw/ide/trace-events include/hw/ide/internal.h+38 -420 replies
5/9IDE: replace DEBUG_AIO with trace eventshw/ide/atapi.c hw/ide/core.c hw/ide/trace-events +1 more+25 -132 replies
6/9AHCI: Replace DPRINTF with trace-eventshw/ide/ahci.c hw/ide/trace-events+117 -890 replies
7/9AHCI: Rework IRQ constantshw/ide/ahci.c hw/ide/ahci_internal.h hw/ide/trace-events+74 -210 replies
8/9AHCI: pretty-print FIS to buffer instead of stderrhw/ide/ahci.c hw/ide/trace-events+22 -100 replies
9/9AHCI: remove DPRINTF macrohw/ide/ahci.c+0 -90 replies

Reviews trailers per patch

7 of 9 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchEric BlakePhilippe Mathieu-DaudéStefan Hajnoczi
SeriesR-b
1/9R-b
2/9R-b
3/9R-b
4/9
5/9R-b
6/9R-b
7/9R-b
8/9
9/9R-b T-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v3 thread

Cover letter [Qemu-devel] [PATCH v3 0/9] IDE: replace printfs with tracing

Wherever possible, replace all printfs with proper tracing. In most places I've tried to do a straight replacement, but forthcoming patches may calibrate the tracing to be a little nicer.

For now, it's nice to just remove the all-or-nothing tracing.

Key:
[----] : patches are identical
[####] : number of functional differences between upstream/downstream patch [down] : patch is downstream-only
The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively

001/9:[----] [--] 'IDE: replace DEBUG_IDE with tracing system' 002/9:[----] [--] 'IDE: Add register hints to tracing' 003/9:[----] [--] 'IDE: add tracing for data ports' 004/9:[0002] [FC] 'ATAPI: Replace DEBUG_IDE_ATAPI with tracing events' 005/9:[0011] [FC] 'IDE: replace DEBUG_AIO with trace events' 006/9:[----] [--] 'AHCI: Replace DPRINTF with trace-events' 007/9:[0004] [FC] 'AHCI: Rework IRQ constants'
008/9:[0052] [FC] 'AHCI: pretty-print FIS to buffer instead of stderr' 009/9:[----] [--] 'AHCI: remove DPRINTF macro'

===
v3:
===

04: Change preprocessor gate mechanism for building cmd
packet buffer dumps (Stefan)
05: Add getter for IDE_DMA_CMD enumeration (Philippe)
07: Changed AHCI enumeration to match changes in 05,
(But leave assert in place to guard lookup table instead
of adding getter.)
08: Replace FIS buffer printer with something simpler (Stefan)
Change preprocessor gate mechanism for building AHCI buffer dumps (Stefan) enconstify char parameters in trace-events file (Stefan)

===
v2:
===

01: Rehabilitate commit message.
Fix switch () statement spacing. (Eric)
Adjust spacing in ide-tracing file to maintain columns. Change filename orderings in trace-events. (Eric) Fixed newline issue in trace-events. (Eric)

02: Context / Added R-B.

03: Added trace-events items to appropriate patch (removed from 04) (Eric)
Added a verbose warning for data tracers (Eric)

04: Shifted items to 03 (Eric)
Fixed newline issue (Eric)

05: Changed __END to __COUNT (Philippe)
Removed __BEGIN enumerator (Philippe)

06: Added more information to unknown write (Philippe)

08: Context (Entropy)

John Snow (9):
IDE: replace DEBUG_IDE with tracing system
IDE: Add register hints to tracing
IDE: add tracing for data ports
ATAPI: Replace DEBUG_IDE_ATAPI with tracing events
IDE: replace DEBUG_AIO with trace events
AHCI: Replace DPRINTF with trace-events
AHCI: Rework IRQ constants
AHCI: pretty-print FIS to buffer instead of stderr
AHCI: remove DPRINTF macro

 Makefile.objs             |   1 +
 hw/ide/ahci.c             | 243 +++++++++++++++++++++++-----------------------
 hw/ide/ahci_internal.h    |  44 +++++++--
 hw/ide/atapi.c            |  69 +++++--------
 hw/ide/cmd646.c           |  10 +-
 hw/ide/core.c             | 185 ++++++++++++++++++++++-------------
 hw/ide/pci.c              |  17 +---
 hw/ide/piix.c             |  11 +--
 hw/ide/trace-events       | 111 +++++++++++++++++++++
 hw/ide/via.c              |  10 +-
 include/hw/ide/internal.h |   8 +-
 11 files changed, 437 insertions(+), 272 deletions(-)
 create mode 100644 hw/ide/trace-events
Signature · 1 line
2.9.5