diff options
author | Ben Reynwar <ben@reynwar.net> | 2013-05-10 01:17:21 -0700 |
---|---|---|
committer | Ben Reynwar <ben@reynwar.net> | 2013-05-10 01:17:21 -0700 |
commit | af76f9509ae97f04ef6b77a3f63e2650dc2b66c8 (patch) | |
tree | 2b5ad689efd3cb2f387dfc61d81c8f6364b92b38 /gnuradio-runtime | |
parent | 72948e9a4031f8d779a70f73e6e6a0014d1de326 (diff) | |
parent | 3e052d303874a07237c4e0c31eef3f7f7a192835 (diff) |
Merge branch 'next' into next_docs
Diffstat (limited to 'gnuradio-runtime')
-rw-r--r-- | gnuradio-runtime/CMakeLists.txt | 1 | ||||
-rw-r--r-- | gnuradio-runtime/include/gr_buffer.h | 2 | ||||
-rw-r--r-- | gnuradio-runtime/include/gr_constants.h | 10 | ||||
-rw-r--r-- | gnuradio-runtime/lib/CMakeLists.txt | 1 | ||||
-rw-r--r-- | gnuradio-runtime/lib/gr_block_detail.cc | 2 | ||||
-rw-r--r-- | gnuradio-runtime/lib/gr_realtime.cc | 3 |
6 files changed, 13 insertions, 6 deletions
diff --git a/gnuradio-runtime/CMakeLists.txt b/gnuradio-runtime/CMakeLists.txt index abdc969690..4940f7e58c 100644 --- a/gnuradio-runtime/CMakeLists.txt +++ b/gnuradio-runtime/CMakeLists.txt @@ -27,6 +27,7 @@ include(GrPython) # Setup compatibility checks and defines ######################################################################## include(${CMAKE_CURRENT_SOURCE_DIR}/ConfigChecks.cmake) +GR_CHECK_LINUX_SCHED_AVAIL() ######################################################################## # Register component diff --git a/gnuradio-runtime/include/gr_buffer.h b/gnuradio-runtime/include/gr_buffer.h index 9b9f75604a..cc6a7a61fe 100644 --- a/gnuradio-runtime/include/gr_buffer.h +++ b/gnuradio-runtime/include/gr_buffer.h @@ -112,6 +112,7 @@ class GR_RUNTIME_API gr_buffer { * the tag. * * \param tag the tag that needs to be removed + * \param id the unique ID of the block calling this function */ void remove_item_tag(const gr_tag_t &tag, long id); @@ -283,6 +284,7 @@ class GR_RUNTIME_API gr_buffer_reader { * \param v a vector reference to return tags into * \param abs_start a uint64 count of the start of the range of interest * \param abs_end a uint64 count of the end of the range of interest + * \param id the unique ID of the block to make sure already deleted tags are not returned */ void get_tags_in_range(std::vector<gr_tag_t> &v, uint64_t abs_start, diff --git a/gnuradio-runtime/include/gr_constants.h b/gnuradio-runtime/include/gr_constants.h index 3534166bc0..38ad858b20 100644 --- a/gnuradio-runtime/include/gr_constants.h +++ b/gnuradio-runtime/include/gr_constants.h @@ -26,27 +26,27 @@ #include <string> /*! - * \brief return ./configure --prefix argument. Typically /usr/local + * \brief return CMAKE_INSTALL_PREFIX. Typically /usr/local */ GR_RUNTIME_API const std::string gr_prefix(); /*! - * \brief return ./configure --sysconfdir argument. Typically $prefix/etc or /etc + * \brief return SYSCONFDIR. Typically ${CMAKE_INSTALL_PREFIX}/etc or /etc */ GR_RUNTIME_API const std::string gr_sysconfdir(); /*! - * \brief return preferences file directory. Typically $sysconfdir/etc/conf.d + * \brief return preferences file directory. Typically ${SYSCONFDIR}/etc/conf.d */ GR_RUNTIME_API const std::string gr_prefsdir(); /*! - * \brief return date/time of build, as set when 'bootstrap' is run + * \brief return date/time of build, as set when 'cmake' is run */ GR_RUNTIME_API const std::string gr_build_date(); /*! - * \brief return version string defined in configure.ac + * \brief return version string defined by cmake (GrVersion.cmake) */ GR_RUNTIME_API const std::string gr_version(); diff --git a/gnuradio-runtime/lib/CMakeLists.txt b/gnuradio-runtime/lib/CMakeLists.txt index 98db673f5d..1cde8ce323 100644 --- a/gnuradio-runtime/lib/CMakeLists.txt +++ b/gnuradio-runtime/lib/CMakeLists.txt @@ -123,6 +123,7 @@ list(APPEND gnuradio_runtime_sources gr_vmcircbuf_mmap_tmpfile.cc gr_vmcircbuf_sysv_shm.cc malloc16.c + realtime.cc runtime_block_gateway.cc ) diff --git a/gnuradio-runtime/lib/gr_block_detail.cc b/gnuradio-runtime/lib/gr_block_detail.cc index 7d850138c4..0b12b1728b 100644 --- a/gnuradio-runtime/lib/gr_block_detail.cc +++ b/gnuradio-runtime/lib/gr_block_detail.cc @@ -270,6 +270,7 @@ gr_block_detail::stop_perf_counters(int noutput_items, int nproduced) d_var_input_buffers_full[i] = 0; } for(size_t i=0; i < d_output.size(); i++) { + gr::thread::scoped_lock guard(*d_output[i]->mutex()); float pfull = 1.0f - static_cast<float>(d_output[i]->space_available()) / static_cast<float>(d_output[i]->bufsize()); d_ins_output_buffers_full[i] = pfull; @@ -304,6 +305,7 @@ gr_block_detail::stop_perf_counters(int noutput_items, int nproduced) } for(size_t i=0; i < d_output.size(); i++) { + gr::thread::scoped_lock guard(*d_output[i]->mutex()); float pfull = 1.0f - static_cast<float>(d_output[i]->space_available()) / static_cast<float>(d_output[i]->bufsize()); diff --git a/gnuradio-runtime/lib/gr_realtime.cc b/gnuradio-runtime/lib/gr_realtime.cc index d7a7eab5ba..9977718a5d 100644 --- a/gnuradio-runtime/lib/gr_realtime.cc +++ b/gnuradio-runtime/lib/gr_realtime.cc @@ -25,9 +25,10 @@ #endif #include <gr_realtime.h> +#include <realtime.h> gr_rt_status_t gr_enable_realtime_scheduling() { - return gr_enable_realtime_scheduling(); + return gr::enable_realtime_scheduling(); } |