From: vincent.abriou@st.com (Vincent ABRIOU)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 2/3] drm: convert DT component matching to component_match_add_release()
Date: Tue, 7 Jun 2016 16:26:13 +0200 [thread overview]
Message-ID: <5756D985.80107@st.com> (raw)
In-Reply-To: <E1b8pyX-0005OP-2s@rmk-PC.armlinux.org.uk>
On 06/03/2016 04:21 PM, Russell King wrote:
> Convert DT component matching to use component_match_add_release().
>
> Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
> ---
> drivers/gpu/drm/arm/hdlcd_drv.c | 9 +++------
> drivers/gpu/drm/armada/armada_drv.c | 8 ++------
> drivers/gpu/drm/drm_of.c | 6 ++++--
> drivers/gpu/drm/etnaviv/etnaviv_drv.c | 11 ++---------
> drivers/gpu/drm/msm/msm_drv.c | 8 ++------
> drivers/gpu/drm/msm/msm_drv.h | 1 +
> drivers/gpu/drm/rockchip/rockchip_drm_drv.c | 12 +++---------
> drivers/gpu/drm/sti/sti_drv.c | 9 ++-------
> drivers/gpu/drm/tilcdc/tilcdc_external.c | 8 ++------
> 9 files changed, 21 insertions(+), 51 deletions(-)
>
>
> diff --git a/drivers/gpu/drm/sti/sti_drv.c b/drivers/gpu/drm/sti/sti_drv.c
> index 872495e72294..aeb2787c9bd4 100644
> --- a/drivers/gpu/drm/sti/sti_drv.c
> +++ b/drivers/gpu/drm/sti/sti_drv.c
> @@ -10,6 +10,7 @@
> #include <linux/debugfs.h>
> #include <linux/kernel.h>
> #include <linux/module.h>
> +#include <linux/of_component.h>
> #include <linux/of_platform.h>
>
> #include <drm/drm_atomic.h>
> @@ -341,11 +342,6 @@ static struct drm_driver sti_driver = {
> .minor = DRIVER_MINOR,
> };
>
> -static int compare_of(struct device *dev, void *data)
> -{
> - return dev->of_node == data;
> -}
> -
> static int sti_bind(struct device *dev)
> {
> return drm_platform_init(&sti_driver, to_platform_device(dev));
> @@ -375,8 +371,7 @@ static int sti_platform_probe(struct platform_device *pdev)
> child_np = of_get_next_available_child(node, NULL);
>
> while (child_np) {
> - component_match_add(dev, &match, compare_of, child_np);
> - of_node_put(child_np);
> + component_match_add_of(dev, &match, child_np);
> child_np = of_get_next_available_child(node, child_np);
> }
>
Hi Russel,
Ok for the sti driver.
Acked-by: Vincent Abriou <vincent.abriou@st.com>
next prev parent reply other threads:[~2016-06-07 14:26 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-03 7:58 [PATCH] drm: convert DT component matching to component_match_add_release() Russell King
2016-06-03 9:40 ` Liviu Dudau
2016-06-03 10:36 ` Russell King - ARM Linux
2016-06-03 11:19 ` Liviu Dudau
2016-06-03 11:48 ` Russell King - ARM Linux
2016-06-03 10:56 ` Robin Murphy
2016-06-03 14:15 ` Russell King - ARM Linux
2016-06-03 14:21 ` [PATCH v2 1/3] of: add common OF-based component functionality Russell King
2016-06-03 15:29 ` Rob Herring
2016-06-03 15:36 ` Russell King - ARM Linux
2016-06-03 19:52 ` Rob Herring
2016-06-03 15:44 ` Thierry Reding
2016-06-03 16:11 ` Russell King - ARM Linux
2016-06-03 14:21 ` [PATCH v2 2/3] drm: convert DT component matching to component_match_add_release() Russell King
2016-06-03 15:10 ` Lucas Stach
2016-06-07 13:39 ` Liviu Dudau
2016-06-07 14:26 ` Vincent ABRIOU [this message]
2016-06-03 14:21 ` [PATCH v2 3/3] iommu: " Russell King
2016-06-03 15:20 ` Matthias Brugger
2016-06-15 13:31 ` Joerg Roedel
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=5756D985.80107@st.com \
--to=vincent.abriou@st.com \
--cc=linux-arm-kernel@lists.infradead.org \
/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;
as well as URLs for NNTP newsgroup(s).