Re: [RFC 02/10] property: add fwnode_get_match_data()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Feb 21, 2022 at 05:26:44PM +0100, Clément Léger wrote:
> Add fwnode_get_match_data() which is meant to be used as
> device_get_match_data for fwnode_operations.

...

> +const void *fwnode_get_match_data(const struct fwnode_handle *fwnode,
> +				  const struct device *dev)
> +{
> +	const struct of_device_id *match;
> +
> +	match = fwnode_match_node(fwnode, dev->driver->of_match_table);
> +	if (!match)
> +		return NULL;
> +
> +	return match->data;
> +}

It's OF-centric API, why it has fwnode prefix? Can it leave in drivers/of instead?


-- 
With Best Regards,
Andy Shevchenko





[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux