Add video_compress_fb_() which takes an additional msg parameter to describe the frame being checked. This helps with debugging when a frame check fails. The existing video_compress_fb() becomes a wrapper that passes NULL for the message. Co-developed-by: Claude Opus 4.5 <noreply@anthropic.com> Signed-off-by: Simon Glass <simon.glass@canonical.com> --- test/dm/video.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/test/dm/video.c b/test/dm/video.c index b7aa835c86a..421d50df064 100644 --- a/test/dm/video.c +++ b/test/dm/video.c @@ -138,8 +138,8 @@ static int video_write_bmp(struct unit_test_state *uts, struct udevice *dev, return ret; } -int video_compress_fb(struct unit_test_state *uts, struct udevice *dev, - bool use_copy) +static int video_compress_fb_(struct unit_test_state *uts, struct udevice *dev, + bool use_copy, const char *msg) { struct sandbox_state *state = state_get_current(); struct video_priv *priv = dev_get_uclass_priv(dev); @@ -184,6 +184,12 @@ int video_compress_fb(struct unit_test_state *uts, struct udevice *dev, return destlen; } +int video_compress_fb(struct unit_test_state *uts, struct udevice *dev, + bool use_copy) +{ + return video_compress_fb_(uts, dev, use_copy, NULL); +} + int video_check_copy_fb(struct unit_test_state *uts, struct udevice *dev) { struct video_priv *priv = dev_get_uclass_priv(dev); -- 2.43.0