Introduce general-purpose ways to wait for dpif and netdev changes.
[openvswitch] / lib / rconn.c
index deb95195deac5ffd93225716ca3f3a6d1974fa27..b18a2e59e918c3d4373b3a4e19a0bcf55b6e6af6 100644 (file)
@@ -698,6 +698,15 @@ rconn_get_last_connection(const struct rconn *rc)
     return rc->last_connected;
 }
 
+/* Returns the time at which the last OpenFlow message was received by 'rc'.
+ * If no packets have been received on 'rc', returns the time at which 'rc'
+ * was created. */
+time_t
+rconn_get_last_received(const struct rconn *rc)
+{
+    return rc->last_received;
+}
+
 /* Returns the time at which 'rc' was created. */
 time_t
 rconn_get_creation_time(const struct rconn *rc)