]> git.karo-electronics.de Git - linux-beck.git/blobdiff - include/net/dsa.h
net: dsa: Export suspend/resume functions
[linux-beck.git] / include / net / dsa.h
index 2217a3f817f8e5072954941d34d089be28b1e136..d00c392bc9f880adfb5f9b281ea80de79cb0beb8 100644 (file)
@@ -386,4 +386,18 @@ static inline bool dsa_uses_tagged_protocol(struct dsa_switch_tree *dst)
 
 void dsa_unregister_switch(struct dsa_switch *ds);
 int dsa_register_switch(struct dsa_switch *ds, struct device_node *np);
+#ifdef CONFIG_PM_SLEEP
+int dsa_switch_suspend(struct dsa_switch *ds);
+int dsa_switch_resume(struct dsa_switch *ds);
+#else
+static inline int dsa_switch_suspend(struct dsa_switch *ds)
+{
+       return 0;
+}
+static inline int dsa_switch_resume(struct dsa_switch *ds)
+{
+       return 0;
+}
+#endif /* CONFIG_PM_SLEEP */
+
 #endif