aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/property.h
diff options
context:
space:
mode:
authorHeikki Krogerus <heikki.krogerus@linux.intel.com>2016-03-29 07:52:23 -0400
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2016-04-08 21:10:50 -0400
commitf4d05266032346531b9f889e26aa31a0cf2a9822 (patch)
tree505a1b118968395ab85a39f37ae0e6c0a4d6c342 /include/linux/property.h
parent9735a22799b9214d17d3c231fe377fc852f042e9 (diff)
device property: don't bother the drivers with struct property_set
Since device_add_property_set() now always takes a copy of the property_set, and also since the fwnode type is always hard coded to be FWNODE_PDATA, there is no need for the drivers to deliver the entire struct property_set. The function can just create the instance of it on its own and bind the properties from the drivers to it on the spot. This renames device_add_property_set() to device_add_properties(). The function now takes struct property_entry as its parameter instead of struct property_set. Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Acked-by: Thierry Reding <treding@nvidia.com> Acked-by: Lee Jones <lee.jones@linaro.org> Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.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.h15
1 files changed, 3 insertions, 12 deletions
diff --git a/include/linux/property.h b/include/linux/property.h
index b51fcd36d892..ecab11e40794 100644
--- a/include/linux/property.h
+++ b/include/linux/property.h
@@ -238,18 +238,9 @@ struct property_entry {
238 .name = _name_, \ 238 .name = _name_, \
239} 239}
240 240
241/** 241int device_add_properties(struct device *dev,
242 * struct property_set - Collection of "built-in" device properties. 242 struct property_entry *properties);
243 * @fwnode: Handle to be pointed to by the fwnode field of struct device. 243void device_remove_properties(struct device *dev);
244 * @properties: Array of properties terminated with a null entry.
245 */
246struct property_set {
247 struct fwnode_handle fwnode;
248 struct property_entry *properties;
249};
250
251int device_add_property_set(struct device *dev, const struct property_set *pset);
252void device_remove_property_set(struct device *dev);
253 244
254bool device_dma_supported(struct device *dev); 245bool device_dma_supported(struct device *dev);
255 246