Commit 2eee9581 authored by Hans de Goede's avatar Hans de Goede Committed by Mauro Carvalho Chehab
Browse files

media: atomisp: Add atomisp_s_sensor_power() helper



Since the atomisp driver only supports 1 stream / only has 1 asd now,
there is no longer a need to track which stream owns the sensor.

So the asd owner-pointer of struct atomisp_input_subdev can be dropped,
replace this with a simple camera_on boolean and add a new
atomisp_s_sensor_power() helper which takes care of avoiding unbalanced
s_power() subdev calls as well as takes care of handling the special
-ENOIOCTLCMD return for subdevs which don't implement s_power().

Reviewed-by: default avatarAndy Shevchenko <andy@kernel.org>
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@kernel.org>
parent c7064fb6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment