Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1175614 > unrolled thread

Re: [PATCH v1 10/10] core: platform: use fwnode_driver_match_device()

Started by"Rafael J. Wysocki" <rjw@rjwysocki.net>
First post2015-07-02 01:30 +0200
Last post2015-07-02 01:30 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH v1 10/10] core: platform: use fwnode_driver_match_device() "Rafael J. Wysocki" <rjw@rjwysocki.net> - 2015-07-02 01:30 +0200

#1175614 — Re: [PATCH v1 10/10] core: platform: use fwnode_driver_match_device()

From"Rafael J. Wysocki" <rjw@rjwysocki.net>
Date2015-07-02 01:30 +0200
SubjectRe: [PATCH v1 10/10] core: platform: use fwnode_driver_match_device()
Message-ID<pHzC1-3jd-1@gated-at.bofh.it>
On Tuesday, June 30, 2015 04:55:08 PM Tomeu Vizoso wrote:
> Instead of calling both of_driver_match_device() and
> acpi_driver_match_device(), call fwnode_driver_match_device() which
> should be able to sort out what firmware describes the device in
> question.
> 
> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>

This one should be part of the other set IMO.

Or please just combine the two sets so it is more clear what the new helpers
are intended for.


> ---
> 
>  drivers/base/platform.c | 8 ++------
>  1 file changed, 2 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/base/platform.c b/drivers/base/platform.c
> index 063f0ab..a7e7757 100644
> --- a/drivers/base/platform.c
> +++ b/drivers/base/platform.c
> @@ -843,12 +843,8 @@ static int platform_match(struct device *dev, struct device_driver *drv)
>  	if (pdev->driver_override)
>  		return !strcmp(pdev->driver_override, drv->name);
>  
> -	/* Attempt an OF style match first */
> -	if (of_driver_match_device(dev, drv))
> -		return 1;
> -
> -	/* Then try ACPI style match */
> -	if (acpi_driver_match_device(dev, drv))
> +	/* Attempt a firmware match first */
> +	if (fwnode_driver_match_device(dev, drv))
>  		return 1;
>  
>  	/* Then try to match against the id table */
> 

-- 
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web