diff options
author | Heikki Krogerus <heikki.krogerus@linux.intel.com> | 2019-05-31 17:15:36 +0300 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2019-06-03 11:55:38 +0300 |
commit | b06184acf751fa52a3763e4fadfd2807e9703acd (patch) | |
tree | febf98d6e8ccf8af0899ee6f50d9e02ec13fdc57 /include/linux/property.h | |
parent | c959d0c231f7063b14d766cfecc1fe90c2ab5061 (diff) | |
download | linux-b06184acf751fa52a3763e4fadfd2807e9703acd.tar.xz |
software node: Add software_node_get_reference_args()
This makes it possible to support drivers that use
fwnode_property_get_reference_args() function.
Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Tested-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'include/linux/property.h')
-rw-r--r-- | include/linux/property.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/include/linux/property.h b/include/linux/property.h index a3813ded52ea..abcde2f236a0 100644 --- a/include/linux/property.h +++ b/include/linux/property.h @@ -332,16 +332,44 @@ int fwnode_graph_parse_endpoint(const struct fwnode_handle *fwnode, /* -------------------------------------------------------------------------- */ /* Software fwnode support - when HW description is incomplete or missing */ +struct software_node; + +/** + * struct software_node_ref_args - Reference with additional arguments + * @node: Reference to a software node + * @nargs: Number of elements in @args array + * @args: Integer arguments + */ +struct software_node_ref_args { + const struct software_node *node; + unsigned int nargs; + u64 args[NR_FWNODE_REFERENCE_ARGS]; +}; + +/** + * struct software_node_reference - Named software node reference property + * @name: Name of the property + * @nrefs: Number of elements in @refs array + * @refs: Array of references with optional arguments + */ +struct software_node_reference { + const char *name; + unsigned int nrefs; + const struct software_node_ref_args *refs; +}; + /** * struct software_node - Software node description * @name: Name of the software node * @parent: Parent of the software node * @properties: Array of device properties + * @references: Array of software node reference properties */ struct software_node { const char *name; const struct software_node *parent; const struct property_entry *properties; + const struct software_node_reference *references; }; bool is_software_node(const struct fwnode_handle *fwnode); |