diff options
author | Ashish Chaudhari <ashish@ettus.com> | 2017-04-04 19:21:31 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2017-04-05 17:16:31 -0700 |
commit | 4ab72eb9991d503d8cd329b31572d966ef0e1ae8 (patch) | |
tree | 65daea22e4f3dcb25b6d562b82b97da2b4887d88 /host/lib/usrp/e300/e300_impl.hpp | |
parent | 15d9c6850c23c867c8ec823dedd20c7ec09d7e6b (diff) | |
download | uhd-4ab72eb9991d503d8cd329b31572d966ef0e1ae8.tar.gz uhd-4ab72eb9991d503d8cd329b31572d966ef0e1ae8.tar.bz2 uhd-4ab72eb9991d503d8cd329b31572d966ef0e1ae8.zip |
device3: Fixed potential concurreny issues
- Protected block_ctrl vector with a mutex
- Note: const block accessors are not thread safe
- Removed sid_framer from base device3 class
- Made x300,e300 sid_framers atomic
Diffstat (limited to 'host/lib/usrp/e300/e300_impl.hpp')
-rw-r--r-- | host/lib/usrp/e300/e300_impl.hpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/host/lib/usrp/e300/e300_impl.hpp b/host/lib/usrp/e300/e300_impl.hpp index 50d78fdd4..cc2e39e23 100644 --- a/host/lib/usrp/e300/e300_impl.hpp +++ b/host/lib/usrp/e300/e300_impl.hpp @@ -47,6 +47,7 @@ #include "e300_i2c.hpp" #include "e300_eeprom_manager.hpp" #include "e300_sensor_manager.hpp" +#include <atomic> /* if we don't compile with gpsd support, don't bother */ #ifdef E300_GPSD @@ -288,7 +289,7 @@ private: // members uhd::device_addr_t _device_addr; xport_t _xport_path; e300_fifo_interface::sptr _fifo_iface; - size_t _sid_framer; + std::atomic<size_t> _sid_framer; radio_perifs_t _radio_perifs[2]; double _tick_rate; ad9361_ctrl::sptr _codec_ctrl; |