Commit eec4954b authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

driver core: make device_is_dependent() static

The function device_is_dependent() is only called by the driver core
internally and should not, at this time, be called by anyone else
outside of it, so mark it as static so as not to give driver authors the
wrong idea.

Cc: Saravana Kannan <saravanak@google.com>
Acked-by: default avatar"Rafael J. Wysocki" <rafael@kernel.org>
Link: https://lore.kernel.org/r/2023112815-faculty-thud-add8@gregkhSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 2cc14f52
...@@ -298,7 +298,7 @@ static inline bool device_link_flag_is_sync_state_only(u32 flags) ...@@ -298,7 +298,7 @@ static inline bool device_link_flag_is_sync_state_only(u32 flags)
* Check if @target depends on @dev or any device dependent on it (its child or * Check if @target depends on @dev or any device dependent on it (its child or
* its consumer etc). Return 1 if that is the case or 0 otherwise. * its consumer etc). Return 1 if that is the case or 0 otherwise.
*/ */
int device_is_dependent(struct device *dev, void *target) static int device_is_dependent(struct device *dev, void *target)
{ {
struct device_link *link; struct device_link *link;
int ret; int ret;
......
...@@ -1071,7 +1071,6 @@ int device_rename(struct device *dev, const char *new_name); ...@@ -1071,7 +1071,6 @@ int device_rename(struct device *dev, const char *new_name);
int device_move(struct device *dev, struct device *new_parent, int device_move(struct device *dev, struct device *new_parent,
enum dpm_order dpm_order); enum dpm_order dpm_order);
int device_change_owner(struct device *dev, kuid_t kuid, kgid_t kgid); int device_change_owner(struct device *dev, kuid_t kuid, kgid_t kgid);
int device_is_dependent(struct device *dev, void *target);
static inline bool device_supports_offline(struct device *dev) static inline bool device_supports_offline(struct device *dev)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment