Skip to content

v4l2-tracer: fix expected frame length calculation

Sarah Gershuni linux-media 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2add plane_bytesperline to trace_contextutils/v4l2-tracer/trace-helper.cpp utils/v4l2-tracer/trace.h+14 -20 replies
2/2calculate expected length using v4l2-fwht infoutils/v4l2-tracer/trace-helper.cpp+28 -120 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] v4l2-tracer: fix expected frame length calculation

This series fixes the calculation of expected frame lengths in v4l2-tracer. Previously, the calculation assumed that the stride equals the width and that chroma padding follows the end of the plane, which could result in incorrect lengths.

Patch 1/2: add plane_bytesperline to trace_context
- Introduces plane_bytesperline to store the stride of each plane, providing the necessary data to compute accurate frame lengths.

Patch 2/2: calculate expected length using v4l2-fwht info
- Computes the frame length per plane correctly, fixing previous inaccuracies.

Together, these patches ensure that v4l2-tracer calculates expected frame lengths accurately for all supported pixel formats.

Sarah Gershuni (2):
add plane_bytesperline to trace_context
calculate expected length using v4l2-fwht info

 utils/v4l2-tracer/trace-helper.cpp | 55 ++++++++++++++++++++++--------
 utils/v4l2-tracer/trace.h          |  1 +
 2 files changed, 42 insertions(+), 14 deletions(-)
Signature · 1 line
2.43.0