* [PATCH] drm/msm/dp: switch to devm_drm_of_get_bridge
@ 2022-02-21 7:33 José Expósito
2022-02-21 8:55 ` Maxime Ripard
2022-02-22 21:07 ` Stephen Boyd
0 siblings, 2 replies; 4+ messages in thread
From: José Expósito @ 2022-02-21 7:33 UTC (permalink / raw)
To: robdclark
Cc: sean, airlied, daniel, swboyd, bjorn.andersson, dmitry.baryshkov,
maxime, linux-arm-msm, dri-devel, freedreno, linux-kernel,
José Expósito
The function "drm_of_find_panel_or_bridge" has been deprecated in
favor of "devm_drm_of_get_bridge".
Switch to the new function and reduce boilerplate.
Signed-off-by: José Expósito <jose.exposito89@gmail.com>
---
drivers/gpu/drm/msm/dp/dp_parser.c | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/drivers/gpu/drm/msm/dp/dp_parser.c b/drivers/gpu/drm/msm/dp/dp_parser.c
index a7acc23f742b..0951752e2d98 100644
--- a/drivers/gpu/drm/msm/dp/dp_parser.c
+++ b/drivers/gpu/drm/msm/dp/dp_parser.c
@@ -268,16 +268,8 @@ static int dp_parser_clock(struct dp_parser *parser)
static int dp_parser_find_panel(struct dp_parser *parser)
{
struct device *dev = &parser->pdev->dev;
- struct drm_panel *panel;
- int rc;
- rc = drm_of_find_panel_or_bridge(dev->of_node, 1, 0, &panel, NULL);
- if (rc) {
- DRM_ERROR("failed to acquire DRM panel: %d\n", rc);
- return rc;
- }
-
- parser->panel_bridge = devm_drm_panel_bridge_add(dev, panel);
+ parser->panel_bridge = devm_drm_of_get_bridge(dev, dev->of_node, 1, 0);
if (IS_ERR(parser->panel_bridge)) {
DRM_ERROR("failed to create panel bridge\n");
return PTR_ERR(parser->panel_bridge);
--
2.25.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] drm/msm/dp: switch to devm_drm_of_get_bridge
2022-02-21 7:33 [PATCH] drm/msm/dp: switch to devm_drm_of_get_bridge José Expósito
@ 2022-02-21 8:55 ` Maxime Ripard
2022-02-22 21:07 ` Stephen Boyd
1 sibling, 0 replies; 4+ messages in thread
From: Maxime Ripard @ 2022-02-21 8:55 UTC (permalink / raw)
To: José Expósito
Cc: robdclark, sean, airlied, daniel, swboyd, bjorn.andersson,
dmitry.baryshkov, linux-arm-msm, dri-devel, freedreno,
linux-kernel
[-- Attachment #1: Type: text/plain, Size: 353 bytes --]
On Mon, Feb 21, 2022 at 08:33:39AM +0100, José Expósito wrote:
> The function "drm_of_find_panel_or_bridge" has been deprecated in
> favor of "devm_drm_of_get_bridge".
>
> Switch to the new function and reduce boilerplate.
>
> Signed-off-by: José Expósito <jose.exposito89@gmail.com>
Reviewed-by: Maxime Ripard <maxime@cerno.tech>
Maxime
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drm/msm/dp: switch to devm_drm_of_get_bridge
2022-02-21 7:33 [PATCH] drm/msm/dp: switch to devm_drm_of_get_bridge José Expósito
2022-02-21 8:55 ` Maxime Ripard
@ 2022-02-22 21:07 ` Stephen Boyd
2022-02-28 18:01 ` José Expósito
1 sibling, 1 reply; 4+ messages in thread
From: Stephen Boyd @ 2022-02-22 21:07 UTC (permalink / raw)
To: José Expósito, robdclark
Cc: sean, airlied, daniel, bjorn.andersson, dmitry.baryshkov, maxime,
linux-arm-msm, dri-devel, freedreno, linux-kernel
Quoting José Expósito (2022-02-20 23:33:39)
> The function "drm_of_find_panel_or_bridge" has been deprecated in
> favor of "devm_drm_of_get_bridge".
>
> Switch to the new function and reduce boilerplate.
>
> Signed-off-by: José Expósito <jose.exposito89@gmail.com>
> ---
Dmitry is rewriting this code in a larger series. This patch is
superseded by that work.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drm/msm/dp: switch to devm_drm_of_get_bridge
2022-02-22 21:07 ` Stephen Boyd
@ 2022-02-28 18:01 ` José Expósito
0 siblings, 0 replies; 4+ messages in thread
From: José Expósito @ 2022-02-28 18:01 UTC (permalink / raw)
To: Stephen Boyd
Cc: robdclark, sean, airlied, daniel, bjorn.andersson,
dmitry.baryshkov, maxime, linux-arm-msm, dri-devel, freedreno,
linux-kernel
On Tue, Feb 22, 2022 at 09:07:49PM +0000, Stephen Boyd wrote:
> Quoting José Expósito (2022-02-20 23:33:39)
> > The function "drm_of_find_panel_or_bridge" has been deprecated in
> > favor of "devm_drm_of_get_bridge".
> >
> > Switch to the new function and reduce boilerplate.
> >
> > Signed-off-by: José Expósito <jose.exposito89@gmail.com>
> > ---
>
> Dmitry is rewriting this code in a larger series. This patch is
> superseded by that work.
Thanks for the heads up Stephen, it is indeed superseded by [0].
And thanks for the review Maxime.
[0] https://lore.kernel.org/dri-devel/20220211224006.1797846-3-dmitry.baryshkov@linaro.org/
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2022-02-28 18:22 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-02-21 7:33 [PATCH] drm/msm/dp: switch to devm_drm_of_get_bridge José Expósito
2022-02-21 8:55 ` Maxime Ripard
2022-02-22 21:07 ` Stephen Boyd
2022-02-28 18:01 ` José Expósito
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox