aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/include/uhdlib/rfnoc/graph.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/include/uhdlib/rfnoc/graph.hpp')
-rw-r--r--host/lib/include/uhdlib/rfnoc/graph.hpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/host/lib/include/uhdlib/rfnoc/graph.hpp b/host/lib/include/uhdlib/rfnoc/graph.hpp
index 87977a1dc..5b735b624 100644
--- a/host/lib/include/uhdlib/rfnoc/graph.hpp
+++ b/host/lib/include/uhdlib/rfnoc/graph.hpp
@@ -7,14 +7,14 @@
#ifndef INCLUDED_LIBUHD_GRAPH_HPP
#define INCLUDED_LIBUHD_GRAPH_HPP
-#include <uhd/rfnoc/graph_edge.hpp>
#include <uhd/rfnoc/actions.hpp>
+#include <uhd/rfnoc/graph_edge.hpp>
#include <uhd/rfnoc/node.hpp>
#include <boost/graph/adjacency_list.hpp>
-#include <tuple>
-#include <memory>
#include <deque>
-#include <atomic>
+#include <memory>
+#include <mutex>
+#include <tuple>
namespace uhd { namespace rfnoc { namespace detail {
@@ -273,9 +273,12 @@ private:
// message is sent
std::recursive_mutex _action_mutex;
+ //! Changes to the release/commit state of the graph are locked with this mutex
+ std::recursive_mutex _release_mutex;
+
//! This counter gets decremented everytime commit() is called. When zero,
// the graph is committed.
- std::atomic<size_t> _release_count{1};
+ size_t _release_count{1};
};