media: dw9807-vcm: Add regulator support to the driver 28/293328/1
authorDave Stevenson <dave.stevenson@raspberrypi.com>
Tue, 3 Jan 2023 16:35:59 +0000 (16:35 +0000)
committerSeung-Woo Kim <sw0312.kim@samsung.com>
Mon, 22 May 2023 08:02:22 +0000 (17:02 +0900)
commit90d24e832ed8c322660a8349b91148cd0bbe69f4
tree1d4078b845765de80a3ba5741667f819a58a4296
parent855879ae1726a016419b677257fc212ffbfb37b2
media: dw9807-vcm: Add regulator support to the driver

Uses the regulator notifier framework so that the current
focus position will be restored whenever any user of the
regulator powers it up. This means that should the VCM
and sensor share a common regulator then starting the sensor
will automatically restore the default position. If they
have independent regulators then it will behave be powered
up when the VCM subdev is opened.

Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
[sw0312.kim: cherry-pick raspberry pi kernel upstream to support rpi camera module v3]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I599694491e29003dc633e8e6678f7ffc52342eef
drivers/media/i2c/dw9807-vcm.c