summaryrefslogtreecommitdiff
path: root/lib/block.cpp
diff options
context:
space:
mode:
authorJosh Blum2012-11-05 22:59:47 -0800
committerJosh Blum2012-11-05 22:59:47 -0800
commit37a863991f5e05035cce6738379de7a8ebc2b160 (patch)
treec7f2c7732074d69f1b3fe147f5fb32d92c34c9c8 /lib/block.cpp
parented68f79a7a2e3c1bdbe0a2b4c5498ac29e431cce (diff)
downloadsandhi-37a863991f5e05035cce6738379de7a8ebc2b160.tar.gz
sandhi-37a863991f5e05035cce6738379de7a8ebc2b160.tar.bz2
sandhi-37a863991f5e05035cce6738379de7a8ebc2b160.zip
polish up work and notify api
There is a formal api to mark done, and IO failures. Notify topology was created for consistency. So far, there output fail is unimplemented, and input fail requires an additional check.
Diffstat (limited to 'lib/block.cpp')
-rw-r--r--lib/block.cpp19
1 files changed, 17 insertions, 2 deletions
diff --git a/lib/block.cpp b/lib/block.cpp
index 3732fdb..51c5f08 100644
--- a/lib/block.cpp
+++ b/lib/block.cpp
@@ -156,9 +156,9 @@ bool Block::stop(void)
return true;
}
-bool Block::check_topology(int, int)
+void Block::notify_topology(const size_t, const size_t)
{
- return true;
+ return;
}
void Block::set_buffer_affinity(const long affinity)
@@ -170,3 +170,18 @@ void Block::set_interruptible_work(const bool enb)
{
(*this)->block->interruptible_work = enb;
}
+
+void Block::mark_output_fail(const size_t which_output)
+{
+ (*this)->block->output_fail(which_output);
+}
+
+void Block::mark_input_fail(const size_t which_input)
+{
+ (*this)->block->input_fail(which_input);
+}
+
+void Block::mark_done(void)
+{
+ (*this)->block->mark_done();
+}