From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: "Rob Herring (Arm)" <robh@kernel.org>
Cc: Phong LE <ple@baylibre.com>,
Neil Armstrong <neil.armstrong@linaro.org>,
Andrzej Hajda <andrzej.hajda@intel.com>,
Robert Foss <rfoss@kernel.org>, Jonas Karlman <jonas@kwiboo.se>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
Jessica Zhang <quic_jesszhan@quicinc.com>,
Rob Clark <robdclark@gmail.com>,
Abhinav Kumar <quic_abhinavk@quicinc.com>,
Dmitry Baryshkov <dmitry.baryshkov@linaro.org>,
Sean Paul <sean@poorly.run>,
Marijn Suijten <marijn.suijten@somainline.org>,
dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
linux-arm-msm@vger.kernel.org, freedreno@lists.freedesktop.org
Subject: Re: [PATCH] drm: Use of_property_present() for non-boolean properties
Date: Mon, 4 Nov 2024 22:48:14 +0200 [thread overview]
Message-ID: <20241104204814.GC27775@pendragon.ideasonboard.com> (raw)
In-Reply-To: <20241104190636.274926-1-robh@kernel.org>
Hi Rob,
Thank you for the patch.
On Mon, Nov 04, 2024 at 01:06:35PM -0600, Rob Herring (Arm) wrote:
> The use of of_property_read_bool() for non-boolean properties is
> deprecated in favor of of_property_present() when testing for property
> presence.
>
> Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---
> drivers/gpu/drm/bridge/ite-it66121.c | 2 +-
> drivers/gpu/drm/bridge/sii902x.c | 2 +-
> drivers/gpu/drm/drm_panel.c | 2 +-
> drivers/gpu/drm/msm/dsi/dsi_host.c | 2 +-
> 4 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/ite-it66121.c b/drivers/gpu/drm/bridge/ite-it66121.c
> index 925e42f46cd8..0eae7c01b975 100644
> --- a/drivers/gpu/drm/bridge/ite-it66121.c
> +++ b/drivers/gpu/drm/bridge/ite-it66121.c
> @@ -1480,7 +1480,7 @@ static int it66121_audio_codec_init(struct it66121_ctx *ctx, struct device *dev)
>
> dev_dbg(dev, "%s\n", __func__);
>
> - if (!of_property_read_bool(dev->of_node, "#sound-dai-cells")) {
> + if (!of_property_present(dev->of_node, "#sound-dai-cells")) {
> dev_info(dev, "No \"#sound-dai-cells\", no audio\n");
> return 0;
> }
> diff --git a/drivers/gpu/drm/bridge/sii902x.c b/drivers/gpu/drm/bridge/sii902x.c
> index 7f91b0db161e..f73e1174a5ad 100644
> --- a/drivers/gpu/drm/bridge/sii902x.c
> +++ b/drivers/gpu/drm/bridge/sii902x.c
> @@ -850,7 +850,7 @@ static int sii902x_audio_codec_init(struct sii902x *sii902x,
> u8 lanes[4];
> int num_lanes, i;
>
> - if (!of_property_read_bool(dev->of_node, "#sound-dai-cells")) {
> + if (!of_property_present(dev->of_node, "#sound-dai-cells")) {
> dev_dbg(dev, "%s: No \"#sound-dai-cells\", no audio\n",
> __func__);
> return 0;
> diff --git a/drivers/gpu/drm/drm_panel.c b/drivers/gpu/drm/drm_panel.c
> index 19ab0a794add..46d61cc871ca 100644
> --- a/drivers/gpu/drm/drm_panel.c
> +++ b/drivers/gpu/drm/drm_panel.c
> @@ -413,7 +413,7 @@ bool drm_is_panel_follower(struct device *dev)
> * don't bother trying to parse it here. We just need to know if the
> * property is there.
> */
> - return of_property_read_bool(dev->of_node, "panel");
> + return of_property_present(dev->of_node, "panel");
> }
> EXPORT_SYMBOL(drm_is_panel_follower);
>
> diff --git a/drivers/gpu/drm/msm/dsi/dsi_host.c b/drivers/gpu/drm/msm/dsi/dsi_host.c
> index 185d7de0bf37..78cac4ecc58f 100644
> --- a/drivers/gpu/drm/msm/dsi/dsi_host.c
> +++ b/drivers/gpu/drm/msm/dsi/dsi_host.c
> @@ -1831,7 +1831,7 @@ static int dsi_host_parse_dt(struct msm_dsi_host *msm_host)
> msm_dsi->te_source = devm_kstrdup(dev, te_source, GFP_KERNEL);
> ret = 0;
>
> - if (of_property_read_bool(np, "syscon-sfpb")) {
> + if (of_property_present(np, "syscon-sfpb")) {
> msm_host->sfpb = syscon_regmap_lookup_by_phandle(np,
> "syscon-sfpb");
> if (IS_ERR(msm_host->sfpb)) {
--
Regards,
Laurent Pinchart
next prev parent reply other threads:[~2024-11-04 20:48 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-04 19:06 Rob Herring (Arm)
2024-11-04 19:14 ` Abhinav Kumar
2024-11-04 20:48 ` Laurent Pinchart [this message]
2024-11-05 6:33 ` Dragan Simic
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=20241104204814.GC27775@pendragon.ideasonboard.com \
--to=laurent.pinchart@ideasonboard.com \
--cc=airlied@gmail.com \
--cc=andrzej.hajda@intel.com \
--cc=dmitry.baryshkov@linaro.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=freedreno@lists.freedesktop.org \
--cc=jernej.skrabec@gmail.com \
--cc=jonas@kwiboo.se \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=marijn.suijten@somainline.org \
--cc=mripard@kernel.org \
--cc=neil.armstrong@linaro.org \
--cc=ple@baylibre.com \
--cc=quic_abhinavk@quicinc.com \
--cc=quic_jesszhan@quicinc.com \
--cc=rfoss@kernel.org \
--cc=robdclark@gmail.com \
--cc=robh@kernel.org \
--cc=sean@poorly.run \
--cc=simona@ffwll.ch \
--cc=tzimmermann@suse.de \
/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®