From: Eugen Hristev <ehristev@kernel.org>
To: Balakrishnan Sambath <balakrishnan.s@microchip.com>,
Eugen Hristev <ehristev@kernel.org>,
Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: Hans Verkuil <hverkuil@kernel.org>,
Sakari Ailus <sakari.ailus@linux.intel.com>,
linux-media@vger.kernel.org, linux-kernel@vger.kernel.org,
stable@vger.kernel.org
Subject: Re: [PATCH 04/10] media: microchip-isc: disable histogram and flush AWB work on stop
Date: Sun, 21 Jun 2026 09:23:22 +0300 [thread overview]
Message-ID: <dad6ba27-5fd1-4a52-ae0b-6e0db3a9d1eb@kernel.org> (raw)
In-Reply-To: <20260616-balki-isc-prefix-fixes-v1-v1-4-b23677fc5ab6@microchip.com>
On 6/16/26 14:50, Balakrishnan Sambath wrote:
> isc_stop_streaming() masked the DMA done interrupt but left the
> histogram enabled, so a HISDONE that fired just before the stop could
> still queue isc_awb_work() after pm_runtime_put_sync() gated the clocks.
> isc_awb_work() reads the histogram registers in isc_hist_count() before
> taking its own PM reference, so the access faults on the suspended
> device.
>
> Disable the histogram and flush the work before dropping the PM
> reference, mirroring the start_streaming error path.
>
In here you reference some error path that you mirror, but you add it in
the next commit in which you say you mirror this exact commit :/
Circular mirroring of paths which initially did not exist.
I would squash this commit with the next one and show the facts as they
are : stop histogram and work queue in different stop/error scenarios,
no more mirroring.
Eugen
> Fixes: 91b4e487b0c6 ("media: microchip: add ISC driver as Microchip ISC")
> Cc: stable@vger.kernel.org
> Signed-off-by: Balakrishnan Sambath <balakrishnan.s@microchip.com>
> ---
> drivers/media/platform/microchip/microchip-isc-base.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/media/platform/microchip/microchip-isc-base.c b/drivers/media/platform/microchip/microchip-isc-base.c
> index 3245dd7cb980..8f255a4c4e7a 100644
> --- a/drivers/media/platform/microchip/microchip-isc-base.c
> +++ b/drivers/media/platform/microchip/microchip-isc-base.c
> @@ -425,9 +425,13 @@ static void isc_stop_streaming(struct vb2_queue *vq)
> /* Disable DMA interrupt */
> regmap_write(isc->regmap, ISC_INTDIS, ISC_INT_DDONE);
>
> + isc_set_histogram(isc, false);
> +
> /* let a running IRQ handler finish before the clock is disabled */
> synchronize_irq(isc->irq);
>
> + cancel_work_sync(&isc->awb_work);
> +
> pm_runtime_put_sync(isc->dev);
>
> /* Disable stream on the sub device */
>
next prev parent reply other threads:[~2026-06-21 6:23 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-16 11:50 [PATCH 00/10] media: microchip-isc: AWB, stream-stop and endpoint-ref fixes Balakrishnan Sambath
2026-06-16 11:50 ` [PATCH 01/10] media: microchip-isc: fix awb_mutex and lock lifecycle Balakrishnan Sambath
2026-06-16 11:50 ` [PATCH 02/10] media: microchip-isc: take a reference on the parsed endpoints Balakrishnan Sambath
2026-06-16 11:50 ` [PATCH 03/10] media: microchip-isc: synchronize the IRQ before disabling clocks on stop Balakrishnan Sambath
2026-06-19 8:01 ` Eugen Hristev
2026-06-16 11:50 ` [PATCH 04/10] media: microchip-isc: disable histogram and flush AWB work " Balakrishnan Sambath
2026-06-21 6:23 ` Eugen Hristev [this message]
2026-06-22 11:27 ` Balakrishnan.S
2026-06-16 11:51 ` [PATCH 05/10] media: microchip-isc: clean up histogram on the start_streaming error path Balakrishnan Sambath
2026-06-16 11:51 ` [PATCH 06/10] media: microchip-isc: do not touch WB registers when not streaming Balakrishnan Sambath
2026-06-16 11:51 ` [PATCH 07/10] media: microchip-isc: fix pfe_cfg0_bps comment Balakrishnan Sambath
2026-06-21 6:27 ` Eugen Hristev
2026-06-22 11:32 ` Balakrishnan.S
2026-06-23 6:29 ` Eugen Hristev
2026-06-16 11:51 ` [PATCH 08/10] media: microchip-isc: fix PM runtime leak in AWB work handler Balakrishnan Sambath
2026-06-16 11:51 ` [PATCH 09/10] media: microchip-isc: fix SBGGR10 Bayer pattern Balakrishnan Sambath
2026-06-16 11:51 ` [PATCH 10/10] media: microchip-isc: fix WB offset and gain register field masking Balakrishnan Sambath
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=dad6ba27-5fd1-4a52-ae0b-6e0db3a9d1eb@kernel.org \
--to=ehristev@kernel.org \
--cc=balakrishnan.s@microchip.com \
--cc=hverkuil@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=stable@vger.kernel.org \
/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
all inboxes | Powered by JetHome®