From cb1649d201e41c85ed77256712309706ed1a805d Mon Sep 17 00:00:00 2001 From: Martin Braun Date: Fri, 21 Apr 2017 22:33:16 -0700 Subject: uhd: tasks now use std::threads under the hood, and can't be interrupted USRP1 and USRP2 used tasks that relied on Boost thread interruption mechanisms. These were replaced with explicit atomics. --- host/lib/usrp/usrp2/usrp2_impl.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'host/lib/usrp/usrp2/usrp2_impl.cpp') diff --git a/host/lib/usrp/usrp2/usrp2_impl.cpp b/host/lib/usrp/usrp2/usrp2_impl.cpp index 78a9acb72..9ee13d289 100644 --- a/host/lib/usrp/usrp2/usrp2_impl.cpp +++ b/host/lib/usrp/usrp2/usrp2_impl.cpp @@ -316,7 +316,8 @@ static zero_copy_if::sptr make_xport( * Structors **********************************************************************/ usrp2_impl::usrp2_impl(const device_addr_t &_device_addr) : - device_addr(_device_addr) + device_addr(_device_addr), + _pirate_task_exit(false) { UHD_LOGGER_INFO("USRP2") << "Opening a USRP2/N-Series device..."; @@ -786,6 +787,7 @@ usrp2_impl::usrp2_impl(const device_addr_t &_device_addr) : } usrp2_impl::~usrp2_impl(void){UHD_SAFE_CALL( + _pirate_task_exit = true; for(const std::string &mb: _mbc.keys()){ _mbc[mb].tx_dsp->set_updates(0, 0); } -- cgit v1.2.3