From: Nicolas Dufresne <nicolas.dufresne@collabora.com>
To: Siddharth Vadapalli <s-vadapalli@ti.com>,
mchehab@kernel.org, jai.luthra@linux.dev,
detlev.casanova@collabora.com, hverkuil+cisco@kernel.org,
sakari.ailus@linux.intel.com, richard.leitner@linux.dev,
jackson.lee@chipsnmedia.com
Cc: linux-media@vger.kernel.org,
linux-arm-kernel@lists.infradead.org, devarsht@ti.com,
vigneshr@ti.com, srk@ti.com
Subject: Re: [PATCH 1/3] media: v4l2: Add V4L2_EVENT_BUF_PROGRESS to report progress of capture
Date: Mon, 30 Nov 2026 10:21:49 -0500 [thread overview]
Message-ID: <a531bccd7b36304f150d3c25cfc6f4fa74f2ccd9.camel@collabora.com> (raw)
In-Reply-To: <20261129132825.4031308-2-s-vadapalli@ti.com>
[-- Attachment #1: Type: text/plain, Size: 1235 bytes --]
Hi,
Le dimanche 29 novembre 2026 à 18:58 +0530, Siddharth Vadapalli a écrit :
> + The buffer remains owned by the driver until it is dequeued, and the
> + driver does not perform any cache maintenance on the part of the
> + buffer that was reported. An application that reads that part before
> + the buffer is dequeued must make sure that its mapping is coherent
> + with DMA, which is not the case for memory allocated with
> + ``V4L2_MEMORY_FLAG_NON_COHERENT``. For buffers with memory type
> + ``V4L2_MEMORY_DMABUF``, cache management is the responsibility of
> + the exporter of the buffer.
I think outside of write-combine, which you likely use, this is completely
unusable. Its not possible to do device cache management properly without the
context the driver has.
May I propose for the event to deliver a dma fence. Then the driver that do use
device caches can spawn a worker that will signal the fence when the memory is
actually ready. On top of which, you can deliver the fence once the transfer is
proven to have started, rather then when its complet. Sub-frame, unless you only
care about really slow devices, introduce very tight timing which only dma
fences will really cover.
Nicolas
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2026-11-30 15:22 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-29 13:28 [PATCH 0/3] media: Add V4L2_EVENT_BUF_PROGRESS and use it in j721e-csi2rx Siddharth Vadapalli
2026-11-29 13:28 ` [PATCH 1/3] media: v4l2: Add V4L2_EVENT_BUF_PROGRESS to report progress of capture Siddharth Vadapalli
2026-11-30 15:21 ` Nicolas Dufresne [this message]
2026-11-29 13:28 ` [PATCH 2/3] media: v4l2-ctrls: Add buffer progress controls for sub-frame functionality Siddharth Vadapalli
2026-11-29 13:28 ` [PATCH 3/3] media: ti: j721e-csi2rx: Generate capture-progress events for sub-frames Siddharth Vadapalli
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a531bccd7b36304f150d3c25cfc6f4fa74f2ccd9.camel@collabora.com \
--to=nicolas.dufresne@collabora.com \
--cc=detlev.casanova@collabora.com \
--cc=devarsht@ti.com \
--cc=hverkuil+cisco@kernel.org \
--cc=jackson.lee@chipsnmedia.com \
--cc=jai.luthra@linux.dev \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=richard.leitner@linux.dev \
--cc=s-vadapalli@ti.com \
--cc=sakari.ailus@linux.intel.com \
--cc=srk@ti.com \
--cc=vigneshr@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox