diff options
author | Saravana Kannan <saravanak@google.com> | 2020-05-15 08:34:59 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-05-15 17:34:52 +0300 |
commit | 716a7a25969003d82ab738179c3f1068a120ed11 (patch) | |
tree | 797f2e264d46d265342ff14319fe5b496a223fd3 /include/linux/fwnode.h | |
parent | 5f5377eaddfc24e5d7562e588d0ff84f9264d7c1 (diff) | |
download | linux-716a7a25969003d82ab738179c3f1068a120ed11.tar.xz |
driver core: fw_devlink: Add support for batching fwnode parsing
The amount of time spent parsing fwnodes of devices can become really
high if the devices are added in an non-ideal order. Worst case can be
O(N^2) when N devices are added. But this can be optimized to O(N) by
adding all the devices and then parsing all their fwnodes in one batch.
This commit adds fw_devlink_pause() and fw_devlink_resume() to allow
doing this.
Signed-off-by: Saravana Kannan <saravanak@google.com>
Link: https://lore.kernel.org/r/20200515053500.215929-4-saravanak@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/fwnode.h')
-rw-r--r-- | include/linux/fwnode.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/fwnode.h b/include/linux/fwnode.h index e0abafbb17f8..9506f8ec0974 100644 --- a/include/linux/fwnode.h +++ b/include/linux/fwnode.h @@ -171,5 +171,7 @@ struct fwnode_operations { #define get_dev_from_fwnode(fwnode) get_device((fwnode)->dev) extern u32 fw_devlink_get_flags(void); +void fw_devlink_pause(void); +void fw_devlink_resume(void); #endif |