From: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
To: Johan Hovold <johan@kernel.org>,
Vikash Garodia <vikash.garodia@oss.qualcomm.com>,
Dikshita Agarwal <dikshita.agarwal@oss.qualcomm.com>
Cc: Mauro Carvalho Chehab <mchehab@kernel.org>,
linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] media: venus: drop bogus probe deferrals
Date: Fri, 17 Oct 2025 12:40:00 +0100 [thread overview]
Message-ID: <ecf63295-e92d-426e-933f-4efbc667b9af@linaro.org> (raw)
In-Reply-To: <20251017055809.8037-1-johan@kernel.org>
On 17/10/2025 06:58, Johan Hovold wrote:
> The encoder and decoder platform devices are registered by the venus
> driver as children of the venus device, but even if someone were to mess
> this up no amount of probe deferring is going to conjure up a parent.
>
> Relatedly, the venus driver sets its driver data before registering the
> child devices and if this ever breaks we want to learn about it by
> failing probe.
>
> Signed-off-by: Johan Hovold <johan@kernel.org>
> ---
> drivers/media/platform/qcom/venus/vdec.c | 5 +----
> drivers/media/platform/qcom/venus/venc.c | 5 +----
> 2 files changed, 2 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/media/platform/qcom/venus/vdec.c b/drivers/media/platform/qcom/venus/vdec.c
> index 55c27345b7d8..2d822ad86dce 100644
> --- a/drivers/media/platform/qcom/venus/vdec.c
> +++ b/drivers/media/platform/qcom/venus/vdec.c
> @@ -1778,12 +1778,9 @@ static int vdec_probe(struct platform_device *pdev)
> struct venus_core *core;
> int ret;
>
> - if (!dev->parent)
> - return -EPROBE_DEFER;
> -
> core = dev_get_drvdata(dev->parent);
> if (!core)
> - return -EPROBE_DEFER;
> + return -EINVAL;
>
> platform_set_drvdata(pdev, core);
>
> diff --git a/drivers/media/platform/qcom/venus/venc.c b/drivers/media/platform/qcom/venus/venc.c
> index fba07557a399..f1abd2bdce6b 100644
> --- a/drivers/media/platform/qcom/venus/venc.c
> +++ b/drivers/media/platform/qcom/venus/venc.c
> @@ -1560,12 +1560,9 @@ static int venc_probe(struct platform_device *pdev)
> struct venus_core *core;
> int ret;
>
> - if (!dev->parent)
> - return -EPROBE_DEFER;
> -
> core = dev_get_drvdata(dev->parent);
> if (!core)
> - return -EPROBE_DEFER;
> + return -EINVAL;
>
> platform_set_drvdata(pdev, core);
>
> --
> 2.49.1
>
Reviewed-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
next prev parent reply other threads:[~2025-10-17 11:40 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <iRhdXfjORNkpF-OnZ5iafGKrZq5VC_n5X3M_wEBMSzbXpgAoQxgdKIfdAWbBt_oC7p_b1pa226Awh5cp-kR95w==@protonmail.internalid>
2025-10-17 5:58 ` Johan Hovold
2025-10-17 11:40 ` Bryan O'Donoghue [this message]
2025-10-28 10:43 ` Dikshita Agarwal
2025-10-28 12:36 ` Vikash Garodia
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=ecf63295-e92d-426e-933f-4efbc667b9af@linaro.org \
--to=bryan.odonoghue@linaro.org \
--cc=dikshita.agarwal@oss.qualcomm.com \
--cc=johan@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=vikash.garodia@oss.qualcomm.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
all inboxes | Powered by JetHome®