From: Daniel Scally <djrscally@gmail.com>
To: "Dan Carpenter" <dan.carpenter@oracle.com>,
"Yong Zhi" <yong.zhi@intel.com>, "Fabian Wüthrich" <me@fabwu.ch>
Cc: Sakari Ailus <sakari.ailus@linux.intel.com>,
Bingbu Cao <bingbu.cao@intel.com>,
Tianshu Qiu <tian.shu.qiu@intel.com>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Andy Shevchenko <andy.shevchenko@gmail.com>,
linux-media@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] media: ipu3-cio2: fix error code in cio2_bridge_connect_sensor()
Date: Wed, 13 Oct 2021 23:41:18 +0100 [thread overview]
Message-ID: <e3880fc8-6189-ccca-e50b-d1bca27633dc@gmail.com> (raw)
In-Reply-To: <20211013075319.GA6010@kili>
Hi Dan
On 13/10/2021 08:53, Dan Carpenter wrote:
> Return -ENODEV if acpi_get_physical_device_location() fails. Don't
> return success.
>
> Fixes: 485aa3df0dff ("media: ipu3-cio2: Parse sensor orientation and rotation")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Thanks for catching that.
Reviewed-by: Daniel Scally <djrscally@gmail.com>
> ---
> drivers/media/pci/intel/ipu3/cio2-bridge.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/media/pci/intel/ipu3/cio2-bridge.c b/drivers/media/pci/intel/ipu3/cio2-bridge.c
> index 67c467d3c81f..0b586b4e537e 100644
> --- a/drivers/media/pci/intel/ipu3/cio2-bridge.c
> +++ b/drivers/media/pci/intel/ipu3/cio2-bridge.c
> @@ -238,8 +238,10 @@ static int cio2_bridge_connect_sensor(const struct cio2_sensor_config *cfg,
> goto err_put_adev;
>
> status = acpi_get_physical_device_location(adev->handle, &sensor->pld);
> - if (ACPI_FAILURE(status))
> + if (ACPI_FAILURE(status)) {
> + ret = -ENODEV;
> goto err_put_adev;
> + }
>
> if (sensor->ssdb.lanes > CIO2_MAX_LANES) {
> dev_err(&adev->dev,
next prev parent reply other threads:[~2021-10-13 22:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-13 7:53 [PATCH] media: ipu3-cio2: fix error code in cio2_bridge_connect_sensor() Dan Carpenter
2021-10-13 22:41 ` Daniel Scally [this message]
2021-10-14 11:45 ` Kieran Bingham
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=e3880fc8-6189-ccca-e50b-d1bca27633dc@gmail.com \
--to=djrscally@gmail.com \
--cc=andy.shevchenko@gmail.com \
--cc=bingbu.cao@intel.com \
--cc=dan.carpenter@oracle.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=me@fabwu.ch \
--cc=sakari.ailus@linux.intel.com \
--cc=tian.shu.qiu@intel.com \
--cc=yong.zhi@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