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 9DD3244A409; Wed, 14 Oct 2026 06:49:48 +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=1791960588; cv=none; b=E7r/8fd06uPphUqUrDK38CXY+zGnQeNlH3mbgBTXBUg0x7zKfCF8B6tYXFc1hO3EhcqOCuKOREjxdvZ/QVQSpIR/MZAuY4VnU0IdQIzQpU5eJ9ussFDyo1mIPMcoN2Uh/ZgHanpTCA9OLYW213lxNyOEIw+BR+S7O/maS/80D7E= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1791960588; c=relaxed/simple; bh=zgzIKcPpPlhwn+/jD26bwEQDWYZk4cqXx3wE756XGPw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=LrVncuYwRwI6t0GyljA42Hvr3vv+6HC3SC1gKlF73zU2qJ1i+pXTc4jE7r64arRMjn9kcx/vST32LY99NQaDZlsOy00A6W6Gp9LvYJqanIFr6nwcdV+0/NpF42wiBmcUtq3lWiiz8WWLYDMtJKrCJrbkAOOhwZDBU/LO7fTlicU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=ObliUR/E; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="ObliUR/E" Received: by smtp.kernel.org (Postfix) with ESMTPS id 2E19DC2BCC7; Wed, 14 Oct 2026 06:49:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux.dev; s=korg; t=1791960588; bh=zgzIKcPpPlhwn+/jD26bwEQDWYZk4cqXx3wE756XGPw=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=ObliUR/EFribJnHUAzTu9qvr/8lSkZNUDo9BlvIoQv0+CGK2NLcbwp0uj5dhI3K0s LHtres4xw6AXoWnD6Ski13KeSnxcK+MyEO9GHqWw8Iu3h2lMffN7Uag25HKabUsZBO I5Wc8ghuMSXEpGgrbHrcpTIkYi/YBWwCAEC3LaMo= Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0CD54CC6B24; Wed, 14 Oct 2026 06:49:48 +0000 (UTC) From: Richard Leitner Date: Wed, 14 Oct 2026 08:49:08 +0200 Subject: [PATCH v2 1/8] media: i2c: ov9282: handle error from exposure range update Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20261014-ov9282-fixes-v2-1-3bb376d8b1a9@linux.dev> References: <20261014-ov9282-fixes-v2-0-3bb376d8b1a9@linux.dev> In-Reply-To: <20261014-ov9282-fixes-v2-0-3bb376d8b1a9@linux.dev> To: Sakari Ailus , Dave Stevenson , Mauro Carvalho Chehab , Daniele Alessandrelli , "Paul J. Murphy" , Martina Krasteva , Richard Leitner , Hans Verkuil , Bryan O'Donoghue , Jacopo Mondi Cc: Mauro Carvalho Chehab , Gyula Kelemen , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org X-Mailer: b4 0.16.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1791960586; l=1053; i=richard.leitner@linux.dev; s=20250225; h=from:subject:message-id; bh=zgzIKcPpPlhwn+/jD26bwEQDWYZk4cqXx3wE756XGPw=; b=McsawXTKwPYKEZZ9iQYdUz3LTZT5hDS9NIGhgxUPF62Ln+fU+AuYx22pKn/FfCL2X4D93b2iP +1H2r/zhWeTC2EjRzKU6ml+MSwZ/DPpre31OWMdWxFgoTJXt7W6zOJO X-Developer-Key: i=richard.leitner@linux.dev; a=ed25519; pk=8hZNyyyQFqZ5ruVJsSGBSPIrmJpfDm5HwHU4QVOP1Pk= X-Endpoint-Received: by B4 Relay for richard.leitner@linux.dev/20250225 with auth_id=350 When setting V4L2_CID_VBLANK the V4L2 range for the exposure control is updated by v4l2_ctrl_modify_range(). This range update missed a return value check, which resulted in ov9282_set_ctrl() not returning on an error from that function call. Fix this by checking the return value and returning it on error. Reviewed-by: Dave Stevenson Fixes: 14ea315bbeb75 ("media: i2c: Add ov9282 camera sensor driver") Cc: stable@vger.kernel.org Signed-off-by: Richard Leitner --- drivers/media/i2c/ov9282.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/media/i2c/ov9282.c b/drivers/media/i2c/ov9282.c index 5d301660a87d8..c10b2e205834e 100644 --- a/drivers/media/i2c/ov9282.c +++ b/drivers/media/i2c/ov9282.c @@ -608,6 +608,8 @@ static int ov9282_set_ctrl(struct v4l2_ctrl *ctrl) ov9282->cur_mode->height - OV9282_EXPOSURE_OFFSET, 1, OV9282_EXPOSURE_DEFAULT); + if (ret) + return ret; break; } -- 2.53.0