From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7B7D83BB11C; Fri, 15 May 2026 16:17:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778861879; cv=none; b=nouccAJE9k0dWeYCFrIecAW6gHmxH60EZ4fAn0stIyFP9fF0ZlIrONTmekhTH+3mAR4D5lIWOYJ3UHOU/sX4ZXGvFkNUeYYH41SW2U3ID6dAiM5it6TmOVybrh3aKc/LIfg47OfORKwFBJa4fg1PakOwVchsmAig5qDHEdAa+a4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778861879; c=relaxed/simple; bh=TtQhzETxuY8PDTFGlcU69wlKzxy4SfxyojBO32Xx718=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=aEIqXCYBofle2tdy+14yfGEv1wwk8dKp6Xqd+zTf/aso5KtMMUQOV+QXBEyn/iyTnBgGBHUeOQ6W/FEzqYk8B7LSCB8DVyRyY2YeTlY+OVHyKjRiK6l+Xa0gxfF+DrrzcpbKFwraVSE73cQ+lpB59tLz6cmIjwbupGA0l0IEKwM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=DrnxXAm1; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="DrnxXAm1" Received: by smtp.kernel.org (Postfix) with ESMTPSA id CE157C2BCB0; Fri, 15 May 2026 16:17:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1778861879; bh=TtQhzETxuY8PDTFGlcU69wlKzxy4SfxyojBO32Xx718=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DrnxXAm1EEBstUxIMv6saC9NWeC91AEGfLkdgWwTXzjFsQmLudhjE5dOXPj6vKbbb 86MU0myoFQ/VVU10r0MxG5vQx8WiMa7ghXPUgDlngcAttCC5gyhVABxIWTuJKazAV2 aUAp/0PKcc9tgeJinTHLFnVm3JYTO6ZNU/gc3xyw= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Guoniu Zhou , Laurent Pinchart , Hans Verkuil Subject: [PATCH 6.18 009/188] media: nxp: imx8-isi: Reduce minimum queued buffers from 2 to 0 Date: Fri, 15 May 2026 17:47:06 +0200 Message-ID: <20260515154657.511931556@linuxfoundation.org> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260515154657.309489048@linuxfoundation.org> References: <20260515154657.309489048@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.18-stable review patch. If anyone has any objections, please let me know. ------------------ From: Guoniu Zhou commit 2f38622d0f85f317be9e6b131da6cd511db94fd2 upstream. Fix a hang issue when capturing a single frame with applications like cam in libcamera. It would hang waiting for the driver to complete the buffer, but streaming never starts because min_queued_buffers was set to 2. The ISI module uses a ping-pong buffer mechanism that requires two buffers to be programmed at all times. However, when fewer than 2 user buffers are available, the driver use internal discard buffers to fill the remaining slot(s). Reduce minimum queued buffers from 2 to 0 allows streaming to start without any queued buffers. Fixes: cf21f328fcaf ("media: nxp: Add i.MX8 ISI driver") Cc: stable@vger.kernel.org Signed-off-by: Guoniu Zhou Reviewed-by: Laurent Pinchart Link: https://patch.msgid.link/20260312-isi_min_buffers-v2-1-d5ea1c79ad81@nxp.com Signed-off-by: Laurent Pinchart Signed-off-by: Hans Verkuil Signed-off-by: Greg Kroah-Hartman --- drivers/media/platform/nxp/imx8-isi/imx8-isi-video.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/media/platform/nxp/imx8-isi/imx8-isi-video.c +++ b/drivers/media/platform/nxp/imx8-isi/imx8-isi-video.c @@ -1410,7 +1410,7 @@ int mxc_isi_video_register(struct mxc_is q->mem_ops = &vb2_dma_contig_memops; q->buf_struct_size = sizeof(struct mxc_isi_buffer); q->timestamp_flags = V4L2_BUF_FLAG_TIMESTAMP_MONOTONIC; - q->min_queued_buffers = 2; + q->min_queued_buffers = 0; q->lock = &video->lock; q->dev = pipe->isi->dev;