From: Antti Laakso <antti.laakso@linux.intel.com>
To: Sakari Ailus <sakari.ailus@linux.intel.com>
Cc: linux-media@vger.kernel.org, "Sapre,
Sarang" <sarang.sapre@intel.com>,
Manik Bajpai <manik.bajpai@intel.com>,
Divyamani Tripathi <divyamani.tripathi@intel.com>
Subject: Re: [PATCH 2/2] media: ipu6: Warn if the active list isn't empty when returning buffers
Date: Wed, 30 Sep 2026 12:23:52 +0300 [thread overview]
Message-ID: <arzVKOdobIONAwwB@alaakso-desk> (raw)
In-Reply-To: <20260929105415.2516142-3-sakari.ailus@linux.intel.com>
On Tue, Sep 29, 2026 at 01:54:15PM +0300, Sakari Ailus wrote:
> The ISYS needs a reset when the active buffer list isn't empty. Warn about
> this.
>
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
> ---
> drivers/media/pci/intel/ipu6/ipu6-isys-queue.c | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/drivers/media/pci/intel/ipu6/ipu6-isys-queue.c b/drivers/media/pci/intel/ipu6/ipu6-isys-queue.c
> index 2608e3b91acb..c9ecda158fd1 100644
> --- a/drivers/media/pci/intel/ipu6/ipu6-isys-queue.c
> +++ b/drivers/media/pci/intel/ipu6/ipu6-isys-queue.c
> @@ -423,6 +423,7 @@ static void return_buffers(struct ipu6_isys_queue *aq,
> struct ipu6_isys_video *av = ipu6_isys_queue_to_video(aq);
> struct ipu6_isys_buffer *ib;
> bool need_reset = false;
> + bool first_buf = true;
> unsigned long flags;
>
> spin_lock_irqsave(&aq->lock, flags);
> @@ -448,6 +449,12 @@ static void return_buffers(struct ipu6_isys_queue *aq,
> while (!list_empty(&aq->active)) {
> struct vb2_buffer *vb;
>
> + if (first_buf) {
> + dev_warn(&av->isys->adev->auxdev.dev,
> + "buffer list not empty, needs isys reset\n");
> + first_buf = false;
> + }
Could the warning be in the end of the function, in need_reset block. We
could save one local variable too.
> +
> ib = list_first_entry(&aq->active, struct ipu6_isys_buffer,
> head);
> vb = ipu6_isys_buffer_to_vb2_buffer(ib);
> --
> 2.47.3
>
next prev parent reply other threads:[~2026-09-30 9:23 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-29 10:54 [PATCH 0/2] IPU6 fixes following multi-stream support Sakari Ailus
2026-09-29 10:54 ` [PATCH 1/2] media: ipu6: Reset need_reset in ISYS suspend Sakari Ailus
2026-09-29 10:54 ` [PATCH 2/2] media: ipu6: Warn if the active list isn't empty when returning buffers Sakari Ailus
2026-09-30 9:23 ` Antti Laakso [this message]
2026-09-30 9:33 ` Sakari Ailus
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=arzVKOdobIONAwwB@alaakso-desk \
--to=antti.laakso@linux.intel.com \
--cc=divyamani.tripathi@intel.com \
--cc=linux-media@vger.kernel.org \
--cc=manik.bajpai@intel.com \
--cc=sakari.ailus@linux.intel.com \
--cc=sarang.sapre@intel.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