Linux Power Management development
 help / color / mirror / Atom feed
* [PATCH v2 1/2] driver core: Export device_link_flag_is_sync_state_only()
@ 2025-09-11 11:16 Pin-yen Lin
  2025-09-11 11:16 ` [PATCH v2 2/2] PM: sleep: Don't wait for SYNC_STATE_ONLY device links Pin-yen Lin
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Pin-yen Lin @ 2025-09-11 11:16 UTC (permalink / raw)
  To: Rafael J . Wysocki, Len Brown, Pavel Machek, Greg Kroah-Hartman,
	Danilo Krummrich, Saravana Kannan
  Cc: Hsin-Te Yuan, linux-pm, Chen-Yu Tsai, linux-kernel, Pin-yen Lin

Export device_link_flag_is_sync_state_only() for future patches.

Signed-off-by: Pin-yen Lin <treapking@chromium.org>

---

Changes in v2:
- New in v2

 drivers/base/core.c    | 3 ++-
 include/linux/device.h | 1 +
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/base/core.c b/drivers/base/core.c
index d22d6b23e758..cc6af9b0d59d 100644
--- a/drivers/base/core.c
+++ b/drivers/base/core.c
@@ -287,10 +287,11 @@ static bool device_is_ancestor(struct device *dev, struct device *target)
 #define DL_MARKER_FLAGS		(DL_FLAG_INFERRED | \
 				 DL_FLAG_CYCLE | \
 				 DL_FLAG_MANAGED)
-static inline bool device_link_flag_is_sync_state_only(u32 flags)
+bool device_link_flag_is_sync_state_only(u32 flags)
 {
 	return (flags & ~DL_MARKER_FLAGS) == DL_FLAG_SYNC_STATE_ONLY;
 }
+EXPORT_SYMBOL_GPL(device_link_flag_is_sync_state_only);
 
 /**
  * device_is_dependent - Check if one device depends on another one
diff --git a/include/linux/device.h b/include/linux/device.h
index 0470d19da7f2..e27d0bf7c43d 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -1197,6 +1197,7 @@ const char *dev_driver_string(const struct device *dev);
 struct device_link *device_link_add(struct device *consumer,
 				    struct device *supplier, u32 flags);
 void device_link_del(struct device_link *link);
+bool device_link_flag_is_sync_state_only(u32 flags);
 void device_link_remove(void *consumer, struct device *supplier);
 void device_links_supplier_sync_state_pause(void);
 void device_links_supplier_sync_state_resume(void);
-- 
2.51.0.384.g4c02a37b29-goog


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2025-09-11 12:50 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-11 11:16 [PATCH v2 1/2] driver core: Export device_link_flag_is_sync_state_only() Pin-yen Lin
2025-09-11 11:16 ` [PATCH v2 2/2] PM: sleep: Don't wait for SYNC_STATE_ONLY device links Pin-yen Lin
2025-09-11 12:28   ` Greg Kroah-Hartman
2025-09-11 12:49     ` Rafael J. Wysocki
2025-09-11 12:28 ` [PATCH v2 1/2] driver core: Export device_link_flag_is_sync_state_only() Greg Kroah-Hartman
2025-09-11 12:50 ` Rafael J. Wysocki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox