* [PATCH] drm/drm-bridge.c: Drop conditionals around of_node pointers
@ 2024-05-07 18:00 Sui Jingfeng
2024-05-07 20:21 ` Laurent Pinchart
2024-05-10 8:04 ` Robert Foss
0 siblings, 2 replies; 3+ messages in thread
From: Sui Jingfeng @ 2024-05-07 18:00 UTC (permalink / raw
To: Andrzej Hajda
Cc: Neil Armstrong, Robert Foss, Laurent Pinchart, Jonas Karlman,
Jernej Skrabec, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, David Airlie, Daniel Vetter, dri-devel,
linux-kernel, Sui Jingfeng
Having conditional around the of_node pointer of the drm_bridge structure
is not necessary, since drm_bridge structure always has the of_node as its
member.
Let's drop the conditional to get a better looks, please also note that
this is following the already accepted commitments. see commit d8dfccde2709
("drm/bridge: Drop conditionals around of_node pointers") for reference.
Signed-off-by: Sui Jingfeng <sui.jingfeng@linux.dev>
---
drivers/gpu/drm/drm_bridge.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/gpu/drm/drm_bridge.c b/drivers/gpu/drm/drm_bridge.c
index 30d66bee0ec6..a6dbe1751e88 100644
--- a/drivers/gpu/drm/drm_bridge.c
+++ b/drivers/gpu/drm/drm_bridge.c
@@ -352,13 +352,8 @@ int drm_bridge_attach(struct drm_encoder *encoder, struct drm_bridge *bridge,
bridge->encoder = NULL;
list_del(&bridge->chain_node);
-#ifdef CONFIG_OF
DRM_ERROR("failed to attach bridge %pOF to encoder %s: %d\n",
bridge->of_node, encoder->name, ret);
-#else
- DRM_ERROR("failed to attach bridge to encoder %s: %d\n",
- encoder->name, ret);
-#endif
return ret;
}
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] drm/drm-bridge.c: Drop conditionals around of_node pointers
2024-05-07 18:00 [PATCH] drm/drm-bridge.c: Drop conditionals around of_node pointers Sui Jingfeng
@ 2024-05-07 20:21 ` Laurent Pinchart
2024-05-10 8:04 ` Robert Foss
1 sibling, 0 replies; 3+ messages in thread
From: Laurent Pinchart @ 2024-05-07 20:21 UTC (permalink / raw
To: Sui Jingfeng
Cc: Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
Jernej Skrabec, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, David Airlie, Daniel Vetter, dri-devel,
linux-kernel
On Wed, May 08, 2024 at 02:00:00AM +0800, Sui Jingfeng wrote:
> Having conditional around the of_node pointer of the drm_bridge structure
> is not necessary, since drm_bridge structure always has the of_node as its
> member.
>
> Let's drop the conditional to get a better looks, please also note that
> this is following the already accepted commitments. see commit d8dfccde2709
> ("drm/bridge: Drop conditionals around of_node pointers") for reference.
>
> Signed-off-by: Sui Jingfeng <sui.jingfeng@linux.dev>
It looks like this was forgotten in commit d8dfccde2709 ("drm/bridge:
Drop conditionals around of_node pointers").
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> ---
> drivers/gpu/drm/drm_bridge.c | 5 -----
> 1 file changed, 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_bridge.c b/drivers/gpu/drm/drm_bridge.c
> index 30d66bee0ec6..a6dbe1751e88 100644
> --- a/drivers/gpu/drm/drm_bridge.c
> +++ b/drivers/gpu/drm/drm_bridge.c
> @@ -352,13 +352,8 @@ int drm_bridge_attach(struct drm_encoder *encoder, struct drm_bridge *bridge,
> bridge->encoder = NULL;
> list_del(&bridge->chain_node);
>
> -#ifdef CONFIG_OF
> DRM_ERROR("failed to attach bridge %pOF to encoder %s: %d\n",
> bridge->of_node, encoder->name, ret);
> -#else
> - DRM_ERROR("failed to attach bridge to encoder %s: %d\n",
> - encoder->name, ret);
> -#endif
>
> return ret;
> }
--
Regards,
Laurent Pinchart
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] drm/drm-bridge.c: Drop conditionals around of_node pointers
2024-05-07 18:00 [PATCH] drm/drm-bridge.c: Drop conditionals around of_node pointers Sui Jingfeng
2024-05-07 20:21 ` Laurent Pinchart
@ 2024-05-10 8:04 ` Robert Foss
1 sibling, 0 replies; 3+ messages in thread
From: Robert Foss @ 2024-05-10 8:04 UTC (permalink / raw
To: Andrzej Hajda, Sui Jingfeng
Cc: Laurent Pinchart, Jonas Karlman, Neil Armstrong, David Airlie,
Maxime Ripard, Thomas Zimmermann, Daniel Vetter,
Maarten Lankhorst, Jernej Skrabec, linux-kernel, dri-devel
On Wed, 8 May 2024 02:00:00 +0800, Sui Jingfeng wrote:
> Having conditional around the of_node pointer of the drm_bridge structure
> is not necessary, since drm_bridge structure always has the of_node as its
> member.
>
> Let's drop the conditional to get a better looks, please also note that
> this is following the already accepted commitments. see commit d8dfccde2709
> ("drm/bridge: Drop conditionals around of_node pointers") for reference.
>
> [...]
Applied, thanks!
[1/1] drm/drm-bridge.c: Drop conditionals around of_node pointers
https://cgit.freedesktop.org/drm/drm-misc/commit/?id=ad3323a6ccb7
Rob
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-05-10 8:04 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-07 18:00 [PATCH] drm/drm-bridge.c: Drop conditionals around of_node pointers Sui Jingfeng
2024-05-07 20:21 ` Laurent Pinchart
2024-05-10 8:04 ` Robert Foss
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 read-only IMAP folder(s) and NNTP newsgroup(s).