From nobody Sat Feb 7 09:29:36 2026 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) (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 7414831D75C; Mon, 5 Jan 2026 17:12:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=213.167.242.64 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767633135; cv=none; b=CLaqbd/+Fb84TstYJU3FJLSXoW7PjBXhfY0U/8KqJgnXtXKWlsqa8AgOe1Q7CkOWKUWX9Tzz4xWony0nsUuuGOg5V23P662RT8ZXTDgkvld0reIZzrjeHJCl4AMWXXeAUMP1Zhmmn541QrlCwdxK+eHnNZY5g9f1ScW/gBblHxA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767633135; c=relaxed/simple; bh=pDIvxJGIlX+hjy9FPe//FACZ0eNRYp4yWgqfgSVzjBg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=PKzc0uvGJrWPyxLDhX6K1TMiXixOFyvoqfCBBJTLv2kpm7/dXb7ds4wYZeDd+T/AYRLV6ncPAHdX7Z16pIelVZ9Fv3O9bG2SMhUUW9EHz76021LHNGvfShMge+6uLC5XKSfYCmki120iJ34WR0Ouz5MYAJLyG1nOJDJrrRPI5iE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=ideasonboard.com; spf=pass smtp.mailfrom=ideasonboard.com; dkim=pass (1024-bit key) header.d=ideasonboard.com header.i=@ideasonboard.com header.b=D8swEKdl; arc=none smtp.client-ip=213.167.242.64 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=ideasonboard.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ideasonboard.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="D8swEKdl" Received: from rui-Precision-7560.local (unknown [209.216.103.65]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 4B9A026D1; Mon, 5 Jan 2026 18:11:47 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1767633109; bh=pDIvxJGIlX+hjy9FPe//FACZ0eNRYp4yWgqfgSVzjBg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=D8swEKdlCt4EECcT3W9lhQhwoxfmQdRuN/04e2sWFC8pTYuRHbdUVvh3ihUBh86/O x8IwdtlXNST1Xf4IZmASJpiKYEOB3Fm+HV0K79LxbadfVpgav8R8uvbuxWb4yreQo3 Smj0jhtMcQmVhCjR5jUZfTu5Fe8ZrbcFPcGbSkTc= From: Rui Wang To: linux-media@vger.kernel.org, dafna@fastmail.com, laurent.pinchart@ideasonboard.com, mchehab@kernel.org, heiko@sntech.de, linux-rockchip@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: libcamera-devel@lists.libcamera.org, Rui Wang Subject: [PATCH v4 1/1] media: rkisp1: Fix filter mode register configuration Date: Mon, 5 Jan 2026 12:11:42 -0500 Message-ID: <20260105171142.147792-2-rui.wang@ideasonboard.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260105171142.147792-1-rui.wang@ideasonboard.com> References: <20260105171142.147792-1-rui.wang@ideasonboard.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" The rkisp1_flt_config() function performs an initial direct write to RKISP1_CIF_ISP_FILT_MODE without including the RKISP1_CIF_ISP_FLT_ENA bit, which clears the filter enable bit in the hardware. The subsequent read/modify/write sequence then reads back the register with the enable bit already cleared and cannot restore it, resulting in the filter being inadvertently disabled. Remove the redundant direct write. The read/modify/write sequence alone correctly preserves the existing enable bit state while updating the DNR mode and filter configuration bits. Signed-off-by: Rui Wang Reviewed-by Stefan Klug and Kieran Bingham Reviewed-by: Kieran Bingham Reviewed-by: Laurent Pinchart Reviewed-by: Stefan Klug --- =20 Changelog since v1: 1. Update version number from v1 to v4 to clarify the confusing Reviewed-by Stefan Klug and Kieran Bingham from v1 are carried over (no function code changes). drivers/media/platform/rockchip/rkisp1/rkisp1-params.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/drivers/media/platform/rockchip/rkisp1/rkisp1-params.c b/drive= rs/media/platform/rockchip/rkisp1/rkisp1-params.c index c9f88635224c..6442436a5e42 100644 --- a/drivers/media/platform/rockchip/rkisp1/rkisp1-params.c +++ b/drivers/media/platform/rockchip/rkisp1/rkisp1-params.c @@ -411,12 +411,6 @@ static void rkisp1_flt_config(struct rkisp1_params *pa= rams, rkisp1_write(params->rkisp1, RKISP1_CIF_ISP_FILT_LUM_WEIGHT, arg->lum_weight); =20 - rkisp1_write(params->rkisp1, RKISP1_CIF_ISP_FILT_MODE, - (arg->mode ? RKISP1_CIF_ISP_FLT_MODE_DNR : 0) | - RKISP1_CIF_ISP_FLT_CHROMA_V_MODE(arg->chr_v_mode) | - RKISP1_CIF_ISP_FLT_CHROMA_H_MODE(arg->chr_h_mode) | - RKISP1_CIF_ISP_FLT_GREEN_STAGE1(arg->grn_stage1)); - /* avoid to override the old enable value */ filt_mode =3D rkisp1_read(params->rkisp1, RKISP1_CIF_ISP_FILT_MODE); filt_mode &=3D RKISP1_CIF_ISP_FLT_ENA; --=20 2.43.0