device property: Implement fwnode_graph_get_endpoint_count()
authorSakari Ailus <sakari.ailus@linux.intel.com>
Wed, 1 Dec 2021 12:59:33 +0000 (14:59 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 17 Dec 2021 17:41:29 +0000 (18:41 +0100)
commitc87b8fc569667610b4891cad1e4a663e5a94d8f8
tree990e02b4cb0640f4e6deed740025f5906c403e83
parent59f3f98284baa29da60410d04e498467c044aac2
device property: Implement fwnode_graph_get_endpoint_count()

Add fwnode_graph_get_endpoint_count() function to provide generic
implementation of of_graph_get_endpoint_count(). The former by default
only counts endpoints to available devices which is consistent with the
rest of the fwnode graph API. By providing FWNODE_GRAPH_DEVICE_DISABLED
flag, also unconnected endpoints and endpoints to disabled devices are
counted.

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/base/property.c
include/linux/property.h