From: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
To: Richard Acayan <mailingradian@gmail.com>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Bjorn Andersson <andersson@kernel.org>,
Konrad Dybcio <konradybcio@kernel.org>,
Sakari Ailus <sakari.ailus@linux.intel.com>,
Tianshu Qiu <tian.shu.qiu@intel.com>,
linux-media@vger.kernel.org, devicetree@vger.kernel.org,
linux-arm-msm@vger.kernel.org
Subject: Re: [PATCH 3/5] media: i2c: imx355: Add power management for managed resources
Date: Tue, 1 Jul 2025 13:48:14 +0100 [thread overview]
Message-ID: <d3c56e1c-69fa-4bf0-8257-aa18ff7d33cd@linaro.org> (raw)
In-Reply-To: <20250630225944.320755-10-mailingradian@gmail.com>
On 30/06/2025 23:59, Richard Acayan wrote:
> +static int imx355_resume(struct device *dev)
> +{
> + struct i2c_client *client = container_of(dev, struct i2c_client, dev);
> + struct v4l2_subdev *sd = i2c_get_clientdata(client);
> + struct imx355 *imx355 = to_imx355(sd);
> + int ret;
> +
> + ret = regulator_bulk_enable(ARRAY_SIZE(imx355->supplies),
> + imx355->supplies);
> + if (ret) {
> + dev_err(dev, "failed to enable regulators: %d\n", ret);
> + return ret;
> + }
> +
> + gpiod_set_value_cansleep(imx355->reset_gpio, 1);
> +
> + clk_prepare_enable(imx355->mclk);
> + usleep_range(12000, 13000);
> +
> + return 0;
> +}
I'd say this sequence is out of spec w/r/t your sensor.
Almost certainly should be
- clock
- rails
- reset lines
The reset sequence should be
- Assert reset
- Wait for some amount of time. Either you get this from the spec
or you borrow a value from a similar driver...
Suggest again what we've done for ov02c10 and ov02e10
- De-assert reset
Then use these power_on/power_off sequences in your probe discovery,
since they will already have error jump labels to do your tidy up.
---
bod
next prev parent reply other threads:[~2025-07-01 12:48 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-30 22:59 [PATCH 0/5] media: i2c: IMX355 for the Pixel 3a Richard Acayan
2025-06-30 22:59 ` [PATCH 1/5] dt-bindings: media: i2c: Add Sony IMX355 Richard Acayan
2025-07-01 13:06 ` Krzysztof Kozlowski
2025-06-30 22:59 ` [PATCH 2/5] media: i2c: imx355: Support device tree probing and resource management Richard Acayan
2025-07-01 12:43 ` Bryan O'Donoghue
2025-07-01 13:08 ` Krzysztof Kozlowski
2025-06-30 22:59 ` [PATCH 3/5] media: i2c: imx355: Add power management for managed resources Richard Acayan
2025-07-01 12:48 ` Bryan O'Donoghue [this message]
2025-06-30 22:59 ` [PATCH 4/5] arm64: dts: qcom: sdm670-google-sargo: add imx355 front camera Richard Acayan
2025-07-01 10:52 ` Konrad Dybcio
2025-07-01 12:23 ` Bryan O'Donoghue
2025-07-01 23:15 ` Richard Acayan
2025-07-02 0:48 ` Bryan O'Donoghue
2025-07-01 13:10 ` Krzysztof Kozlowski
2025-06-30 22:59 ` [PATCH 5/5] arm64: dts: qcom: sdm670-google-sargo: Add front camera rotation/orientation Richard Acayan
2025-07-01 10:53 ` Konrad Dybcio
2025-07-01 13:11 ` Krzysztof Kozlowski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d3c56e1c-69fa-4bf0-8257-aa18ff7d33cd@linaro.org \
--to=bryan.odonoghue@linaro.org \
--cc=andersson@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=konradybcio@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mailingradian@gmail.com \
--cc=mchehab@kernel.org \
--cc=robh@kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=tian.shu.qiu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).