lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YkgpwSJFkOH9+tuA@eze-laptop>
Date:   Sat, 2 Apr 2022 07:47:29 -0300
From:   Ezequiel Garcia <ezequiel@...guardiasur.com.ar>
To:     Nicolas Dufresne <nicolas.dufresne@...labora.com>
Cc:     Mauro Carvalho Chehab <mchehab@...nel.org>, kernel@...labora.com,
        Sebastian Fricke <sebastian.fricke@...labora.com>,
        linux-media@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 02/23] media: v4l2-mem2mem: Trace on implicit un-hold

On Thu, Mar 31, 2022 at 03:37:04PM -0400, Nicolas Dufresne wrote:
> If the timestamp of the src buffer differs from the timestamp of a held
> dst buffer, the held buffer is implicitly removed and marked as done.
> Add a trace to help debugging if someone hits that case.
> 
> Signed-off-by: Nicolas Dufresne <nicolas.dufresne@...labora.com>
> Reviewed-by: Sebastian Fricke <sebastian.fricke@...labora.com>
> ---
>  drivers/media/v4l2-core/v4l2-mem2mem.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/media/v4l2-core/v4l2-mem2mem.c b/drivers/media/v4l2-core/v4l2-mem2mem.c
> index 675e22895ebe..fbcd79763e8f 100644
> --- a/drivers/media/v4l2-core/v4l2-mem2mem.c
> +++ b/drivers/media/v4l2-core/v4l2-mem2mem.c
> @@ -336,6 +336,7 @@ static void __v4l2_m2m_try_queue(struct v4l2_m2m_dev *m2m_dev,
>  	if (src && dst && dst->is_held &&
>  	    dst->vb2_buf.copied_timestamp &&
>  	    dst->vb2_buf.timestamp != src->vb2_buf.timestamp) {
> +		dprintk("src and dst timestamp mismatch, removing held capture buffer.\n");

Nitpick: I would try to make this log consistent with the other logs,
avoid refering to "src" and "dst" and start with a capital letter.

How about "Timestamp mismatch, returning held capture buffer".

Either way, thanks for improving this.

Reviewed-by: Ezequiel Garcia <ezequiel@...guardiasur.com.ar>

>  		dst->is_held = false;
>  		v4l2_m2m_dst_buf_remove(m2m_ctx);
>  		v4l2_m2m_buf_done(dst, VB2_BUF_STATE_DONE);
> -- 
> 2.34.1
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ