diff options
Diffstat (limited to 'host/lib')
| -rw-r--r-- | host/lib/usrp/b100/b100_ctrl.cpp | 4 | ||||
| -rw-r--r-- | host/lib/usrp/common/fx2_ctrl.cpp | 4 | ||||
| -rw-r--r-- | host/lib/usrp/usrp1/io_impl.cpp | 10 | ||||
| -rw-r--r-- | host/lib/usrp/usrp1/usrp1_impl.cpp | 1 | 
4 files changed, 10 insertions, 9 deletions
diff --git a/host/lib/usrp/b100/b100_ctrl.cpp b/host/lib/usrp/b100/b100_ctrl.cpp index 7d40daa32..e6136c00e 100644 --- a/host/lib/usrp/b100/b100_ctrl.cpp +++ b/host/lib/usrp/b100/b100_ctrl.cpp @@ -165,7 +165,7 @@ int b100_ctrl_impl::write(boost::uint32_t addr, const ctrl_data_t &data) {      pkt.pkt_meta.seq = _seq++;      pkt.pkt_meta.len = pkt.data.size();      pkt.pkt_meta.addr = addr; -    boost::uint16_t pkt_buff[CTRL_PACKET_LENGTH / sizeof(boost::uint16_t)]; +    boost::uint16_t pkt_buff[CTRL_PACKET_LENGTH / sizeof(boost::uint16_t)] = {};      pack_ctrl_pkt(pkt_buff, pkt);      size_t result = send_pkt(pkt_buff); @@ -181,7 +181,7 @@ ctrl_data_t b100_ctrl_impl::read(boost::uint32_t addr, size_t len) {      pkt.pkt_meta.seq = _seq++;      pkt.pkt_meta.len = len;      pkt.pkt_meta.addr = addr; -    boost::uint16_t pkt_buff[CTRL_PACKET_LENGTH / sizeof(boost::uint16_t)]; +    boost::uint16_t pkt_buff[CTRL_PACKET_LENGTH / sizeof(boost::uint16_t)] = {};      //flush anything that might be in the queue      while (get_ctrl_data(pkt.data, 0.0)){ diff --git a/host/lib/usrp/common/fx2_ctrl.cpp b/host/lib/usrp/common/fx2_ctrl.cpp index 3c6df7079..baf8f5e68 100644 --- a/host/lib/usrp/common/fx2_ctrl.cpp +++ b/host/lib/usrp/common/fx2_ctrl.cpp @@ -419,7 +419,7 @@ public:      {          UHD_ASSERT_THROW(bytes.size() < max_i2c_data_bytes); -        unsigned char buff[max_i2c_data_bytes]; +        unsigned char buff[max_i2c_data_bytes] = {};          std::copy(bytes.begin(), bytes.end(), buff);          int ret = this->usrp_i2c_write(addr & 0xff, @@ -434,7 +434,7 @@ public:      {        UHD_ASSERT_THROW(num_bytes < max_i2c_data_bytes); -      unsigned char buff[max_i2c_data_bytes]; +      unsigned char buff[max_i2c_data_bytes] = {};        int ret = this->usrp_i2c_read(addr & 0xff,                                              buff,                                              num_bytes); diff --git a/host/lib/usrp/usrp1/io_impl.cpp b/host/lib/usrp/usrp1/io_impl.cpp index f3cad188a..f27135562 100644 --- a/host/lib/usrp/usrp1/io_impl.cpp +++ b/host/lib/usrp/usrp1/io_impl.cpp @@ -221,17 +221,17 @@ void usrp1_impl::io_init(void){      _io_impl = UHD_PIMPL_MAKE(io_impl, (_data_transport)); -    //create a new vandal thread to poll xerflow conditions -    _io_impl->vandal_task = task::make(boost::bind( -        &usrp1_impl::vandal_conquest_loop, this -    )); -      //init as disabled, then call the real function (uses restore)      this->enable_rx(false);      this->enable_tx(false);      rx_stream_on_off(false);      tx_stream_on_off(false);      _io_impl->flush_send_buff(); + +    //create a new vandal thread to poll xerflow conditions +    _io_impl->vandal_task = task::make(boost::bind( +        &usrp1_impl::vandal_conquest_loop, this +    ));  }  void usrp1_impl::rx_stream_on_off(bool enb){ diff --git a/host/lib/usrp/usrp1/usrp1_impl.cpp b/host/lib/usrp/usrp1/usrp1_impl.cpp index ef8ae950d..430ea59c8 100644 --- a/host/lib/usrp/usrp1/usrp1_impl.cpp +++ b/host/lib/usrp/usrp1/usrp1_impl.cpp @@ -210,6 +210,7 @@ usrp1_impl::usrp1_impl(const device_addr_t &device_addr){      ////////////////////////////////////////////////////////////////////      // Initialize the properties tree      //////////////////////////////////////////////////////////////////// +    _rx_dc_offset_shadow = 0;      _tree = property_tree::make();      _tree->create<std::string>("/name").set("USRP1 Device");      const fs_path mb_path = "/mboards/0";  | 
